diff options
author | ponce <matteo.bernardini@gmail.com> | 2012-08-09 21:21:54 +0200 |
---|---|---|
committer | Robby Workman <rworkman@slackbuilds.org> | 2012-08-21 20:08:25 -0500 |
commit | 8ad56b83a029c130bef5fae2a05345dce47c5b55 (patch) | |
tree | 1a99bee37aea99c529d6bdcb422eaa279cb0a2d0 /libraries | |
parent | ee8df823970ffd5754563af3fdb9898f2ad73649 (diff) |
libraries/wvstreams: Various build fixes
Added a patch for parallel builds, two more to fix building on
14.0, and some compiler flags needed for the new gcc-4.7.x.
Signed-off-by: Robby Workman <rworkman@slackbuilds.org>
Diffstat (limited to 'libraries')
-rw-r--r-- | libraries/wvstreams/patches/05_gcc.diff | 41 | ||||
-rw-r--r-- | libraries/wvstreams/patches/wvstreams-4.6.1-gcc47.patch | 10 | ||||
-rw-r--r-- | libraries/wvstreams/patches/wvstreams-4.6.1-parallel-make.patch | 58 | ||||
-rw-r--r-- | libraries/wvstreams/wvstreams-4.6.1-glibc212.patch | 23 | ||||
-rw-r--r-- | libraries/wvstreams/wvstreams.SlackBuild | 18 |
5 files changed, 122 insertions, 28 deletions
diff --git a/libraries/wvstreams/patches/05_gcc.diff b/libraries/wvstreams/patches/05_gcc.diff new file mode 100644 index 0000000000000..8e4fd03298267 --- /dev/null +++ b/libraries/wvstreams/patches/05_gcc.diff @@ -0,0 +1,41 @@ +Index: wvstreams-4.6.1/crypto/wvx509.cc +=================================================================== +--- wvstreams-4.6.1.orig/crypto/wvx509.cc 2011-05-20 00:02:38.119136584 +0200 ++++ wvstreams-4.6.1/crypto/wvx509.cc 2011-05-20 00:02:26.035136589 +0200 +@@ -1157,7 +1157,7 @@ + + if (ext) + { +- X509V3_EXT_METHOD *method = X509V3_EXT_get(ext); ++ X509V3_EXT_METHOD *method = (X509V3_EXT_METHOD *)X509V3_EXT_get(ext); + if (!method) + { + WvDynBuf buf; +Index: wvstreams-4.6.1/ipstreams/wvunixdgsocket.cc +=================================================================== +--- wvstreams-4.6.1.orig/ipstreams/wvunixdgsocket.cc 2011-05-20 00:02:38.391136584 +0200 ++++ wvstreams-4.6.1/ipstreams/wvunixdgsocket.cc 2011-05-20 00:02:35.283136585 +0200 +@@ -1,8 +1,6 @@ + #include "wvunixdgsocket.h" +-#ifdef MACOS + #include <sys/types.h> + #include <sys/stat.h> +-#endif + + WvUnixDGSocket::WvUnixDGSocket(WvStringParm filename, bool _server, int perms) + : socketfile(filename) +Index: wvstreams-4.6.1/streams/wvatomicfile.cc +=================================================================== +--- wvstreams-4.6.1.orig/streams/wvatomicfile.cc 2011-05-20 00:02:38.223136584 +0200 ++++ wvstreams-4.6.1/streams/wvatomicfile.cc 2011-05-20 00:02:31.619136587 +0200 +@@ -10,10 +10,7 @@ + #include "wvatomicfile.h" + #include "wvfileutils.h" + #include "wvstrutils.h" +- +-#ifdef MACOS + #include <sys/stat.h> +-#endif + + WvAtomicFile::WvAtomicFile(WvStringParm filename, int flags, mode_t create_mode) + : tmp_file(WvString::null) diff --git a/libraries/wvstreams/patches/wvstreams-4.6.1-gcc47.patch b/libraries/wvstreams/patches/wvstreams-4.6.1-gcc47.patch new file mode 100644 index 0000000000000..3d67048324543 --- /dev/null +++ b/libraries/wvstreams/patches/wvstreams-4.6.1-gcc47.patch @@ -0,0 +1,10 @@ +--- wvstreams-4.6.1-dist/include/wvuid.h 2012-01-05 10:18:58.713661236 +0100 ++++ wvstreams-4.6.1/include/wvuid.h 2012-01-05 10:27:42.198435328 +0100 +@@ -7,6 +7,7 @@ + #ifndef __WVUID_H + #define __WVUID_H + ++#include <unistd.h> + #include "wvstring.h" + + #if WIN32 diff --git a/libraries/wvstreams/patches/wvstreams-4.6.1-parallel-make.patch b/libraries/wvstreams/patches/wvstreams-4.6.1-parallel-make.patch new file mode 100644 index 0000000000000..5ad79fd7a9a63 --- /dev/null +++ b/libraries/wvstreams/patches/wvstreams-4.6.1-parallel-make.patch @@ -0,0 +1,58 @@ +diff -ur wvstreams-4.6.1.orig/Makefile wvstreams-4.6.1/Makefile +--- wvstreams-4.6.1.orig/Makefile 2009-09-16 00:26:50.000000000 +0300 ++++ wvstreams-4.6.1/Makefile 2010-01-04 18:06:15.000000000 +0200 +@@ -131,12 +131,19 @@ + # libwvstreams: stream/event handling library + # + TARGETS += libwvstreams.so +-TARGETS += crypto/tests/ssltest ipstreams/tests/unixtest ++TARGETS += crypto/tests/ssltest ++crypto/tests/ssltest: $(LIBWVSTREAMS) ++ ++TARGETS += ipstreams/tests/unixtest ++ipstreams/tests/unixtest: $(LIBWVSTREAMS) ++ + TARGETS += crypto/tests/printcert ++crypto/tests/printcert: $(LIBWVSTREAMS) + + ifndef _MACOS + ifneq ("$(with_readline)", "no") + TARGETS += ipstreams/tests/wsd ++ ipstreams/tests/wsd: $(LIBWVSTREAMS) + ipstreams/tests/wsd-LIBS += -lreadline + else + TEST_SKIP_OBJS += ipstreams/tests/wsd +@@ -179,7 +186,11 @@ + # + ifneq ("$(with_dbus)", "no") + TARGETS += libwvdbus.so +- TARGETS += dbus/tests/wvdbus dbus/tests/wvdbusd ++ TARGETS += dbus/tests/wvdbus ++ dbus/tests/wvdbus: $(LIBWVDBUS) ++ ++ TARGETS += dbus/tests/wvdbusd ++ dbus/tests/wvdbusd: $(LIBWVDBUS) + TESTS += $(call tests_cc,dbus/tests) + libwvdbus_OBJS += $(call objects,dbus) + libwvdbus.so: $(libwvdbus_OBJS) $(LIBWVSTREAMS) +diff -ur wvstreams-4.6.1.orig/wvrules-posix.mk wvstreams-4.6.1/wvrules-posix.mk +--- wvstreams-4.6.1.orig/wvrules-posix.mk 2008-10-21 18:31:58.000000000 +0300 ++++ wvstreams-4.6.1/wvrules-posix.mk 2010-01-04 18:04:00.000000000 +0200 +@@ -85,12 +85,15 @@ + $(AR) s $1 + endef + +-CC: FORCE ++CC: + @CC="$(CC)" CFLAGS="$(CFLAGS)" CPPFLAGS="$(CPPFLAGS)" \ + $(WVSTREAMS)/gen-cc CC c + +-CXX: FORCE ++CXX: + @CC="$(CXX)" CFLAGS="$(CXXFLAGS)" CPPFLAGS="$(CPPFLAGS)" \ + $(WVSTREAMS)/gen-cc CXX cc + ++#All files must depend on the above two rules. This is a godawful hack. ++$(shell find -type f '(' -name '*.c' -o -name '*.cc' ')' ): CC CXX ++ + wvlink=$(LINK_MSG)$(WVLINK_CC) $(LDFLAGS) $($1-LDFLAGS) -o $1 $(filter %.o %.a %.so, $2) $($1-LIBS) $(XX_LIBS) $(LDLIBS) $(PRELIBS) $(LIBS) diff --git a/libraries/wvstreams/wvstreams-4.6.1-glibc212.patch b/libraries/wvstreams/wvstreams-4.6.1-glibc212.patch deleted file mode 100644 index 473d3e8329332..0000000000000 --- a/libraries/wvstreams/wvstreams-4.6.1-glibc212.patch +++ /dev/null @@ -1,23 +0,0 @@ -http://bugs.gentoo.org/333301 - ---- ipstreams/wvunixdgsocket.cc -+++ ipstreams/wvunixdgsocket.cc -@@ -1,5 +1,5 @@ - #include "wvunixdgsocket.h" --#ifdef MACOS -+#if defined(MACOS) || defined(__GNUC__) - #include <sys/types.h> - #include <sys/stat.h> - #endif ---- streams/wvatomicfile.cc -+++ streams/wvatomicfile.cc -@@ -11,7 +11,8 @@ - #include "wvfileutils.h" - #include "wvstrutils.h" - --#ifdef MACOS -+#if defined(MACOS) || defined(__GNUC__) -+#include <sys/types.h> - #include <sys/stat.h> - #endif - diff --git a/libraries/wvstreams/wvstreams.SlackBuild b/libraries/wvstreams/wvstreams.SlackBuild index ebe4b85968f18..8575b8f8c5205 100644 --- a/libraries/wvstreams/wvstreams.SlackBuild +++ b/libraries/wvstreams/wvstreams.SlackBuild @@ -6,7 +6,7 @@ PRGNAM=wvstreams VERSION=4.6.1 -BUILD=${BUILD:-1} +BUILD=${BUILD:-2} TAG=${TAG:-_SBo} if [ -z "$ARCH" ]; then @@ -51,13 +51,21 @@ find . \ \( -perm 666 -o -perm 664 -o -perm 600 -o -perm 444 -o -perm 440 -o -perm 400 \) \ -exec chmod 644 {} \; -# Fix a build error with glibc-2.12.x -patch -p0 < $CWD/wvstreams-4.6.1-glibc212.patch +# patch to allow parallel builds +patch -p1 < $CWD/patches/wvstreams-4.6.1-parallel-make.patch + +# patch for gcc-4.7 +# https://code.google.com/p/wvstreams/issues/detail?id=34 +patch -p1 < $CWD/patches/wvstreams-4.6.1-gcc47.patch +# another patch for gcc and glibc > 2.12.0 from debian +patch -p1 < $CWD/patches/05_gcc.diff # configure doesn't support disabling static libraries # Don't manually remove them either, as wvdial won't build then :) -CFLAGS="$SLKCFLAGS" \ -CXXFLAGS="$SLKCFLAGS" \ +# Added more flags to avoid aborting when building with gcc-4.7.x +# https://bugs.gentoo.org/show_bug.cgi?id=419971 +CFLAGS="$SLKCFLAGS -fno-tree-dce -fno-optimize-sibling-calls" \ +CXXFLAGS="$SLKCFLAGS -fno-tree-dce -fno-optimize-sibling-calls" \ ./configure \ --prefix=/usr \ --libdir=/usr/lib${LIBDIRSUFFIX} \ |