summaryrefslogtreecommitdiff
path: root/src/template/solaris
blob: 4a9a5651bb028af43b32e7a2af64d0570e506a55 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
if test "$GCC" != yes ; then
  CC="$CC -Xa"			# relaxed ISO C mode
  CFLAGS="-v -DSUNOS4_CC"	# -v is like gcc -Wall
  if test "$enable_debug" != yes; then
    CFLAGS="$CFLAGS -O"		# any optimization breaks debug
  fi
fi

# Pick right test-and-set (TAS) code.  We need out-of-line assembler
# when not using gcc.
case $host in
  sparc-*-solaris*)
	if test "$GCC" != yes ; then
		need_tas=yes
		tas_file=solaris_sparc.s
	fi
    ;;
  i?86-*-solaris*)
	if test "$GCC" != yes ; then
		soarch=`isainfo`
		if isainfo | grep amd64
		then
			need_tas=yes
			tas_file=solaris_x86_64.s
		else
			need_tas=yes
			tas_file=solaris_i386.s
		fi
	fi
    ;;
esac

# -D_POSIX_PTHREAD_SEMANTICS enables 5-arg getpwuid_r, among other things