summary refs log tree commit diff
path: root/zshconfig.ac
diff options
context:
space:
mode:
Diffstat (limited to 'zshconfig.ac')
-rw-r--r--zshconfig.ac12
1 files changed, 11 insertions, 1 deletions
diff --git a/zshconfig.ac b/zshconfig.ac
index f2b2ea263..3aee9fb08 100644
--- a/zshconfig.ac
+++ b/zshconfig.ac
@@ -1594,6 +1594,16 @@ char *argv[];
       ;;
     esac
   else
+    case "$host" in
+      *openbsd*)
+	DLLD="${DLLD=$CC}"
+	DLLDARG="${LDARG}"
+      ;;
+      * )
+	DLLD="${DLLD=ld}"
+	DLLDARG=""
+      ;;
+    esac
     DLLD="${DLLD=ld}"
     DLLDARG=""
   fi
@@ -1614,7 +1624,7 @@ char *argv[];
     netbsd*)      DLLDFLAGS="${DLLDFLAGS=${DLLDARG}-x -shared --whole-archive}" ;;
     aix*)         DLLDFLAGS="${DLLDFLAGS=-G -bexpall -lc}" ;;
     solaris*|sysv4*|esix*) DLLDFLAGS="${DLLDFLAGS=-G}" ;;
-    openbsd*)     DLLDFLAGS="${DLLDFLAGS=-Bshareable}" ;;
+    openbsd*)     DLLDFLAGS="${DLLDFLAGS=-shared -fPIC}" ;;
   esac
   case "$host" in
     *-hpux*)  EXTRA_LDFLAGS="${EXTRA_LDFLAGS=-Wl,-E}" ;;