summaryrefslogtreecommitdiff
path: root/hints/netbsd.sh
diff options
context:
space:
mode:
authorJarkko Hietaniemi <jhi@iki.fi>2003-07-02 05:21:23 +0000
committerJarkko Hietaniemi <jhi@iki.fi>2003-07-02 05:21:23 +0000
commite36eebf2b283f6eca7d567f41c465c06577584f1 (patch)
tree609536e34a4917f5b978f322ec115a4259cb6acd /hints/netbsd.sh
parentb2611ffd7151da72f6720ecd6efcd9b61d3e4a8e (diff)
downloadperl-e36eebf2b283f6eca7d567f41c465c06577584f1.tar.gz
Move the libgcc.a hack into a section for pre-1.6 NetBSD releases.
The latest releases of NetBSD don't require the hack. From Johnny Lam. p4raw-id: //depot/perl@19920
Diffstat (limited to 'hints/netbsd.sh')
-rw-r--r--hints/netbsd.sh25
1 files changed, 15 insertions, 10 deletions
diff --git a/hints/netbsd.sh b/hints/netbsd.sh
index d246d09fe5..02d730fa0a 100644
--- a/hints/netbsd.sh
+++ b/hints/netbsd.sh
@@ -37,16 +37,21 @@ case "$osvers" in
cccdlflags="-DPIC -fPIC $cccdlflags"
lddlflags="--whole-archive -shared $lddlflags"
rpathflag="-Wl,-rpath,"
- #
- # Include the whole libgcc.a into the perl executable so
- # that certain symbols needed by loadable modules built as
- # C++ objects (__eh_alloc, __pure_virtual, etc.) will always
- # be defined.
- #
- # XXX This should be obsoleted by gcc-3.0.
- #
- ccdlflags="-Wl,-whole-archive -lgcc -Wl,-no-whole-archive \
- -Wl,-E $ccdlflags"
+ case "$osvers" in
+ 1.[0-5]*)
+ #
+ # Include the whole libgcc.a into the perl executable
+ # so that certain symbols needed by loadable modules
+ # built as C++ objects (__eh_alloc, __pure_virtual,
+ # etc.) will always be defined.
+ #
+ ccdlflags="-Wl,-whole-archive -lgcc \
+ -Wl,-no-whole-archive -Wl,-E $ccdlflags"
+ ;;
+ *)
+ ccdlflags="-Wl,-E $ccdlflags"
+ ;;
+ esac
elif test -f /usr/libexec/ld.so; then
# a.out
d_dlopen=$define