Fix for 6888888 breaks the build
Tim Bell
Tim.Bell at Sun.COM
Thu Oct 15 16:18:53 UTC 2009
> Andrew John Hughes wrote:
(snip!)
>> I think there's still an issue here that makes this patch worth
>> pushing. The 6888888 fix didn't cause the bug, but merely made it
>> visible to a lot more people. So 6889255 will only hide it again.
>> The build uses JAVA_TOOLS_DIR for javac, javah and javadoc:
>>
>> # If no explicit tools, use boot tools (add VM flags in this case)
>> JAVAC_CMD = $(JAVA_TOOLS_DIR)/javac $(JAVAC_JVM_FLAGS) \
>> $(JAVACFLAGS)
>> JAVAH_CMD = $(JAVA_TOOLS_DIR)/javah \
>> $(JAVAHFLAGS)
>> JAVADOC_CMD = $(JAVA_TOOLS_DIR)/javadoc $(JAVA_TOOLS_FLAGS:%=-J%)
>>
>>
>> but only when LANGTOOLS_DIST is not defined. Normally, langtools is
>> built first so LANGTOOLS_DIST is defined. What your fix for 6888888
>> did was cause the setting for JAVAH to get used in all cases and, as
>> JAVA_TOOLS_DIR defaults to ALT_JDK_IMPORT_PATH rather than BOOTDIR
>> this fails in many cases as the user sets ALT_BOOTDIR not
>> ALT_JDK_IMPORT_PATH.
>>
>> In jdk_generic_profile, it seems ALT_JDK_IMPORT_PATH is set to
>> ${jdk_instances}/${importjdk} if it exists. On Solaris,
>> ${jdk_instances} is set to /usr/jdk/instances which probably explains
>> why Sun engineers building on Solaris may not see this bug either.
>> ${jdk_instances} is set to /opt/java on GNU/Linux, whereas distros
>> tend to have standardised on /usr/lib/jvm. It's simply "C:" on
>> Windows. As mentioned on IRC, release engineering are setting
>> ALT_JDK_IMPORT_PATH explicitly so also would never see this bug.
>>
>> As we presumably want the tools from the bootstrap JDK, and not from
>> 'the import JDK to be used to get hotspot VM if not built', I suggest
>> we switch to BOOTDIR by default by applying this patch.
>>
Jonathan Gibbons wrote:
> This probably explains problems I've reported informally to Kelly a
> while back, but never got around to formally investigating. FWIW,
> this fix does not interfere with the fix for 6889255 coming up, and this
> fix seems like a good idea to me.
OK - I filed a new bug report:
6892021 "Build tools from ALT_JDK_IMPORT_PATH versus BOOTDIR"
with a pointer to this email thread.
Kelly - do you have an opinion on this?
Thanks-
Tim
More information about the build-dev
mailing list