Commit | Line | Data |
0e9bad51 |
1 | # hints/bsdos.sh |
25f94b33 |
2 | # |
0806a92f |
3 | # hints file for BSD/OS (adapted from bsd386.sh) |
4 | # Original by Neil Bowers <neilb@khoros.unm.edu>; Tue Oct 4 12:01:34 EDT 1994 |
5 | # Updated by Tony Sanders <sanders@bsdi.com>; Sat Aug 23 12:47:45 MDT 1997 |
572149b7 |
6 | # Added 3.1 with ELF dynamic libraries (NOT in 3.1 yet. |
7 | # Estimated for 4.0) SYSV IPC tested Ok so I re-enabled. |
8 | # |
9 | # Updated to work in post-4.0 by Todd C. Miller <millert@openbsd.org> |
10 | # |
11 | # Updated for threads by "Timur I. Bakeyev" <bsdi@listserv.bat.ru> |
25f94b33 |
12 | # |
0806a92f |
13 | # To override the compiler on the command line: |
14 | # ./Configure -Dcc=gcc2 |
15 | # |
16 | # The BSD/OS distribution is built with: |
17 | # ./Configure -des -Dbsdos_distribution=defined |
25f94b33 |
18 | |
25f94b33 |
19 | signal_t='void' |
0e9bad51 |
20 | d_voidsig='define' |
25f94b33 |
21 | |
0806a92f |
22 | usemymalloc='n' |
23 | |
da0b61dd |
24 | # malloc wrap works |
25 | case "$usemallocwrap" in |
26 | '') usemallocwrap='define' ;; |
27 | esac |
28 | |
0806a92f |
29 | # setre?[ug]id() have been replaced by the _POSIX_SAVED_IDS versions. |
572149b7 |
30 | # See <A HREF="http://www.bsdi.com/bsdi-man?setuid">http://www.bsdi.com/bsdi-man?setuid</A>(2) |
0806a92f |
31 | d_setregid='undef' |
32 | d_setreuid='undef' |
33 | d_setrgid='undef' |
34 | d_setruid='undef' |
35 | |
0e9bad51 |
36 | # we don't want to use -lnm, since exp() is busted (in 1.1 anyway) |
25f94b33 |
37 | set `echo X "$libswanted "| sed -e 's/ nm / /'` |
38 | shift |
39 | libswanted="$*" |
40 | |
0806a92f |
41 | # X libraries are in their own tree |
0e9bad51 |
42 | glibpth="$glibpth /usr/X11/lib" |
43 | ldflags="$ldflags -L/usr/X11/lib" |
44 | |
0806a92f |
45 | case "$optimize" in |
46 | '') optimize='-O2' ;; |
47 | esac |
48 | |
0e9bad51 |
49 | case "$bsdos_distribution" in |
0806a92f |
50 | ''|undef|false) ;; |
51 | *) |
52 | d_dosuid='define' |
53 | d_portable='undef' |
0e9bad51 |
54 | prefix='/usr/contrib' |
0806a92f |
55 | perlpath='/usr/bin/perl5' |
56 | startperl='#!/usr/bin/perl5' |
57 | scriptdir='/usr/contrib/bin' |
58 | privlib='/usr/libdata/perl5' |
59 | man1dir='/usr/contrib/man/man1' |
0e9bad51 |
60 | man3dir='/usr/contrib/man/man3' |
0806a92f |
61 | # phlib added by BSDI -- we share the *.ph include dir with perl4 |
62 | phlib="/usr/libdata/perl5/site_perl/$(arch)-$osname/include" |
63 | phlibexp="/usr/libdata/perl5/site_perl/$(arch)-$osname/include" |
0e9bad51 |
64 | ;; |
65 | esac |
66 | |
25f94b33 |
67 | case "$osvers" in |
68 | 1.0*) |
69 | # Avoid problems with HUGE_VAL in POSIX in 1.0's cc. |
70 | POSIX_cflags='ccflags="$ccflags -UHUGE_VAL"' |
71 | ;; |
72 | 1.1*) |
0e9bad51 |
73 | # Use gcc2 |
25f94b33 |
74 | case "$cc" in |
0e9bad51 |
75 | '') cc='gcc2' ;; |
25f94b33 |
76 | esac |
77 | ;; |
a2588af8 |
78 | 2.0*|2.1*|3.0*|3.1*) |
0806a92f |
79 | so='o' |
d84bea6a |
80 | |
0806a92f |
81 | # default to GCC 2.X w/shared libraries |
d84bea6a |
82 | case "$cc" in |
83 | '') cc='shlicc2' |
84 | cccdlflags=' ' ;; # Avoid the dreaded -fpic |
85 | esac |
86 | |
0806a92f |
87 | # default ld to shared library linker |
d84bea6a |
88 | case "$ld" in |
89 | '') ld='shlicc2' |
90 | lddlflags='-r' ;; # this one is necessary |
91 | esac |
92 | |
0806a92f |
93 | # Must preload the static shared libraries. |
c20f90ab |
94 | libswanted="Xpm Xaw Xmu Xt SM ICE Xext X11 $libswanted" |
95 | libswanted="rpc curses termcap $libswanted" |
d84bea6a |
96 | ;; |
572149b7 |
97 | 4.*) |
98 | # ELF dynamic link libraries starting in 4.0 |
491527d0 |
99 | useshrplib='true' |
100 | so='so' |
101 | dlext='so' |
102 | |
103 | case "$cc" in |
104 | '') cc='cc' # cc is gcc2 in 4.0 |
105 | cccdlflags="-fPIC" |
b250498f |
106 | ;; |
491527d0 |
107 | esac |
108 | |
109 | case "$ld" in |
110 | '') ld='ld' |
111 | lddlflags="-shared -x $lddlflags" ;; |
112 | esac |
572149b7 |
113 | # Due usage of static pointer from crt.o |
114 | libswanted="util $libswanted" ;; |
25f94b33 |
115 | esac |
491527d0 |
116 | |
572149b7 |
117 | # This script UU/usethreads.cbu will get 'called-back' by Configure |
118 | # after it has prompted the user for whether to use threads. |
119 | cat > UU/usethreads.cbu <<'EOCBU' |
120 | case "$usethreads" in |
121 | $define|true|[yY]*) |
122 | case "$osvers" in |
123 | 3.*|4.*) ccflags="-D_REENTRANT $ccflags" |
124 | ;; |
125 | *) cat <<EOM >&4 |
126 | I did not know that BSD/OS $osvers supports POSIX threads. |
127 | |
7f2de2d2 |
128 | Feel free to tell perlbug@perl.org otherwise. |
572149b7 |
129 | EOM |
130 | exit 1 |
131 | ;; |
132 | esac |
133 | ;; |
134 | esac |
135 | EOCBU |