Updated. I kicked off a JPRT -bo run to be sure it doesn't break something else.
http://cr.openjdk.java.net/~ddehaven/8043340/v4/ Only change from previous is in make/bsd/makefiles/saproc.make, I added SA_SYSROOT_FLAGS which is set to SYSROOT_CFLAGS. I didn't want to add SYSROOT_CFLAGS to the compile command in case $(CC) expands to something that includes the same args on non-Mac platforms, this seems safer. -DrD- > > Yes, I was going for convenience and minimizing disturbance. I'll change how > the flags are passed. > > If SDKROOT is unset then the paths point at the existing hard-coded paths in > /System/Library/Frameworks, all SDKROOT does is prepend the SDK path and it's > only set under certain conditions. JPRT has been perfectly happy with this > change so far. > > Note that this ugliness can go away when we remove the dependencies on the > JavaNativeFoundation and JavaRuntimeSupport frameworks. > > -DrD- > >> Hi David, >> >> In saproc.make: >> >> Hijacking SAARCH seems wrong - convenient perhaps, but wrong. What you are >> adding is nothing to do with the ARCH setting. If none of the existing >> variables are suitable perhaps just add SA_CFLAGS? >> >> If SDKROOT is not set is the path one that would normally exist? In >> particular does it exist on all our JPRT clients? >> >> Thanks, >> David H. >> >> On 12/06/2014 6:06 AM, David DeHaven wrote: >>> >>> Can I get hotspot signoff on the (fairly trivial) hotspot changes for this? >>> >>> The hotspot specific changes are here: >>> http://cr.openjdk.java.net/~ddehaven/8043340/v3/hotspot/ >>> >>> Also, is there a problem if I push these through jdk9/build instead of >>> going through hotspot? >>> >>> I'm re-submitting a JPRT run, now that JDK-8045998 has been fixed I should >>> actually get valid results. >>> >>> -DrD- >>> >>>> From: David DeHaven <david.deha...@oracle.com> >>>> Subject: Re: RFR: [9] 8043340 & 8043591: [macosx] Build system issues >>>> Date: June 4, 2014 16:01:29 PDT >>>> To: build-dev build-dev <build-dev@openjdk.java.net> >>>> >>>> >>>> Next (hopefully last??) update: >>>> http://cr.openjdk.java.net/~ddehaven/8043340/v3 >>>> >>>> (ignore changes to jdk/src/macosx/native/sun/osxapp/ThreadUtilities.m, >>>> that's a separate patch) >>>> >>>> I also removed generated_configure.sh since those will be automatically >>>> generated before pushing anyways and it just keeps getting in the way. >>>> >>>> >>>> These comments in flags.m4 are a bit misleading and not really true: >>>> # FIXME: This needs to be exported in spec.gmk due to closed legacy >>>> code. >>>> # FIXME: clean this up, and/or move it elsewhere. >>>> >>>> So, I removed them... >>>> >>>> I also removed using SDKROOT from the env, since we ignore the >>>> environment. Only two args affect SYSROOT now, --with-sysroot and >>>> --with-sdk-name. >>>> >>>> >>>> >>>> Testing: >>>> >>>> I now have two system configurations I'm testing with: >>>> 1> OS X 10.8, Xcode 5 in /Applications/Xcode.app, Xcode 4.6.3 in >>>> /Applications/old/Xcode4.app (plus everything needed to build closed jdk) >>>> 2> OS X 10.9, Command line tools only, installed JDK 8u5, freetype and >>>> autoconf 2.69 (nothing else) >>>> >>>> System 1 tests: >>>> $ sudo xcode-select -switch /Applications/Xcode.app >>>> $ make clean; sh ./configure; make images >>>> ... >>>> 00:09:17 TOTAL >>>> ------------------------- >>>> Finished building Java(TM) for target 'images' >>>> >>>> >>>> $ make clean; sh ./configure >>>> --with-toolchain-path=/Applications/old/Xcode4.app/Contents/Developer/usr/bin; >>>> make images >>>> ... >>>> 00:13:37 TOTAL >>>> ------------------------- >>>> Finished building Java(TM) for target 'images' >>>> >>>> (Note that building with Xcode 5/clang is faster...) >>>> >>>> >>>> $ sudo xcode-select -switch /Applications/old/Xcode4.app >>>> $ make clean; sh ./configure; make images >>>> Broken! The current Xcode command line tools don't run gcc as gcc even if >>>> Xcode 4 is active >>>> Nothing we can do about this, anyone needing to use Xcode 4 will need to >>>> use --with-toolchain-path or --with-toolchain-type=clang (as below) >>>> Hudson/JPRT should not be affected unless they also have Xcode 5 installed >>>> >>>> >>>> $ make clean; sh ./configure --with-toolchain-type=clang; make images >>>> ... >>>> 00:10:54 TOTAL >>>> ------------------------- >>>> Finished building Java(TM) for target 'images' >>>> >>>> >>>> System 2 tests: >>>> OpenJDK only (ignore the time, I had it pulling closed jdk while building): >>>> $ rm -rf build; sh ./configure --with-freetype=/opt/freetype && make images >>>> ... >>>> 00:20:26 TOTAL >>>> ------------------------- >>>> Finished building OpenJDK for target 'images' >>>> >>>> >>>> Closed JDK (images only, deploy/install expected to fail) >>>> $ rm -rf build; sh ./configure --with-freetype=/opt/freetype && make images >>>> ... >>>> 00:10:05 TOTAL >>>> ------------------------- >>>> Finished building Java(TM) for target 'images' >>>> >>>> -DrD- >>>> >>> >