$NetBSD: patch-ab,v 1.6 2009/10/27 18:50:39 drochner Exp $ --- Makefile.config.in.orig 2008-03-25 15:24:58.000000000 +0100 +++ Makefile.config.in @@ -155,6 +155,15 @@ ifeq ($(findstring solaris,$(HOST_OS)),s CFLAGS_SHLIB = -Kpic endif +ifeq ($(HOST_OS),solaris2) + SHARED_LIB_TYPE = unix + SHLIB_SUFFIX = so + shlibfn = $(1:%=%.$(SHLIB_SUFFIX).$(MAJ).$(MIN)) + shliblefn = $(1:%=%.$(SHLIB_SUFFIX)) + LDFLAGS_SHLIB = -Wl,-Bdynamic,-G,-h,$(SONAME) + CFLAGS_SHLIB = -Kpic +endif + ifeq ($(HOST_OS),aix) # This code is not finished; that's why we don't set SHARED_LIB_TYPE. # If you can finish it and make it work on AIX, please do. @@ -188,11 +197,30 @@ ifeq ($(HOST_OS),osf) endif ifeq ($(findstring netbsd,$(HOST_OS)),netbsd) - # This code is not finished; that's why we don't set SHARED_LIB_TYPE. - # If you can finish it and make it work on AIX, please do. - # SHARED_LIB_TYPE = unix + SHARED_LIB_TYPE = unix + SHLIB_SUFFIX = so + shlibfn = $(1:%=%.$(SHLIB_SUFFIX).$(MAJ).$(MIN)) + shliblefn = $(1:%=%.$(SHLIB_SUFFIX)) + CFLAGS_SHLIB = -fPIC + LDFLAGS_SHLIB = -shared -Wl,-soname,$(SONAME) $(SHLIB_CLIB) +endif + +ifeq ($(HOST_OS),dragonfly) + SHARED_LIB_TYPE = unix + SHLIB_SUFFIX = so + shlibfn = $(1:%=%.$(SHLIB_SUFFIX).$(MAJ).$(MIN)) + shliblefn = $(1:%=%.$(SHLIB_SUFFIX)) + CFLAGS_SHLIB = -fPIC + LDFLAGS_SHLIB = -shared -Wl,-soname,$(SONAME) $(SHLIB_CLIB) +endif + +ifeq ($(findstring freebsd,$(HOST_OS)),freebsd) + SHARED_LIB_TYPE = unix SHLIB_SUFFIX = so - CFLAGS_SHLIB = -fpic + shlibfn = $(1:%=%.$(SHLIB_SUFFIX).$(MAJ).$(MIN)) + shliblefn = $(1:%=%.$(SHLIB_SUFFIX)) + CFLAGS_SHLIB = -fPIC + LDFLAGS_SHLIB = -shared -Wl,-soname,$(SONAME) $(SHLIB_CLIB) endif ifeq ($(HOST_OS),darwin)