Hi Johnathan, this is a known problem - at least to me :)
It is caused by a peculiarity of the gcc version on Ubuntu where "gcc -dumpversion" doesn't print a micro-version: Ubuntu: $ gcc -dumpversion 4.6 Any other Linux: $ gcc -dumpversion 4.8.3 This "feature" is tracked under https://bugs.launchpad.net/ubuntu/+source/gcc-4.8/+bug/1360404 and has been fixed for gcc 4.9 but won't be fixed for older versions of gcc. In hotspot/make/linux/makefiles/gcc.make we parse the micro-version of gcc and use it in the following way: CC_VER_MICRO := $(shell $(CC) -dumpversion | sed 's/egcs-//' | cut -d'.' -f3) ifeq ($(shell expr $(CC_VER_MAJOR) = 4 \& $(CC_VER_MINOR) = 1 \& $(CC_VER_MICRO) = 1), 1) $(error "GCC $(CC_VER_MAJOR).$(CC_VER_MINOR).$(CC_VER_MICRO) not supported because of https://gcc.gnu.org/bugzilla/show_bug.cgi?id=27724") endif The shell expression results in a syntax error if $(CC_VER_MICRO) because it expaands to something like "expr 4 = 4 & 3 = 1 & = 1" I haven't fixed it until now because it does no harm. The corresponding check is for gcc 4.1.1 but the affected Ubuntu gcc compilers are 4.6, 4.7 and 4.8. A trivial fix would be to set CC_VER_MICRO to "0" by default. Regards, Volker On Tue, Nov 3, 2015 at 10:45 PM, Jonathan Gibbons <jonathan.gibb...@oracle.com> wrote: > I'm seeing a bunch of "syntax error"s on an otherwise successful build of > jdk9/dev. > > This is on Ubuntu Linux, 14.04. > > Is this a known problem; should I be worried? > > -- Jon > > Creating support/jce/policy/unlimited/US_export_policy.jar > Creating support/jce/policy/limited/local_policy.jar > Creating support/jce/policy/unlimited/local_policy.jar > Generating java.security > expr: syntax error > expr: syntax error > expr: syntax error > expr: syntax error > expr: syntax error > expr: syntax error > Note: Some input files use unchecked or unsafe operations. > Note: Recompile with -Xlint:unchecked for details. > Warning: generation and use of skeletons and static stubs for JRMP > is deprecated. Skeletons are unnecessary, and static stubs have > been superseded by dynamically generated stubs. Users are > encouraged to migrate away from using rmic to generate skeletons and static > stubs. See the documentation for java.rmi.server.UnicastRemoteObject. > expr: syntax error > expr: syntax error > expr: syntax error > All done. > Generating linux_amd64_docs/jvmti.html > Creating libverify.so from 2 file(s) > Creating libjava.so from 61 file(s) > Creating libfdlibm.a from 57 file(s) >