pkgsrc-WIP-changes archive

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

vlc: Partial port to NetBSD



Module Name:	pkgsrc-wip
Committed By:	Kamil Rytarowski <n54%gmx.com@localhost>
Pushed By:	kamil
Date:		Tue Mar 20 13:28:43 2018 +0100
Changeset:	336d95f2bb2dbd5fd224843a24185e736b61a3b5

Modified Files:
	vlc/Makefile
	vlc/distinfo
Added Files:
	vlc/patches/patch-compat_Makefile.am
	vlc/patches/patch-include_vlc__common.h
	vlc/patches/patch-m4_dolt.m4

Log Message:
vlc: Partial port to NetBSD

To see a diff of this commit:
https://wip.pkgsrc.org/cgi-bin/gitweb.cgi?p=pkgsrc-wip.git;a=commitdiff;h=336d95f2bb2dbd5fd224843a24185e736b61a3b5

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

diffstat:
 vlc/Makefile                            |  8 ++++----
 vlc/distinfo                            |  3 +++
 vlc/patches/patch-compat_Makefile.am    | 14 +++++++++++++
 vlc/patches/patch-include_vlc__common.h | 36 +++++++++++++++++++++++++++++++++
 vlc/patches/patch-m4_dolt.m4            | 12 +++++++++++
 5 files changed, 69 insertions(+), 4 deletions(-)

diffs:
diff --git a/vlc/Makefile b/vlc/Makefile
index e1bab5ff16..2dc2a21fef 100644
--- a/vlc/Makefile
+++ b/vlc/Makefile
@@ -16,7 +16,7 @@ LICENSE=		gnu-gpl-v2
 CONFLICTS=		vlc07-[0-9]* vlc08-[0-9]*
 
 USE_LIBTOOL=		yes
-USE_TOOLS+=		gmake perl pkg-config
+USE_TOOLS+=		gmake perl pkg-config autoreconf autoconf automake bison autopoint realpath
 
 USE_PKGLOCALEDIR=	yes
 GNU_CONFIGURE=		yes
@@ -61,9 +61,6 @@ CONFIGURE_ARGS+=	--disable-vnc
 CONFIGURE_ARGS+=	--disable-vsxu
 CONFIGURE_ARGS+=	--disable-zvbi
 
-CFLAGS+=		-fPIC
-CXXFLAGS+=		-fPIC
-
 # which platforms support OSSv4?
 .if ${MACHINE_PLATFORM:MNetBSD-[789]*-*}
 PLIST.oss=		yes
@@ -140,6 +137,9 @@ SUBST_MESSAGE.fnt=	Fixing hardcoded font paths.
 CHECK_WRKREF_SKIP=	lib/libvlccore.a \
 			lib/libvlccore.so*
 
+pre-configure:
+	${RUN} cd ${WRKSRC} && ${SH} ./bootstrap
+
 .include "../../audio/fluidsynth/buildlink3.mk"
 .include "../../audio/flac/buildlink3.mk"
 .include "../../multimedia/libkate/buildlink3.mk"
diff --git a/vlc/distinfo b/vlc/distinfo
index 3c62ba11b6..063c1096f6 100644
--- a/vlc/distinfo
+++ b/vlc/distinfo
@@ -4,3 +4,6 @@ SHA1 (vlc-3.0.1.tar.xz) = 9eab63eeb525f200220fe7f99ca2a67805058517
 RMD160 (vlc-3.0.1.tar.xz) = b0ecf5e2bccb916d5e0fb8fa57593ae8c5ec7741
 SHA512 (vlc-3.0.1.tar.xz) = f2ba7586e8fb8c04484e62809265ec998e875b1eff03262bbf463370277a318816cbb8d260901c774e59443393b16b040cb714019c80e051578008abbf91b13c
 Size (vlc-3.0.1.tar.xz) = 25174040 bytes
+SHA1 (patch-compat_Makefile.am) = 8a5f9c82a748542423172a3a32daefd386ae815d
+SHA1 (patch-include_vlc__common.h) = cc5b766e882097f5a7767023e440e4ccd49b219f
+SHA1 (patch-m4_dolt.m4) = f567605ca51069a681516016066ef0009787c904
diff --git a/vlc/patches/patch-compat_Makefile.am b/vlc/patches/patch-compat_Makefile.am
new file mode 100644
index 0000000000..fe3efd210e
--- /dev/null
+++ b/vlc/patches/patch-compat_Makefile.am
@@ -0,0 +1,14 @@
+$NetBSD$
+
+--- compat/Makefile.am.orig	2017-11-24 15:29:17.000000000 +0000
++++ compat/Makefile.am
+@@ -1,7 +1,7 @@
+-pkglib_LTLIBRARIES = libcompat.la
++noinst_LTLIBRARIES = libcompat.la
+ libcompat_la_SOURCES = dummy.c
+ libcompat_la_LIBADD = $(LTLIBOBJS) $(LIBRT)
+-libcompat_la_LDFLAGS = -no-undefined -static
++libcompat_la_LDFLAGS = -no-undefined
+ 
+ BUILT_SOURCES = dummy.c
+ CLEANFILES = dummy.c
diff --git a/vlc/patches/patch-include_vlc__common.h b/vlc/patches/patch-include_vlc__common.h
new file mode 100644
index 0000000000..c063383290
--- /dev/null
+++ b/vlc/patches/patch-include_vlc__common.h
@@ -0,0 +1,36 @@
+$NetBSD$
+
+--- include/vlc_common.h.orig	2017-12-21 09:51:16.000000000 +0000
++++ include/vlc_common.h
+@@ -556,6 +556,7 @@ static inline unsigned (ctz)(unsigned x)
+ #endif
+ }
+ 
++#if !defined(__NetBSD__)
+ /** Bit weight */
+ VLC_USED
+ static inline unsigned (popcount)(unsigned x)
+@@ -589,6 +590,7 @@ static inline int (popcountll)(unsigned 
+     return count;
+ #endif
+ }
++#endif
+ 
+ VLC_USED
+ static inline unsigned (parity)(unsigned x)
+@@ -602,6 +604,7 @@ static inline unsigned (parity)(unsigned
+ #endif
+ }
+ 
++#if !defined(__NetBSD__)
+ /** Byte swap (16 bits) */
+ VLC_USED
+ static inline uint16_t (bswap16)(uint16_t x)
+@@ -649,6 +652,7 @@ static inline uint64_t (bswap64)(uint64_
+          | ((x & 0xFF00000000000000ULL) >> 56);
+ #endif
+ }
++#endif
+ 
+ /* Integer overflow */
+ static inline bool uadd_overflow(unsigned a, unsigned b, unsigned *res)
diff --git a/vlc/patches/patch-m4_dolt.m4 b/vlc/patches/patch-m4_dolt.m4
new file mode 100644
index 0000000000..3cdbd7de9b
--- /dev/null
+++ b/vlc/patches/patch-m4_dolt.m4
@@ -0,0 +1,12 @@
+$NetBSD$
+
+--- m4/dolt.m4.orig	2017-11-24 15:29:17.000000000 +0000
++++ m4/dolt.m4
+@@ -20,6 +20,7 @@ AS_IF([test x$GCC != xyes], [dolt_suppor
+ 
+ AS_CASE([$host],
+     [*-*-linux*|*-*-freebsd*], [pic_options='-fPIC'],
++    [*-*-netbsd*],             [pic_options='-fPIC -DPIC'],
+     [*-apple-darwin*],         [pic_options='-fno-common'],
+     [*mingw*|*nacl*],          [pic_options='']
+     [*],                       [dolt_supported=no]


Home | Main Index | Thread Index | Old Index