diff: mgnuc fixes for SunOS pthread.h -ansi problem
Fergus Henderson
fjh at cs.mu.OZ.AU
Sat Mar 13 10:39:20 AEDT 1999
Estimated hours taken: 0.5
scripts/mgnuc.in:
Re-enable the passing of `-ansi' to gcc, unless `--no-ansi' is
specified. I think Tom Conway's change to disable it in all cases
was committed accidentally.
Change the code which disables `-ansi' if `--thread-safe' is
specified and it's a sparc (since the Solaris "pthread.h"
doesn't work with -ansi) to check the OS (Solaris or SunOS)
rather than the architecture (sparc).
Index: scripts/mgnuc.in
===================================================================
RCS file: /home/staff/zs/imp/mercury/scripts/mgnuc.in,v
retrieving revision 1.58
diff -u -r1.58 mgnuc.in
--- mgnuc.in 1998/12/22 07:54:16 1.58
+++ mgnuc.in 1999/02/10 18:26:31
@@ -67,7 +67,7 @@
case "$CC" in
*gcc*)
- ANSI_OPTS="" # --no-ansi to avoid syntax errors in Solaris pthread.h
+ ANSI_OPTS="-ansi"
CHECK_OPTS="
-Wall -Wwrite-strings -Wpointer-arith -Wtraditional
-Wshadow -Wstrict-prototypes -Wmissing-prototypes -Wno-unused"
@@ -340,7 +340,7 @@
# disabling the warning.
CHECK_OPTS="$CHECK_OPTS -Wno-uninitialized"
;;
- sparc-*)
+ *-solaris*|*-sunos*)
# The solaris headers for pthreads are not ANSI :-(
case $thread_safe in true)
ANSI_OPTS=""
--
Fergus Henderson <fjh at cs.mu.oz.au> | "I have always known that the pursuit
WWW: <http://www.cs.mu.oz.au/~fjh> | of excellence is a lethal habit"
PGP: finger fjh at 128.250.37.3 | -- the last words of T. S. Garp.
More information about the developers
mailing list