[PATCH] hotspot/make/solaris/makefiles/sparcWorks.make misses grep for CC version

Kelly O'Hair Kelly.Ohair at Sun.COM
Mon Nov 10 19:35:27 UTC 2008


I'll file a bug for this so it doesn't get lost.

Thanks for the patch.

-kto


Christian Thalinger wrote:
> Hi!
> 
> I just wanted to build the new OpenJDK 6 b13 drop on a recent
> OpenSolaris Indiana (snv_101a) and ran into this warning:
> 
> cd solaris_i486_compiler2/product && make -w
> WARNING: You are using CC version 5.10 Usage: CC [ options ] files.  Use 'CC -flags' for details and should be using version 5.10
> WARNING: You are using cc version cc: `-V' option must have argument and should be using version 5.10
> expr: syntax error
> expr: syntax error
> expr: syntax error
> expr: syntax error
> expr: syntax error
> 
> This seems to be related to the update of Sun Studio C++ compiler to
> version 5.10, as it didn't happen with 5.9.  I thought it may be fixed
> in jdk7, but it isn't.  So here is a patch that fixes this problem:
> 
> diff -r 42ca4002efc2 make/solaris/makefiles/sparcWorks.make
> --- a/make/solaris/makefiles/sparcWorks.make	Thu Nov 06 12:10:20 2008 -0800
> +++ b/make/solaris/makefiles/sparcWorks.make	Mon Nov 10 15:22:15 2008 +0100
> @@ -41,7 +41,7 @@
>  
>  # Get the last thing on the line that looks like x.x+ (x is a digit).
>  COMPILER_REV := \
> -$(shell $(CPP) -V 2>&1 | sed -e 's/^.*\([1-9]\.[0-9][0-9]*\).*/\1/')
> +$(shell $(CPP) -V 2>&1 | grep "CC:" | sed -e 's/^.*\([1-9]\.[0-9][0-9]*\).*/\1/')
>  C_COMPILER_REV := \
>  $(shell $(CC) -V 2>&1 | grep -i "cc:" |  sed -e 's/^.*\([1-9]\.[0-9][0-9]*\).*/\1/')
> 
> - Christian
> 



More information about the build-dev mailing list