Fix build on OpenBSD/amd64 5.2.

Add config for OpenBSD.
This commit is contained in:
ryoon 2013-01-05 10:37:56 +00:00
parent 3988c0d8f5
commit 0f34fb0b37
3 changed files with 28 additions and 7 deletions

View file

@ -1,4 +1,4 @@
# $NetBSD: Makefile,v 1.30 2012/12/16 01:52:36 obache Exp $
# $NetBSD: Makefile,v 1.31 2013/01/05 10:37:56 ryoon Exp $
DISTNAME= xmlrpc-c-1.16.44
# the "super stable" branch
@ -37,6 +37,8 @@ SUBST_FILES.pthread= xmlrpc-c-config.* xmlrpc-c-config.test.*
SUBST_SED.pthread= -e 's/-lpthread/${PTHREAD_LINKFLAGS:Q}/'
SUBST_SED.pthread+= -e 's/-L\(.\)libdir/-L\1libdir ${COMPILER_RPATH_FLAG}\1libdir/'
LDFLAGS.OpenBSD+= ${PTHREAD_LINKFLAGS}
.include "../../www/curl/buildlink3.mk"
.include "../../www/libwww/buildlink3.mk"
.include "../../mk/pthread.buildlink3.mk"

View file

@ -1,4 +1,4 @@
$NetBSD: distinfo,v 1.27 2012/12/15 18:33:28 adam Exp $
$NetBSD: distinfo,v 1.28 2013/01/05 10:37:56 ryoon Exp $
SHA1 (xmlrpc-c-1.16.44.tgz) = 181c54ac860698ed7cf4e3814c6f3c6dd46b2ce1
RMD160 (xmlrpc-c-1.16.44.tgz) = c9293bb74bf6298d6dd6529669f86d4cddd1fcf8
@ -10,7 +10,7 @@ SHA1 (patch-ae) = 52f826d292869be44886881c48aa7707a4af2df3
SHA1 (patch-ai) = e7b981f07d4691bbd63bfa80b34b3e1c050c3ad2
SHA1 (patch-aj) = e3ca062349eb7c50cf3d3dc1370744987a0f3bde
SHA1 (patch-ak) = 2d0528260b203965e5237f5ca7f9464215283f5c
SHA1 (patch-config.mk.in) = 48c5ead1c6ed9993259188eaac8c2df9c89d2c74
SHA1 (patch-config.mk.in) = 9b85954b7ef5962ff3750ccd78392e5c7bdbd592
SHA1 (patch-examples_cpp_Makefile) = 3c2ca9b50a587c6a6395aec292ca643605158171
SHA1 (patch-lib_curl__transport_curlmulti.c) = 1cea4c43b1ed3dcf73827afc14d7bb9267371121
SHA1 (patch-lib_curl__transport_curltransaction.c) = 1dcf46c0dd1dd8e7fdfbb6c81e00b326f6d0b1f9

View file

@ -1,11 +1,11 @@
$NetBSD: patch-config.mk.in,v 1.1 2012/07/25 15:49:34 jperkin Exp $
$NetBSD: patch-config.mk.in,v 1.2 2013/01/05 10:37:56 ryoon Exp $
Do not use -Bdynamic -G when using GCC on Solaris, it creates non-PIC
libraries.
--- config.mk.in.orig 2012-07-25 15:14:31.150813087 +0000
+++ config.mk.in 2012-07-25 15:16:38.062750186 +0000
@@ -187,10 +187,15 @@
--- config.mk.in.orig 2011-03-25 16:58:35.000000000 +0000
+++ config.mk.in
@@ -187,10 +187,15 @@ ifeq ($(patsubst solaris%,solaris,$(HOST
SHLIB_SUFFIX = so
shlibfn = $(1:%=%.$(SHLIB_SUFFIX).$(MAJ).$(MIN))
shliblefn = $(1:%=%.$(SHLIB_SUFFIX))
@ -25,3 +25,22 @@ libraries.
endif
ifeq ($(patsubst aix%,aix,$(HOST_OS)),aix)
@@ -235,6 +240,18 @@ ifeq ($(patsubst netbsd%,netbsd,$(HOST_O
NEED_WL_RPATH=yes
endif
+ifeq ($(patsubst openbsd%,openbsd,$(HOST_OS)),openbsd)
+ SHARED_LIB_TYPE = unix
+ SHLIB_SUFFIX = so
+ MUST_BUILD_SHLIB = Y
+ MUST_BUILD_SHLIBLE = Y
+ shlibfn = $(1:%=%.$(SHLIB_SUFFIX).$(MAJ).$(MIN))
+ shliblefn = $(1:%=%.$(SHLIB_SUFFIX))
+ CFLAGS_SHLIB = -fpic
+ LDFLAGS_SHLIB = -shared -Wl,-soname,$(SONAME) $(SHLIB_CLIB)
+ NEED_WL_RPATH=yes
+endif
+
ifeq ($(patsubst freebsd%,freebsd,$(HOST_OS)),freebsd)
SHARED_LIB_TYPE = unix
SHLIB_SUFFIX = so