This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.
In project properties I have defined the java platform 1.6.0-b105 But in dist's jar-Manifest I find: Created-By: 1.6.0_01-b06 (Sun Microsystems Inc.)
The "Created-By" is added by the ant jar task and is not important at least now. I've expect that you have default platform 1.6.0_01-b06 and explicit platform set to project is 1.6.0-b105, right? The ant runs inside the IDE and the jar task doesn't have support to run on explicit platform. Running the ant on the explicit platform will slowdown the build.
Yes, you are right. The ant jar task should use it's property "platform.active" from project.properties for the "Created-By"-entry, instead of the version of the JVM on which it's running.
Unfortunately it requires changes in the ant jar task.
So then it's an ant issue ? If yes, could you file it there. Unfortunately I'm not involved in the ant project.
I will firstly try to find some workaround and later fill an enhancement for adding (executable) to jar task.
Not a defect IMHO. Ant is correctly recording which version of Java was used to package the JAR. This has nothing to do with what versions of Java were used to compile sources or test the result.
IMHO for the deployer of a given jar archive it's more interesting to know which version of javac has compiled the sources, than which version of jar has packed the classes to a jar. Can you add an additional info in the manifest, which documents this?
Why you need to know which version of javac compiled the sources? If all you need is a -target you can get it from the class files. If you compile source with JDK 1.6 javac with -target 1.4 the javac will generate bytecode for JDK 1.4 but it was compiled by 1.6 javac.
My last comment was just academic. I didn't have needed this until now. I was just confused about finding the "wrong" version in the manifest, thinking that could be confusing to others too.
I came to this issue, because I had real problems compiling with JDK 6.0 u1 (see link below) and wanted to distinguish my jars by it's manifest. http://bugs.sun.com/bugdatabase/view_bug.do?bug_id=6575083 (Until this bug is resolved, I have to remain at JDK 6.0.)
Rather an enhancement request in that case. No plans to implement anything of the sort, but I'm sure you can figure out how to do it yourself by overriding the jar target in your build.xml.