I have J2ME code, which I want to be able to compile using the J2ME Polish preprocessor or the wtkpreprocessor (antenna). They mostly use the same directives so it usually works, but ...
When I want to insert an URL value in the Java code this gives a problem. In Antenna the code would look like this:
//#ifdef my.url
//# System.out.println("My Url");
//#expand String location = "%my.url%";
//#else
System.out.println("Default");
String location = "http://www.some.default.url.com";
//#endif
and in J2ME Polish it would look like this:
//#ifdef my.url:defined
//# System.out.println("My Url");
//#= String location = "${my.url}";
//#else
System.out.println("Default");
String location = "http://www.some.default.url.com";
//#endif
I want some way in which I can use the preprocessors interchangeably and still be able to set the url in the build.xml, any ideas?