mailarchive of the ptxdist mailing list
 help / color / mirror / Atom feed
* [ptxdist] [PATCH 1/2] wvstreams: Add package
@ 2017-10-16 12:15 Sascha Hauer
  2017-10-16 12:15 ` [ptxdist] [PATCH 2/2] wvdial: " Sascha Hauer
  2017-10-16 12:16 ` [ptxdist] [PATCH 1/2] wvstreams: " Sascha Hauer
  0 siblings, 2 replies; 7+ messages in thread
From: Sascha Hauer @ 2017-10-16 12:15 UTC (permalink / raw)
  To: ptxdist

wvstreams is a C++ networking library which is added here because
it's used by wvdial. Upstream for this library is dead, so we
download the package from storage.googleapis.com.

To make it compile the debian patches are added.

WvStreams uses autoconf, but not automake which for us means
that parallel build is broken. Disable parallel build for now.

Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
---
 .../0001-Fix-FTBFS-with-gcc-4.7.patch              | 50 +++++++++++++++
 .../0002-fix-FTBFS-with-OpenSSL-1.0.patch          | 21 +++++++
 .../0003-fix-FTBFS-with-glibc-2.12.patch           | 37 +++++++++++
 .../0004-Fix-compilation-with-gcc-6.patch          | 45 ++++++++++++++
 patches/wvstreams-4.6.1/series                     |  7 +++
 rules/wvstreams.in                                 | 11 ++++
 rules/wvstreams.make                               | 71 ++++++++++++++++++++++
 7 files changed, 242 insertions(+)
 create mode 100644 patches/wvstreams-4.6.1/0001-Fix-FTBFS-with-gcc-4.7.patch
 create mode 100644 patches/wvstreams-4.6.1/0002-fix-FTBFS-with-OpenSSL-1.0.patch
 create mode 100644 patches/wvstreams-4.6.1/0003-fix-FTBFS-with-glibc-2.12.patch
 create mode 100644 patches/wvstreams-4.6.1/0004-Fix-compilation-with-gcc-6.patch
 create mode 100644 patches/wvstreams-4.6.1/series
 create mode 100644 rules/wvstreams.in
 create mode 100644 rules/wvstreams.make

diff --git a/patches/wvstreams-4.6.1/0001-Fix-FTBFS-with-gcc-4.7.patch b/patches/wvstreams-4.6.1/0001-Fix-FTBFS-with-gcc-4.7.patch
new file mode 100644
index 000000000..3d0684666
--- /dev/null
+++ b/patches/wvstreams-4.6.1/0001-Fix-FTBFS-with-gcc-4.7.patch
@@ -0,0 +1,50 @@
+From: Paul Tagliamonte <paultag@ubuntu.com>
+Date: Thu, 28 Sep 2017 15:50:05 +0200
+Subject: [PATCH] Fix FTBFS with gcc-4.7
+
+Small header include change. This is borderlinde cosmetic, but still
+needed to prevent the FTBFS.
+---
+ utils/wvcrash.cc     | 2 +-
+ utils/wvcrashbase.cc | 2 +-
+ utils/wvuid.cc       | 1 +
+ 3 files changed, 3 insertions(+), 2 deletions(-)
+
+diff --git a/utils/wvcrash.cc b/utils/wvcrash.cc
+index 04177598278a..d5e1d8772f92 100644
+--- a/utils/wvcrash.cc
++++ b/utils/wvcrash.cc
+@@ -26,7 +26,7 @@
+ #endif
+ 
+ // FIXME: this file mostly only works in Linux
+-#ifdef __linux
++#if 1
+ 
+ # include <execinfo.h>
+ #include <unistd.h>
+diff --git a/utils/wvcrashbase.cc b/utils/wvcrashbase.cc
+index 8d6702707da2..53e2037827fd 100644
+--- a/utils/wvcrashbase.cc
++++ b/utils/wvcrashbase.cc
+@@ -66,7 +66,7 @@ const char *wvcrash_ring_buffer_get()
+ 
+ 
+ // FIXME: leaving of a will and catching asserts mostly only works in Linux
+-#ifdef __linux
++#if 1
+ 
+ #ifdef __USE_GNU
+ static const char *argv0 = program_invocation_short_name;
+diff --git a/utils/wvuid.cc b/utils/wvuid.cc
+index 7fa10353dc9c..709a484ab35d 100644
+--- a/utils/wvuid.cc
++++ b/utils/wvuid.cc
+@@ -33,6 +33,7 @@ wvuid_t wvgetuid()
+ 
+ #else // not WIN32
+ 
++#include <unistd.h>
+ 
+ WvString wv_username_from_uid(wvuid_t uid)
+ {
diff --git a/patches/wvstreams-4.6.1/0002-fix-FTBFS-with-OpenSSL-1.0.patch b/patches/wvstreams-4.6.1/0002-fix-FTBFS-with-OpenSSL-1.0.patch
new file mode 100644
index 000000000..0e58167dd
--- /dev/null
+++ b/patches/wvstreams-4.6.1/0002-fix-FTBFS-with-OpenSSL-1.0.patch
@@ -0,0 +1,21 @@
+From: Luca Falavigna <dktrkranz@debian.org>
+Date: Thu, 28 Sep 2017 15:51:26 +0200
+Subject: [PATCH] fix FTBFS with OpenSSL 1.0
+
+---
+ crypto/wvx509.cc | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/crypto/wvx509.cc b/crypto/wvx509.cc
+index 93dae06f9ef6..41fa7428a1f9 100644
+--- a/crypto/wvx509.cc
++++ b/crypto/wvx509.cc
+@@ -1157,7 +1157,7 @@ WvString WvX509::get_extension(int nid) const
+         
+         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;
diff --git a/patches/wvstreams-4.6.1/0003-fix-FTBFS-with-glibc-2.12.patch b/patches/wvstreams-4.6.1/0003-fix-FTBFS-with-glibc-2.12.patch
new file mode 100644
index 000000000..af1dfcfc6
--- /dev/null
+++ b/patches/wvstreams-4.6.1/0003-fix-FTBFS-with-glibc-2.12.patch
@@ -0,0 +1,37 @@
+From: Luca Falavigna <dktrkranz@debian.org>
+Date: Thu, 28 Sep 2017 15:52:12 +0200
+Subject: [PATCH] fix FTBFS with glibc 2.12
+
+---
+ ipstreams/wvunixdgsocket.cc | 2 --
+ streams/wvatomicfile.cc     | 3 ---
+ 2 files changed, 5 deletions(-)
+
+diff --git a/ipstreams/wvunixdgsocket.cc b/ipstreams/wvunixdgsocket.cc
+index 41d2911f71ff..c8b539f80795 100644
+--- a/ipstreams/wvunixdgsocket.cc
++++ b/ipstreams/wvunixdgsocket.cc
+@@ -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)
+diff --git a/streams/wvatomicfile.cc b/streams/wvatomicfile.cc
+index 65ae202ff387..e249a149f7bd 100644
+--- a/streams/wvatomicfile.cc
++++ b/streams/wvatomicfile.cc
+@@ -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/patches/wvstreams-4.6.1/0004-Fix-compilation-with-gcc-6.patch b/patches/wvstreams-4.6.1/0004-Fix-compilation-with-gcc-6.patch
new file mode 100644
index 000000000..c253129f4
--- /dev/null
+++ b/patches/wvstreams-4.6.1/0004-Fix-compilation-with-gcc-6.patch
@@ -0,0 +1,45 @@
+From: Gert Wollny <gw.fossdev@gmail.com>
+Date: Thu, 28 Sep 2017 15:53:36 +0200
+Subject: [PATCH] Fix compilation with gcc-6
+
+---
+ streams/wvstream.cc | 12 +++++++-----
+ 1 file changed, 7 insertions(+), 5 deletions(-)
+
+diff --git a/streams/wvstream.cc b/streams/wvstream.cc
+index 4564f3ce873d..5a3c0705aadb 100644
+--- a/streams/wvstream.cc
++++ b/streams/wvstream.cc
+@@ -907,9 +907,9 @@ void WvStream::_build_selectinfo(SelectInfo &si, time_t msec_timeout,
+     
+     if (forceable)
+     {
+-	si.wants.readable = readcb;
+-	si.wants.writable = writecb;
+-	si.wants.isexception = exceptcb;
++	si.wants.readable = static_cast<bool>(readcb);
++	si.wants.writable = static_cast<bool>(writecb);
++	si.wants.isexception = static_cast<bool>(exceptcb);
+     }
+     else
+     {
+@@ -1019,7 +1019,8 @@ bool WvStream::_select(time_t msec_timeout, bool readable, bool writable,
+ 
+ IWvStream::SelectRequest WvStream::get_select_request()
+ {
+-    return IWvStream::SelectRequest(readcb, writecb, exceptcb);
++    return IWvStream::SelectRequest(static_cast<bool>(readcb), static_cast<bool>(writecb),
++				    static_cast<bool>(exceptcb));
+ }
+ 
+ 
+@@ -1107,7 +1108,8 @@ bool WvStream::continue_select(time_t msec_timeout)
+     // inefficient, because if the alarm was expired then pre_select()
+     // returned true anyway and short-circuited the previous select().
+     TRACE("hello-%p\n", this);
+-    return !alarm_was_ticking || select(0, readcb, writecb, exceptcb);
++    return !alarm_was_ticking || select(0, static_cast<bool>(readcb),
++					static_cast<bool>(writecb), static_cast<bool>(exceptcb));
+ }
+ 
+ 
diff --git a/patches/wvstreams-4.6.1/series b/patches/wvstreams-4.6.1/series
new file mode 100644
index 000000000..b7477ef11
--- /dev/null
+++ b/patches/wvstreams-4.6.1/series
@@ -0,0 +1,7 @@
+# generated by git-ptx-patches
+#tag:base --start-number 1
+0001-Fix-FTBFS-with-gcc-4.7.patch
+0002-fix-FTBFS-with-OpenSSL-1.0.patch
+0003-fix-FTBFS-with-glibc-2.12.patch
+0004-Fix-compilation-with-gcc-6.patch
+# c2f1282f6ba8e36353ea9f2195704504  - git-ptx-patches magic
diff --git a/rules/wvstreams.in b/rules/wvstreams.in
new file mode 100644
index 000000000..2f3f60b83
--- /dev/null
+++ b/rules/wvstreams.in
@@ -0,0 +1,11 @@
+## SECTION=system_libraries
+
+config WVSTREAMS
+	tristate
+	prompt "wvstreams"
+	select ZLIB
+	select OPENSSL
+	help
+	  WvStreams aims to be an efficient, secure, and easy-to-use library
+	  for doing network and systems applications development in C++.
+	  Mainly needed for the wvdial tool.
diff --git a/rules/wvstreams.make b/rules/wvstreams.make
new file mode 100644
index 000000000..f5c3220ac
--- /dev/null
+++ b/rules/wvstreams.make
@@ -0,0 +1,71 @@
+# -*-makefile-*-
+#
+# Copyright (C) 2017 by Sascha Hauer <s.hauer@pengutronix.de>
+#
+# See CREDITS for details about who has contributed to this project.
+#
+# For further information about the PTXdist project and license conditions
+# see the README file.
+#
+
+#
+# We provide this package
+#
+PACKAGES-$(PTXCONF_WVSTREAMS) += wvstreams
+
+#
+# Paths and names
+#
+WVSTREAMS_VERSION	:= 4.6.1
+WVSTREAMS_MD5		:= 2760dac31a43d452a19a3147bfde571c
+WVSTREAMS		:= wvstreams-$(WVSTREAMS_VERSION)
+WVSTREAMS_SUFFIX	:= tar.gz
+WVSTREAMS_URL		:= https://storage.googleapis.com/google-code-archive-downloads/v2/code.google.com/wvstreams/${WVSTREAMS}.$(WVSTREAMS_SUFFIX)
+WVSTREAMS_SOURCE	:= $(SRCDIR)/$(WVSTREAMS).$(WVSTREAMS_SUFFIX)
+WVSTREAMS_DIR		:= $(BUILDDIR)/$(WVSTREAMS)
+WVSTREAMS_LICENSE	:= GPLv2
+
+#
+# autoconf
+#
+WVSTREAMS_CONF_TOOL	:= autoconf
+WVSTREAMS_CONF_OPT	:= \
+	$(CROSS_AUTOCONF_USR) \
+	--disable-debug \
+	--enable-fatal-warnings \
+	--disable-optimization \
+	--disable-resolver-fork \
+	--disable-delete-detector \
+	--disable-warnings \
+	--disable-testgui \
+	--without-dbus \
+	--without-pam \
+	--without-tcl \
+	--without-qt \
+	--without-valgrind
+
+WVSTREAMS_MAKE_PAR := NO
+
+# ----------------------------------------------------------------------------
+# Target-Install
+# ----------------------------------------------------------------------------
+
+$(STATEDIR)/wvstreams.targetinstall:
+	@$(call targetinfo)
+
+	@$(call install_init, wvstreams)
+	@$(call install_fixup, wvstreams,PRIORITY,optional)
+	@$(call install_fixup, wvstreams,SECTION,base)
+	@$(call install_fixup, wvstreams,AUTHOR,"Sascha Hauer <s.hauer@pengutronix.de>")
+	@$(call install_fixup, wvstreams,DESCRIPTION,missing)
+
+	@$(call install_lib, wvstreams, 0, 0, 0644, libuniconf)
+	@$(call install_lib, wvstreams, 0, 0, 0644, libwvbase)
+	@$(call install_lib, wvstreams, 0, 0, 0644, libwvstreams)
+	@$(call install_lib, wvstreams, 0, 0, 0644, libwvutils)
+
+	@$(call install_finish, wvstreams)
+
+	@$(call touch)
+
+# vim: syntax=make
-- 
2.11.0


_______________________________________________
ptxdist mailing list
ptxdist@pengutronix.de

^ permalink raw reply	[flat|nested] 7+ messages in thread
* [ptxdist] [PATCH 1/2] wvstreams: Add package
@ 2017-09-29 13:52 Sascha Hauer
  2017-09-29 13:52 ` [ptxdist] [PATCH 2/2] wvdial: " Sascha Hauer
  0 siblings, 1 reply; 7+ messages in thread
From: Sascha Hauer @ 2017-09-29 13:52 UTC (permalink / raw)
  To: ptxdist

wvstreams is a C++ networking library which is added here because
it's used by wvdial. Upstream for this library is dead, so we
download the package from storage.googleapis.com.

To make it compile the debian patches are added.

WvStreams uses autoconf, but not automake which for us means
that parallel build is broken. Disable parallel build for now.

Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
---
 .../0001-Fix-FTBFS-with-gcc-4.7.patch              | 54 ++++++++++++++++++++
 .../0002-fix-FTBFS-with-OpenSSL-1.0.patch          | 25 ++++++++++
 .../0003-fix-FTBFS-with-glibc-2.12.patch           | 41 ++++++++++++++++
 .../0004-Fix-compilation-with-gcc-6.patch          | 49 +++++++++++++++++++
 patches/wvstreams-4.6.1/series                     |  4 ++
 rules/wvstreams.in                                 | 11 +++++
 rules/wvstreams.make                               | 57 ++++++++++++++++++++++
 7 files changed, 241 insertions(+)
 create mode 100644 patches/wvstreams-4.6.1/0001-Fix-FTBFS-with-gcc-4.7.patch
 create mode 100644 patches/wvstreams-4.6.1/0002-fix-FTBFS-with-OpenSSL-1.0.patch
 create mode 100644 patches/wvstreams-4.6.1/0003-fix-FTBFS-with-glibc-2.12.patch
 create mode 100644 patches/wvstreams-4.6.1/0004-Fix-compilation-with-gcc-6.patch
 create mode 100644 patches/wvstreams-4.6.1/series
 create mode 100644 rules/wvstreams.in
 create mode 100644 rules/wvstreams.make

diff --git a/patches/wvstreams-4.6.1/0001-Fix-FTBFS-with-gcc-4.7.patch b/patches/wvstreams-4.6.1/0001-Fix-FTBFS-with-gcc-4.7.patch
new file mode 100644
index 000000000..b8597d29a
--- /dev/null
+++ b/patches/wvstreams-4.6.1/0001-Fix-FTBFS-with-gcc-4.7.patch
@@ -0,0 +1,54 @@
+From 912004e2faa35c95558a04b8d7ac7d132676d92f Mon Sep 17 00:00:00 2001
+From: Paul Tagliamonte <paultag@ubuntu.com>
+Date: Thu, 28 Sep 2017 15:50:05 +0200
+Subject: [PATCH 1/4] Fix FTBFS with gcc-4.7
+
+Small header include change. This is borderlinde cosmetic, but still
+needed to prevent the FTBFS.
+---
+ utils/wvcrash.cc     | 2 +-
+ utils/wvcrashbase.cc | 2 +-
+ utils/wvuid.cc       | 1 +
+ 3 files changed, 3 insertions(+), 2 deletions(-)
+
+diff --git a/utils/wvcrash.cc b/utils/wvcrash.cc
+index 0417759..d5e1d87 100644
+--- a/utils/wvcrash.cc
++++ b/utils/wvcrash.cc
+@@ -26,7 +26,7 @@
+ #endif
+ 
+ // FIXME: this file mostly only works in Linux
+-#ifdef __linux
++#if 1
+ 
+ # include <execinfo.h>
+ #include <unistd.h>
+diff --git a/utils/wvcrashbase.cc b/utils/wvcrashbase.cc
+index 8d67027..53e2037 100644
+--- a/utils/wvcrashbase.cc
++++ b/utils/wvcrashbase.cc
+@@ -66,7 +66,7 @@ const char *wvcrash_ring_buffer_get()
+ 
+ 
+ // FIXME: leaving of a will and catching asserts mostly only works in Linux
+-#ifdef __linux
++#if 1
+ 
+ #ifdef __USE_GNU
+ static const char *argv0 = program_invocation_short_name;
+diff --git a/utils/wvuid.cc b/utils/wvuid.cc
+index 7fa1035..709a484 100644
+--- a/utils/wvuid.cc
++++ b/utils/wvuid.cc
+@@ -33,6 +33,7 @@ wvuid_t wvgetuid()
+ 
+ #else // not WIN32
+ 
++#include <unistd.h>
+ 
+ WvString wv_username_from_uid(wvuid_t uid)
+ {
+-- 
+2.11.0
+
diff --git a/patches/wvstreams-4.6.1/0002-fix-FTBFS-with-OpenSSL-1.0.patch b/patches/wvstreams-4.6.1/0002-fix-FTBFS-with-OpenSSL-1.0.patch
new file mode 100644
index 000000000..d308bc93c
--- /dev/null
+++ b/patches/wvstreams-4.6.1/0002-fix-FTBFS-with-OpenSSL-1.0.patch
@@ -0,0 +1,25 @@
+From f6a5f6c664be64c04d4e70c7a69993401318f36a Mon Sep 17 00:00:00 2001
+From: Luca Falavigna <dktrkranz@debian.org>
+Date: Thu, 28 Sep 2017 15:51:26 +0200
+Subject: [PATCH 2/4] fix FTBFS with OpenSSL 1.0
+
+---
+ crypto/wvx509.cc | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/crypto/wvx509.cc b/crypto/wvx509.cc
+index 93dae06..41fa742 100644
+--- a/crypto/wvx509.cc
++++ b/crypto/wvx509.cc
+@@ -1157,7 +1157,7 @@ WvString WvX509::get_extension(int nid) const
+         
+         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;
+-- 
+2.11.0
+
diff --git a/patches/wvstreams-4.6.1/0003-fix-FTBFS-with-glibc-2.12.patch b/patches/wvstreams-4.6.1/0003-fix-FTBFS-with-glibc-2.12.patch
new file mode 100644
index 000000000..183583aab
--- /dev/null
+++ b/patches/wvstreams-4.6.1/0003-fix-FTBFS-with-glibc-2.12.patch
@@ -0,0 +1,41 @@
+From 013d7fc99cafd215a18ee2e3eeeead15c4428242 Mon Sep 17 00:00:00 2001
+From: Luca Falavigna <dktrkranz@debian.org>
+Date: Thu, 28 Sep 2017 15:52:12 +0200
+Subject: [PATCH 3/4] fix FTBFS with glibc 2.12
+
+---
+ ipstreams/wvunixdgsocket.cc | 2 --
+ streams/wvatomicfile.cc     | 3 ---
+ 2 files changed, 5 deletions(-)
+
+diff --git a/ipstreams/wvunixdgsocket.cc b/ipstreams/wvunixdgsocket.cc
+index 41d2911..c8b539f 100644
+--- a/ipstreams/wvunixdgsocket.cc
++++ b/ipstreams/wvunixdgsocket.cc
+@@ -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)
+diff --git a/streams/wvatomicfile.cc b/streams/wvatomicfile.cc
+index 65ae202..e249a14 100644
+--- a/streams/wvatomicfile.cc
++++ b/streams/wvatomicfile.cc
+@@ -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)
+-- 
+2.11.0
+
diff --git a/patches/wvstreams-4.6.1/0004-Fix-compilation-with-gcc-6.patch b/patches/wvstreams-4.6.1/0004-Fix-compilation-with-gcc-6.patch
new file mode 100644
index 000000000..9381c4c11
--- /dev/null
+++ b/patches/wvstreams-4.6.1/0004-Fix-compilation-with-gcc-6.patch
@@ -0,0 +1,49 @@
+From e8ef9e0843bc0e8e59c556dbe8c612221e54c295 Mon Sep 17 00:00:00 2001
+From: Gert Wollny <gw.fossdev@gmail.com>
+Date: Thu, 28 Sep 2017 15:53:36 +0200
+Subject: [PATCH 4/4] Fix compilation with gcc-6
+
+---
+ streams/wvstream.cc | 12 +++++++-----
+ 1 file changed, 7 insertions(+), 5 deletions(-)
+
+diff --git a/streams/wvstream.cc b/streams/wvstream.cc
+index 4564f3c..5a3c070 100644
+--- a/streams/wvstream.cc
++++ b/streams/wvstream.cc
+@@ -907,9 +907,9 @@ void WvStream::_build_selectinfo(SelectInfo &si, time_t msec_timeout,
+     
+     if (forceable)
+     {
+-	si.wants.readable = readcb;
+-	si.wants.writable = writecb;
+-	si.wants.isexception = exceptcb;
++	si.wants.readable = static_cast<bool>(readcb);
++	si.wants.writable = static_cast<bool>(writecb);
++	si.wants.isexception = static_cast<bool>(exceptcb);
+     }
+     else
+     {
+@@ -1019,7 +1019,8 @@ bool WvStream::_select(time_t msec_timeout, bool readable, bool writable,
+ 
+ IWvStream::SelectRequest WvStream::get_select_request()
+ {
+-    return IWvStream::SelectRequest(readcb, writecb, exceptcb);
++    return IWvStream::SelectRequest(static_cast<bool>(readcb), static_cast<bool>(writecb),
++				    static_cast<bool>(exceptcb));
+ }
+ 
+ 
+@@ -1107,7 +1108,8 @@ bool WvStream::continue_select(time_t msec_timeout)
+     // inefficient, because if the alarm was expired then pre_select()
+     // returned true anyway and short-circuited the previous select().
+     TRACE("hello-%p\n", this);
+-    return !alarm_was_ticking || select(0, readcb, writecb, exceptcb);
++    return !alarm_was_ticking || select(0, static_cast<bool>(readcb),
++					static_cast<bool>(writecb), static_cast<bool>(exceptcb));
+ }
+ 
+ 
+-- 
+2.11.0
+
diff --git a/patches/wvstreams-4.6.1/series b/patches/wvstreams-4.6.1/series
new file mode 100644
index 000000000..d21be5195
--- /dev/null
+++ b/patches/wvstreams-4.6.1/series
@@ -0,0 +1,4 @@
+0001-Fix-FTBFS-with-gcc-4.7.patch
+0002-fix-FTBFS-with-OpenSSL-1.0.patch
+0003-fix-FTBFS-with-glibc-2.12.patch
+0004-Fix-compilation-with-gcc-6.patch
diff --git a/rules/wvstreams.in b/rules/wvstreams.in
new file mode 100644
index 000000000..2f3f60b83
--- /dev/null
+++ b/rules/wvstreams.in
@@ -0,0 +1,11 @@
+## SECTION=system_libraries
+
+config WVSTREAMS
+	tristate
+	prompt "wvstreams"
+	select ZLIB
+	select OPENSSL
+	help
+	  WvStreams aims to be an efficient, secure, and easy-to-use library
+	  for doing network and systems applications development in C++.
+	  Mainly needed for the wvdial tool.
diff --git a/rules/wvstreams.make b/rules/wvstreams.make
new file mode 100644
index 000000000..d5e9aff2b
--- /dev/null
+++ b/rules/wvstreams.make
@@ -0,0 +1,57 @@
+# -*-makefile-*-
+#
+# Copyright (C) 2017 by Sascha Hauer <s.hauer@pengutronix.de>
+#
+# See CREDITS for details about who has contributed to this project.
+#
+# For further information about the PTXdist project and license conditions
+# see the README file.
+#
+
+#
+# We provide this package
+#
+PACKAGES-$(PTXCONF_WVSTREAMS) += wvstreams
+
+#
+# Paths and names
+#
+WVSTREAMS_VERSION	:= 4.6.1
+WVSTREAMS_MD5		:= 2760dac31a43d452a19a3147bfde571c
+WVSTREAMS		:= wvstreams-$(WVSTREAMS_VERSION)
+WVSTREAMS_SUFFIX	:= tar.gz
+WVSTREAMS_URL		:= https://storage.googleapis.com/google-code-archive-downloads/v2/code.google.com/wvstreams/${WVSTREAMS}.$(WVSTREAMS_SUFFIX)
+WVSTREAMS_SOURCE	:= $(SRCDIR)/$(WVSTREAMS).$(WVSTREAMS_SUFFIX)
+WVSTREAMS_DIR		:= $(BUILDDIR)/$(WVSTREAMS)
+WVSTREAMS_LICENSE	:= GPLv2
+
+#
+# autoconf
+#
+WVSTREAMS_CONF_TOOL	:= autoconf
+#WVSTREAMS_CONF_OPT	:= $(CROSS_AUTOCONF_USR)
+WVSTREAMS_MAKE_PAR := NO
+
+# ----------------------------------------------------------------------------
+# Target-Install
+# ----------------------------------------------------------------------------
+
+$(STATEDIR)/wvstreams.targetinstall:
+	@$(call targetinfo)
+
+	@$(call install_init, wvstreams)
+	@$(call install_fixup, wvstreams,PRIORITY,optional)
+	@$(call install_fixup, wvstreams,SECTION,base)
+	@$(call install_fixup, wvstreams,AUTHOR,"Sascha Hauer <s.hauer@pengutronix.de>")
+	@$(call install_fixup, wvstreams,DESCRIPTION,missing)
+
+	@$(call install_lib, wvstreams, 0, 0, 0644, libuniconf)
+	@$(call install_lib, wvstreams, 0, 0, 0644, libwvbase)
+	@$(call install_lib, wvstreams, 0, 0, 0644, libwvstreams)
+	@$(call install_lib, wvstreams, 0, 0, 0644, libwvutils)
+
+	@$(call install_finish, wvstreams)
+
+	@$(call touch)
+
+# vim: syntax=make
-- 
2.11.0


_______________________________________________
ptxdist mailing list
ptxdist@pengutronix.de

^ permalink raw reply	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2017-10-16 12:42 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2017-10-16 12:15 [ptxdist] [PATCH 1/2] wvstreams: Add package Sascha Hauer
2017-10-16 12:15 ` [ptxdist] [PATCH 2/2] wvdial: " Sascha Hauer
2017-10-16 12:36   ` Ladislav Michl
2017-10-16 12:42     ` Sascha Hauer
2017-10-16 12:16 ` [ptxdist] [PATCH 1/2] wvstreams: " Sascha Hauer
  -- strict thread matches above, loose matches on Subject: below --
2017-09-29 13:52 Sascha Hauer
2017-09-29 13:52 ` [ptxdist] [PATCH 2/2] wvdial: " Sascha Hauer
2017-09-30 11:02   ` Michael Olbrich

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox