Commit | Line | Data |
a0d0e21e |
1 | # hints/netbsd.sh |
4633a7c4 |
2 | # |
3 | # talk to mrg@eterna.com.au if you want to change this file. |
4 | # |
5 | # netbsd keeps dynamic loading dl*() functions in /usr/lib/crt0.o, |
232e078e |
6 | # so Configure doesn't find them (unless you abandon the nm scan). |
4633a7c4 |
7 | # this should be *just* 0.9 below as netbsd 0.9a was the first to |
c9ef717e |
8 | # introduce shared libraries. however, they don't work/build on |
9 | # pmax, powerpc and alpha ports correctly, yet. |
10 | |
11 | case "$archname" in |
12 | '') |
13 | archname=`uname -m`-${osname} |
14 | ;; |
15 | esac |
16 | |
a0d0e21e |
17 | case "$osvers" in |
4633a7c4 |
18 | 0.9|0.8*) |
a0d0e21e |
19 | usedl="$undef" |
20 | ;; |
c9ef717e |
21 | *) |
22 | case `uname -m` in |
23 | alpha|powerpc|pmax) |
24 | d_dlopen=$undef |
25 | ;; |
26 | # this doesn't work (yet). |
27 | # alpha) |
28 | # d_dlopen=$define |
29 | # d_dlerror=$define |
30 | # cccdlflags="-DPIC -fPIC $cccdlflags" |
31 | # lddlflags="-shared $lddlflags" |
32 | # ;; |
33 | *) |
34 | d_dlopen=$define |
35 | d_dlerror=$define |
4633a7c4 |
36 | # we use -fPIC here because -fpic is *NOT* enough for some of the |
37 | # extensions like Tk on some netbsd platforms (the sparc is one) |
c9ef717e |
38 | cccdlflags="-DPIC -fPIC $cccdlflags" |
39 | lddlflags="-Bforcearchive -Bshareable $lddlflags" |
40 | ;; |
41 | esac |
42 | ;; |
43 | esac |
491527d0 |
44 | # netbsd 1.3 linker warns about setr[gu]id being deprecated. |
45 | # (setregid, setreuid, preferred?) |
46 | case "$osvers" in |
47 | 1.3|1.3*) |
48 | d_setrgid="$undef" |
49 | d_setruid="$undef" |
50 | ;; |
51 | esac |
c9ef717e |
52 | |
53 | # netbsd had these but they don't really work as advertised, in the |
54 | # versions listed below. if they are defined, then there isn't a |
55 | # way to make perl call setuid() or setgid(). if they aren't, then |
56 | # ($<, $>) = ($u, $u); will work (same for $(/$)). this is because |
57 | # you can not change the real userid of a process under 4.4BSD. |
58 | # netbsd fixed this in 1.2A. |
229e211d |
59 | case "$osvers" in |
c9ef717e |
60 | 0.9*|1.0*|1.1*|1.2_*|1.2|1.2.*) |
4633a7c4 |
61 | d_setregid="$undef" |
62 | d_setreuid="$undef" |
63 | d_setrgid="$undef" |
64 | d_setruid="$undef" |
a0d0e21e |
65 | ;; |
66 | esac |
c6c5e21e |
67 | # netbsd 1.3 linker warns about setr[gu]id being deprecated. |
68 | # (setregid, setreuid, preferred?) |
69 | case "$osvers" in |
70 | 1.3|1.3*) |
71 | d_setrgid="$undef" |
72 | d_setruid="$undef" |
73 | ;; |
74 | esac |
6ee623d5 |
75 | |
76 | # vfork is ok on NetBSD. |
77 | case "$usevfork" in |
78 | '') usevfork=true ;; |
79 | esac |