Results 1 to 4 of 4

Thread: Ant compiling some classes to 1.7 despite -target 1.5?

  1. #1
    Senior Member
    Join Date
    Jul 2007
    Posts
    1,193

    Default Ant compiling some classes to 1.7 despite -target 1.5?

    Has anyone who builds KoLmafia ever ran into the issue where ant decides to compile 1 or 2 classes as JDK7 classes despite being given the 1.5 target directive?

    I have had it happen before and the quick fix is simply to delete the "build" directory and try again, but I'd like to get to the bottom of it as it seems to be what has been causing my native Windows build scripts to error out every once in a while (and consequently stay broken until either I notice it myself, or somebody nudges me on the forums).

    The frustrating thing is that the resulting JAR file will run fine (because I'm using an up to date JRE) but Excelsior JET doesn't support 1.7 classes, so it won't go through with the build process.

    The most recent culprits were:

    net/sourceforge/kolmafia/persistence/CustomItemDatabase.class
    net/sourceforge/kolmafia/KoLConstants.class


    being the only class files to come out as 1.7, I think I've had problems with KoLConstants before. It's a head scratcher though, because as I said the "quick fix" is simply to delete the compiled class and try again and hope ant does what you've asked it to do.

    Anyone else ran into this quirk? Know how to fix it properly?

    Edit: I should let you know that the build environment is Windows 8 64-bit, but I've ran into the issue on Windows 7 and Windows Vista, too. I'm using Ant 1.9.0 and I'm about to check if there's a newer version.
    Last edited by Catch-22; 09-08-2013 at 06:24 PM.
    Procrastination
    Leaves many things unfinished

    Originally Posted by /haiku

  2. #2

    Default

    That's odd. Did you provide the source 1.5 directive as well? If you didn't, that may be why ant is being goofy.

  3. #3
    Senior Member
    Join Date
    Jul 2007
    Posts
    1,193

    Default

    That's odd. Did you provide the source 1.5 directive as well? If you didn't, that may be why ant is being goofy.
    Originally Posted by wrldwzrd89 View Post
    I'm using the unmodified build file from the SVN, which has source and target set to 1.5.
    Procrastination
    Leaves many things unfinished

    Originally Posted by /haiku

  4. #4
    Senior Member
    Join Date
    Jul 2007
    Posts
    1,193

    Default

    I don't want to jinx anything but things appear to be working well in Ant 1.9.2.
    Procrastination
    Leaves many things unfinished

    Originally Posted by /haiku

Similar Threads

  1. 15602: The "compile" target depends on the "version" target
    By RSS Bot in forum Latest SVN Changes
    Replies: 0
    Last Post: 03-17-2015, 05:40 PM
  2. Compiling the latest KolMafia with Jet
    By Orie in forum Unofficial Builds
    Replies: 1
    Last Post: 08-22-2014, 11:33 PM
  3. Bug - Fixed Compile errors preventing KoLmafia from compiling with JDK 1.4
    By wrldwzrd89 in forum Bug Reports
    Replies: 14
    Last Post: 02-26-2012, 10:06 PM
  4. Bug - Fixed Trouble compiling 9773
    By Captain Kirk in forum Bug Reports
    Replies: 3
    Last Post: 08-31-2011, 11:52 AM
  5. Chat Script & Compiling Issues
    By spozmo in forum Scripting Discussion
    Replies: 6
    Last Post: 11-26-2008, 05:18 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •