2008-10-29 17:06:47 +01:00
|
|
|
if test "$SUN_STUDIO_CC" = yes ; then
|
2000-10-10 23:22:29 +02:00
|
|
|
CC="$CC -Xa" # relaxed ISO C mode
|
2008-10-29 17:06:47 +01:00
|
|
|
CFLAGS="-v" # -v is like gcc -Wall
|
2004-12-02 19:11:40 +01:00
|
|
|
if test "$enable_debug" != yes; then
|
|
|
|
CFLAGS="$CFLAGS -O" # any optimization breaks debug
|
|
|
|
fi
|
2006-04-28 06:32:10 +02:00
|
|
|
|
2006-04-28 00:28:42 +02:00
|
|
|
# Pick the right test-and-set (TAS) code for the Sun compiler.
|
|
|
|
# We would like to use in-line assembler, but the compiler
|
2008-10-29 17:06:47 +01:00
|
|
|
# requires *.il files to be on every compile line, making
|
2006-04-28 00:28:42 +02:00
|
|
|
# the build system too fragile.
|
2008-10-29 17:06:47 +01:00
|
|
|
case $host_cpu in
|
|
|
|
sparc)
|
2006-04-28 00:28:42 +02:00
|
|
|
need_tas=yes
|
2008-10-29 17:06:47 +01:00
|
|
|
tas_file=sunstudio_sparc.s
|
2004-09-24 02:21:32 +02:00
|
|
|
;;
|
2008-10-29 17:06:47 +01:00
|
|
|
i?86|x86_64)
|
2006-04-28 00:28:42 +02:00
|
|
|
need_tas=yes
|
2008-10-29 17:06:47 +01:00
|
|
|
tas_file=sunstudio_x86.s
|
2004-09-24 02:21:32 +02:00
|
|
|
;;
|
2006-04-28 00:28:42 +02:00
|
|
|
esac
|
|
|
|
fi
|