pkgsrc-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[pkgsrc/trunk]: pkgsrc fix build on SunOS



details:   https://anonhg.NetBSD.org/pkgsrc/rev/dc7c05059e2f
branches:  trunk
changeset: 364649:dc7c05059e2f
user:      wiedi <wiedi%pkgsrc.org@localhost>
date:      Mon Jul 03 11:52:37 2017 +0000

description:
fix build on SunOS

diffstat:

 multimedia/tstools/Makefile                |   5 ++++-
 multimedia/tstools/distinfo                |   6 +++++-
 multimedia/tstools/patches/patch-Makefile  |  15 +++++++++++++++
 multimedia/tstools/patches/patch-compat.h  |  16 ++++++++++++++++
 multimedia/tstools/patches/patch-misc.c    |  14 ++++++++++++++
 multimedia/tstools/patches/patch-tsserve.c |  14 ++++++++++++++
 net/bmon/Makefile                          |   3 ++-
 net/bmon/distinfo                          |   3 ++-
 net/bmon/patches/patch-src_in__netlink.c   |  14 ++++++++++++++
 9 files changed, 86 insertions(+), 4 deletions(-)

diffs (161 lines):

diff -r c4418a27630f -r dc7c05059e2f multimedia/tstools/Makefile
--- a/multimedia/tstools/Makefile       Mon Jul 03 11:49:47 2017 +0000
+++ b/multimedia/tstools/Makefile       Mon Jul 03 11:52:37 2017 +0000
@@ -1,7 +1,8 @@
-# $NetBSD: Makefile,v 1.6 2014/12/21 12:12:42 mef Exp $
+# $NetBSD: Makefile,v 1.7 2017/07/03 11:52:37 wiedi Exp $
 #
 
 DISTNAME=      tstools-1_11
+PKGREVISION=   1
 PKGNAME=       ${DISTNAME:S/_/./}
 CATEGORIES=    multimedia
 MASTER_SITES=  https://tstools.googlecode.com/files/
@@ -17,6 +18,8 @@
 WRKSRC=                ${WRKDIR}/${DISTNAME:S/_/./}
 USE_TOOLS+=    gmake
 
+LDFLAGS.SunOS+=        -lsocket -lnsl -lresolv
+
 TSPROGS=es2ts \
        esdots \
        esfilter \
diff -r c4418a27630f -r dc7c05059e2f multimedia/tstools/distinfo
--- a/multimedia/tstools/distinfo       Mon Jul 03 11:49:47 2017 +0000
+++ b/multimedia/tstools/distinfo       Mon Jul 03 11:52:37 2017 +0000
@@ -1,6 +1,10 @@
-$NetBSD: distinfo,v 1.2 2015/11/03 23:54:33 agc Exp $
+$NetBSD: distinfo,v 1.3 2017/07/03 11:52:37 wiedi Exp $
 
 SHA1 (tstools-1_11.tgz) = fb8e5f59fada384d2d7865f840a0ad28404bde81
 RMD160 (tstools-1_11.tgz) = f4fa0e3f49c9409096608a6bf3849c785de9d3f5
 SHA512 (tstools-1_11.tgz) = 8cc0f5d4ff22bd3151a4fa3012d22ebc36dd3c7546258f9f9ecc2d0513e478aeccd8f5fff7cfd24e647e0e668b0968e780dab4418469c0979ccc6176136d9e26
 Size (tstools-1_11.tgz) = 392616 bytes
+SHA1 (patch-Makefile) = 895018d485d31fdecdc3a4ee9f672b0a3c34e6df
+SHA1 (patch-compat.h) = b08f53225da9830de408dbadbaa51411b2838380
+SHA1 (patch-misc.c) = 17033aa72ee1fc8b2ac8b8870ed0a1f98b9ec01e
+SHA1 (patch-tsserve.c) = 519f2ed14d50c258ca5b7cc747793d280f7fc6e3
diff -r c4418a27630f -r dc7c05059e2f multimedia/tstools/patches/patch-Makefile
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/multimedia/tstools/patches/patch-Makefile Mon Jul 03 11:52:37 2017 +0000
@@ -0,0 +1,15 @@
+$NetBSD: patch-Makefile,v 1.1 2017/07/03 11:52:37 wiedi Exp $
+
+Don't overwrite pkgsrc LDFLAGS
+
+--- Makefile.orig      2008-11-06 23:15:49.000000000 +0000
++++ Makefile
+@@ -80,7 +80,7 @@ else
+ endif
+ 
+ CFLAGS = $(WARNING_FLAGS) $(OPTIMISE_FLAGS) $(LFS_FLAGS) -I. $(PROFILE_FLAGS) $(ARCH_FLAGS)
+-LDFLAGS = -g -lm $(PROFILE_FLAGS) $(ARCH_FLAGS)
++LDFLAGS += -g -lm $(PROFILE_FLAGS) $(ARCH_FLAGS)
+ 
+ # Target directories
+ OBJDIR = obj
diff -r c4418a27630f -r dc7c05059e2f multimedia/tstools/patches/patch-compat.h
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/multimedia/tstools/patches/patch-compat.h Mon Jul 03 11:52:37 2017 +0000
@@ -0,0 +1,16 @@
+$NetBSD: patch-compat.h,v 1.1 2017/07/03 11:52:37 wiedi Exp $
+
+prevent conflicting offset_t on SunOS
+
+--- compat.h.orig      2008-11-06 23:15:49.000000000 +0000
++++ compat.h
+@@ -113,7 +113,9 @@ typedef uint8_t  byte;
+ //     do both, here, for safety.
+ #include <sys/types.h>
+ #include <unistd.h>
++#if !defined(__sun)
+ typedef off_t offset_t;
++#endif
+ 
+ #if defined(__linux__) && !defined(__USE_FILE_OFFSET64)
+ // If Linux does not have 64 bit support built in, then our offsets will
diff -r c4418a27630f -r dc7c05059e2f multimedia/tstools/patches/patch-misc.c
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/multimedia/tstools/patches/patch-misc.c   Mon Jul 03 11:52:37 2017 +0000
@@ -0,0 +1,14 @@
+$NetBSD: patch-misc.c,v 1.1 2017/07/03 11:52:37 wiedi Exp $
+
+no sin_len on SunOS
+--- misc.c.orig        2008-11-06 23:15:49.000000000 +0000
++++ misc.c
+@@ -1277,7 +1277,7 @@ extern int connect_socket(char *hostname
+   }
+   memcpy(&ipaddr.sin_addr.s_addr, hp->h_addr, hp->h_length);
+   ipaddr.sin_family = hp->h_addrtype;
+-#if !defined(__linux__)
++#if !defined(__linux__) && !defined(__sun)
+   // On BSD, the length is defined in the datastructure
+   ipaddr.sin_len = sizeof(struct sockaddr_in);
+ #endif // __linux__
diff -r c4418a27630f -r dc7c05059e2f multimedia/tstools/patches/patch-tsserve.c
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/multimedia/tstools/patches/patch-tsserve.c        Mon Jul 03 11:52:37 2017 +0000
@@ -0,0 +1,14 @@
+$NetBSD: patch-tsserve.c,v 1.1 2017/07/03 11:52:37 wiedi Exp $
+
+no sin_len on SunOS
+--- tsserve.c.orig     2008-11-06 23:15:49.000000000 +0000
++++ tsserve.c
+@@ -3041,7 +3041,7 @@ static int run_server(tsserve_context_p
+ 
+   // Bind it to port `listen_port` on this machine
+   memset(&ipaddr,0,sizeof(ipaddr));
+-#if !defined(__linux__) && !defined(_WIN32)
++#if !defined(__linux__) && !defined(_WIN32) && !defined(__sun)
+   // On BSD, the length is defined in the datastructure
+   ipaddr.sin_len = sizeof(struct sockaddr_in);
+ #endif
diff -r c4418a27630f -r dc7c05059e2f net/bmon/Makefile
--- a/net/bmon/Makefile Mon Jul 03 11:49:47 2017 +0000
+++ b/net/bmon/Makefile Mon Jul 03 11:52:37 2017 +0000
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile,v 1.18 2017/01/04 01:49:41 roy Exp $
+# $NetBSD: Makefile,v 1.19 2017/07/03 11:53:11 wiedi Exp $
 #
 
 DISTNAME=      bmon-3.8
@@ -15,6 +15,7 @@
 USE_TOOLS+=    pkg-config
 
 CONFIGURE_ARGS+=       --sysconfdir=${PKG_SYSCONFDIR:Q}
+CPPFLAGS.SunOS+=       -D_POSIX_PTHREAD_SEMANTICS
 
 .include "../../devel/confuse/buildlink3.mk"
 .include "../../devel/gettext-lib/buildlink3.mk"
diff -r c4418a27630f -r dc7c05059e2f net/bmon/distinfo
--- a/net/bmon/distinfo Mon Jul 03 11:49:47 2017 +0000
+++ b/net/bmon/distinfo Mon Jul 03 11:52:37 2017 +0000
@@ -1,8 +1,9 @@
-$NetBSD: distinfo,v 1.6 2015/12/25 20:08:38 joerg Exp $
+$NetBSD: distinfo,v 1.7 2017/07/03 11:53:11 wiedi Exp $
 
 SHA1 (bmon-3.8.tar.gz) = f10ddfebf4b6c2fcdeea9ccd3027dd5291cd6838
 RMD160 (bmon-3.8.tar.gz) = eba503ff9d5bedc3901ab546193effcef8fbb298
 SHA512 (bmon-3.8.tar.gz) = 629a8678bf76e2dab125a08b334925f953e3ddd5ee0b2b865f157013a5462a5fa8e1bc76920487a03f5afdf12143c4a2cc1c6ab51d514119ca9754cc67117d84
 Size (bmon-3.8.tar.gz) = 195437 bytes
 SHA1 (patch-examples_Makefile.in) = f7dab570d8b141226f70774aed3a5f119793229f
+SHA1 (patch-src_in__netlink.c) = 2bdc721c284984a2839a33d1eef403afe8e4e35f
 SHA1 (patch-src_in__sysctl.c) = 71c0a11b7e19e0de0eaac281f94e18835aeb532e
diff -r c4418a27630f -r dc7c05059e2f net/bmon/patches/patch-src_in__netlink.c
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/net/bmon/patches/patch-src_in__netlink.c  Mon Jul 03 11:52:37 2017 +0000
@@ -0,0 +1,14 @@
+$NetBSD: patch-src_in__netlink.c,v 1.1 2017/07/03 11:53:11 wiedi Exp $
+
+no netlink support on SunOS
+--- src/in_netlink.c.orig      2015-07-25 09:03:55.000000000 +0000
++++ src/in_netlink.c
+@@ -31,7 +31,7 @@
+ #include <bmon/input.h>
+ #include <bmon/utils.h>
+ 
+-#ifndef SYS_BSD
++#if !defined(SYS_BSD) && !defined(__sun)
+ 
+ static int c_notc = 0;
+ static struct element_group *grp;



Home | Main Index | Thread Index | Old Index