Sunday, August 26, 2012

Ant, Javadoc, Libgdx, CreateProcess error=87, and YOU!

Gratuitously copied from the Western Skies blog since I *just* got bit by this -- and apparently got bit by it before 'cuz Google showed that I had visited this link sometime in the past:

I've been developing an Ant build file for a large-ish base of existing code. I've been using my Mac as the primary devleopment platform, but the ultimate target (for the other developers) is Windows. My task to build the javadocs runs fine on OS X, but the first time I rant it on Windows, I got the following:

c:\demo\build.xml:180: Javadoc failed: java.io.IOException: Cannot run program "c:\Program Files\Java\jdk1.6.0\bin\javadoc.exe": CreateProcess error=87, The parameter is incorrect

After about 10 minutes of Googling, I found a/the simple solution: add the useexternalfile attribute to the javadoc task in Ant. Voila , back in business, on the PC at least, and it didn't seem to break the build on the Mac.

 I got bit by the most recent version libgdx when trying to run "ant" in order to build the "dist", which includes the API documentation that I was really aiming for.

No comments:

Post a Comment