Commit | Line | Data |
8e07c86e |
1 | # hints/hpux.sh |
2 | # Perl Configure hints file for Hewlett Packard HP/UX 9.x and 10.x |
3 | # This file is based on |
4 | # hints/hpux_9.sh, Perl Configure hints file for Hewlett Packard HP/UX 9.x |
5 | # Use Configure -Dcc=gcc to use gcc. |
6 | # From: Jeff Okamoto <okamoto@hpcc123.corp.hp.com> |
7 | # Date: Thu, 28 Sep 95 11:06:07 PDT |
8 | # and |
9 | # hints/hpux_10.sh, Perl Configure hints file for Hewlett Packard HP/UX 10.x |
10 | # From: Giles Lean <giles@nemeton.com.au> |
11 | # Date: Tue, 27 Jun 1995 08:17:45 +1000 |
12 | |
13 | # Use Configure -Dcc=gcc to use gcc. |
14 | # Use Configure -Dprefix=/usr/local to install in /usr/local. |
15 | |
4633a7c4 |
16 | # Some users have reported problems with dynamic loading if the |
17 | # environment variable LDOPTS='-a archive' . |
18 | |
8e07c86e |
19 | # Turn on the _HPUX_SOURCE flag to get many of the HP add-ons |
20 | ccflags="$ccflags -D_HPUX_SOURCE" |
21 | ldflags="$ldflags" |
22 | |
23 | # Check if you're using the bundled C compiler. This compiler doesn't support |
24 | # ANSI C (the -Aa flag) nor can it produce shared libraries. Thus we have |
25 | # to turn off dynamic loading. |
26 | case "$cc" in |
a5f75d66 |
27 | '') if cc $ccflags -Aa 2>&1 | $contains 'option' >/dev/null |
8e07c86e |
28 | then |
29 | case "$usedl" in |
30 | '') usedl="$undef" |
31 | cat <<'EOM' |
32 | |
33 | The bundled C compiler can not produce shared libraries, so you will |
34 | not be able to use dynamic loading. |
35 | |
36 | EOM |
37 | ;; |
38 | esac |
39 | else |
40 | ccflags="$ccflags -Aa" # The add-on compiler supports ANSI C |
41 | fi |
42 | optimize='-O' |
43 | ;; |
44 | esac |
45 | |
4633a7c4 |
46 | # Determine the architecture type of this system. |
47 | xxuname=`uname -r` |
48 | if echo $xxuname | $contains '10' |
49 | then |
50 | # This system is running 10.0 |
51 | xxcontext=`grep $(printf %#x $(getconf CPU_VERSION)) /usr/include/sys/unistd.h` |
52 | if echo "$xxcontext" | $contains 'PA-RISC1.1' |
53 | then |
54 | archname='PA-RISC1.1' |
55 | elif echo "$xxcontext" | $contains 'PA-RISC1.0' |
56 | then |
57 | archname='PA-RISC1.0' |
58 | elif echo "$xxcontext" | $contains 'PA-RISC2' |
59 | then |
60 | archname='PA-RISC2' |
61 | else |
62 | echo "This 10.0 system is of a PA-RISC type I don't recognize." |
63 | echo "Debugging output: $xxcontext" |
64 | archname='' |
65 | fi |
66 | else |
67 | # This system is not running 10.0 |
68 | xxcontext=`/bin/getcontext` |
69 | if echo "$xxcontext" | $contains 'PA-RISC1.1' |
70 | then |
71 | archname='PA-RISC1.1' |
72 | elif echo "$xxcontext" | $contains 'PA-RISC1.0' |
73 | then |
74 | archname='PA-RISC1.0' |
75 | elif echo "$xxcontext" | $contains 'HP-MC' |
76 | then |
77 | archname='HP-MC68K' |
78 | else |
79 | echo "I cannot recognize what chip set this system is using." |
80 | echo "Debugging output: $xxcontext" |
81 | archname='' |
82 | fi |
83 | fi |
84 | |
8e07c86e |
85 | # Remove bad libraries that will cause problems |
86 | # (This doesn't remove libraries that don't actually exist) |
87 | # -lld is unneeded (and I can't figure out what it's used for anyway) |
88 | # -ldbm is obsolete and should not be used |
89 | # -lBSD contains BSD-style duplicates of SVR4 routines that cause confusion |
90 | # -lPW is obsolete and should not be used |
8e07c86e |
91 | # The libraries crypt, malloc, ndir, and net are empty. |
0ca047c2 |
92 | # Although -lndbm should be included, it will make perl blow up if you should |
93 | # copy the binary to a system without libndbm.sl. See ccdlflags below. |
94 | set `echo " $libswanted " | sed -e 's@ ld @ @' -e 's@ dbm @ @' -e 's@ BSD @ @' -e 's@ PW @ @'` |
8e07c86e |
95 | libswanted="$*" |
96 | |
97 | # If you copy the perl binaries to other systems and the dynamic loader |
98 | # complains about missing libraries, you can either copy the shared libraries |
99 | # or switch the comments to recompile perl to use archive libraries |
100 | # ccdlflags="-Wl,-E -Wl,-a,archive $ccdlflags" |
101 | ccdlflags="-Wl,-E $ccdlflags" |
102 | |
103 | usemymalloc='y' |
104 | alignbytes=8 |
105 | selecttype='int *' |
106 | |
107 | # There are some lingering issues about whether g/setpgrp should be a part |
108 | # of the perl core. This setting should cause perl to conform to the Principle |
109 | # of Least Astonishment. The best thing is to use the g/setpgrp in the POSIX |
110 | # module. |
111 | d_bsdpgrp='define' |
112 | |
113 | # If your compile complains about FLT_MIN, uncomment the next line |
114 | # POSIX_cflags='ccflags="$ccflags -DFLT_MIN=1.17549435E-38"' |
115 | |
4633a7c4 |
116 | # Comment this out if you don't want to follow the SVR4 filesystem layout |
8e07c86e |
117 | # that HP-UX 10.0 uses |
118 | case "$prefix" in |
4633a7c4 |
119 | '') prefix='/opt/perl5' ;; |
8e07c86e |
120 | esac |