Munge pseudo-Configure stuff to add -thread to archname as
[p5sagit/p5-mst-13.2.git] / hints / sunos_4_1.sh
CommitLineData
0093f865 1# hints/sunos_4_1.sh
2# Last modified: Thu Feb 8 11:46:05 EST 1996
3# Andy Dougherty <doughera@lafcol.lafayette.edu>
4
a0d0e21e 5case "$cc" in
54000519 6*gcc*) usevfork=false
7 # GNU as and GNU ld might not work. See the INSTALL file.
8 ;;
a0d0e21e 9*) usevfork=true ;;
10esac
0093f865 11
12# Configure will issue a WHOA warning. The problem is that
13# Configure finds getzname, not tzname. If you're in the System V
14# environment, you can set d_tzname='define' since tzname[] is
15# available in the System V environment.
a0d0e21e 16d_tzname='undef'
0093f865 17
54000519 18# Configure will issue a WHOA warning. The problem is that unistd.h
19# contains incorrect prototypes for some functions in the usual
20# BSD-ish environment. In particular, it has
21# extern int getgroups(/* int gidsetsize, gid_t grouplist[] */);
22# but groupslist[] ought to be of type int, not gid_t.
23# This is only really a problem for perl if the
24# user is using gcc, and not running in the SysV environment.
25# The gcc fix-includes script exposes those incorrect prototypes.
26# There may be other examples as well. Volunteers are welcome to
27# track them all down :-). In the meantime, we'll just skip unistd.h
84902520 28# for SunOS in most of the code. The POSIX extension is built with
29# unistd.h because, even though unistd.h has problems, if used with
30# care, it helps create a better POSIX extension.
54000519 31i_unistd='undef'
32
33cat << 'EOM' >&4
34
35You will probably see *** WHOA THERE!!! *** messages from Configure for
36d_tzname and i_unistd. Keep the recommended values. See
37hints/sunos_4_1.sh for more information.
38EOM
39
0093f865 40# SunOS 4.1.3 has two extra fields in struct tm. This works around
41# the problem. Other BSD platforms may have similar problems.
42POSIX_cflags='ccflags="$ccflags -DSTRUCT_TM_HASZONE"'
43
137a3082 44# The correct setting of groupstype depends on which version of the C
45# library is used. If you are in the 'System V environment'
46# (i.e. you have /usr/5bin ahead of /usr/bin in your PATH), and
47# you use Sun's cc compiler, then you'll pick up /usr/5bin/cc, which
48# links against the C library in /usr/5lib. This library has
49# groupstype='gid_t'.
50# If you are in the normal BSDish environment, then you'll pick up
51# /usr/ucb/cc, which links against the C library in /usr/lib. That
52# library has groupstype='int'.
53#
54# If you are using gcc, it links against the C library in /usr/lib
55# independent of whether or not you are in the 'System V environment'.
56# If you want to use the System V libraries, then you need to
57# manually set groupstype='gid_t' and add explicit references to
58# /usr/5lib when Configure prompts you for where to look for libraries.
59#
90248788 60# Check if user is in a bsd or system 5 type environment
a0d0e21e 61if cat -b /dev/null 2>/dev/null
62then # bsd
63 groupstype='int'
64else # sys5
137a3082 65 case "$cc" in
66 *gcc*) groupstype='int';; # gcc doesn't do anything special
67 *) groupstype='gid_t';; # /usr/5bin/cc pulls in /usr/5lib/ stuff.
68 esac
a0d0e21e 69fi
77c65e92 70
71# If you get the message "unresolved symbol '__lib_version' " while
72# linking, your system probably has the optional 'acc' compiler (and
73# libraries) installed, but you are using the bundled 'cc' compiler with
74# the unbundled libraries. The solution is either to use 'acc' and the
75# unbundled libraries (specifically /lib/libm.a), or 'cc' and the bundled
76# library.
77#
78# Thanks to William Setzer <William_Setzer@ncsu.edu> for this info.