From 8376ef56580626e9c0f796d5b85b53a0a1c7d5f5 Mon Sep 17 00:00:00 2001 From: V3n3RiX Date: Sat, 14 Jul 2018 21:03:06 +0100 Subject: gentoo resync : 14.07.2018 --- dev-libs/libspnav/Manifest | 5 ++ .../files/libspnav-0.2.2-custom-flags.patch | 75 ++++++++++++++++++++++ .../libspnav/files/libspnav-0.2.2-makefile.patch | 27 ++++++++ dev-libs/libspnav/libspnav-0.2.2.ebuild | 47 ++++++++++++++ dev-libs/libspnav/metadata.xml | 28 ++++++++ 5 files changed, 182 insertions(+) create mode 100644 dev-libs/libspnav/Manifest create mode 100644 dev-libs/libspnav/files/libspnav-0.2.2-custom-flags.patch create mode 100644 dev-libs/libspnav/files/libspnav-0.2.2-makefile.patch create mode 100644 dev-libs/libspnav/libspnav-0.2.2.ebuild create mode 100644 dev-libs/libspnav/metadata.xml (limited to 'dev-libs/libspnav') diff --git a/dev-libs/libspnav/Manifest b/dev-libs/libspnav/Manifest new file mode 100644 index 000000000000..3def35b43ca0 --- /dev/null +++ b/dev-libs/libspnav/Manifest @@ -0,0 +1,5 @@ +AUX libspnav-0.2.2-custom-flags.patch 2151 BLAKE2B 90868c4c60627a16c247a99cf3dd1fb1d9a49b39f2062de22a7d35223b86be553b9f76f2b363ece3593dec976eb3144163d3ce3ab416d6f8436e79e97fb84144 SHA512 f0f2ea3dcd689168780d17ca94b7c20378afeae72442da9c62f1d618b29ad7877d6f6a78e06ed276cff67e1fc57c2bf6fe371f1545fda99ce74f5ee260baa320 +AUX libspnav-0.2.2-makefile.patch 926 BLAKE2B 28533b0e1b91de397d150302be3ea35dfab22fd1fe2235ff41c5a755db48a4eac2365e2f5b03306157336cd9b09b422877c63c9798ddd2d8525ece94af7d8697 SHA512 ebaa5f5685fc55c0f5c0783efd20b2970be8a4ce3e5564b23c65348b1c72e1840d8c2277843cb4d7d3899579810228835f4aa59f99188e79a5543dca93522a21 +DIST libspnav-0.2.2.tar.gz 11615 BLAKE2B 470a533d9ae58b37cd1c1603381bfd3a3bca79b2fe15a81464727e2543433df2fdf32b8683464ade9aa9670f3c9af1ffddde58299678d89d977577ed324f1ebf SHA512 78b26e6fe4a98af579738743ac4bc2f1de5ccfa9316a103a58ebb935f281fba04b8c6c28c0d63abda15a52c0288e371231425a3a21b26c083a5de7ab101f1940 +EBUILD libspnav-0.2.2.ebuild 1083 BLAKE2B dcd24705baba8b43e0cf62f92d5568a7edf84422851c0012349d45fbac7fc775be3d5f3014ec8b395612681565c6d16038392fcd3798ac46f241fb937f56959f SHA512 a6a7ff7c37d855cc4a53908b5dc6f4b9be3e176a409ba7431f9a068339470301d17dfb5e172daee032d7e7f09bcf23bc0d0ba5739f7dca5b2c380249c165bc16 +MISC metadata.xml 1051 BLAKE2B 964339ac3fa7b2db5174f1a8fcea691118701433e9bf39f50125ca78ab224fdd6084cc50e59bf83bde7658a4e47c6d0561e4c04549b70c8c8826ebbb78b2672c SHA512 7b9a136b25f0f9775ffdc07814659b5d8029ddb8a96d3eed4b111c89ce12819a47c2a7798324ab2789caa6ab5364bc72a4720aa558e679fdd6011ff5381bba6b diff --git a/dev-libs/libspnav/files/libspnav-0.2.2-custom-flags.patch b/dev-libs/libspnav/files/libspnav-0.2.2-custom-flags.patch new file mode 100644 index 000000000000..cc96655bf469 --- /dev/null +++ b/dev-libs/libspnav/files/libspnav-0.2.2-custom-flags.patch @@ -0,0 +1,75 @@ +diff -Npur libspnav-0.2.2.orig/Makefile.in libspnav-0.2.2/Makefile.in +--- libspnav-0.2.2.orig/Makefile.in 2012-01-31 22:34:01.448356249 +0100 ++++ libspnav-0.2.2/Makefile.in 2012-01-31 22:39:20.229350669 +0100 +@@ -7,7 +7,8 @@ lib_so = $(soname).1 + + CC = gcc + AR = ar +-CFLAGS = $(opt) $(dbg) -std=c89 -fpic -pedantic -Wall -fno-strict-aliasing -I. ++CFLAGS = $(opt) -fpic -I. ++LDFLAGS = $(ldopt) -shared -Wl,-soname,$(soname) + + .PHONY: all + all: $(lib_a) $(lib_so) +@@ -16,7 +17,7 @@ $(lib_a): $(obj) + $(AR) rcs $@ $(obj) + + $(lib_so): $(obj) +- $(CC) -shared -Wl,-soname,$(soname) -o $@ $(obj) ++ $(CC) $(LDFLAGS) -o $@ $(obj) + + %.o: $(srcdir)/%.c + $(CC) $(CFLAGS) -c $< -o $@ +diff -Npur libspnav-0.2.2.orig/configure libspnav-0.2.2/configure +--- libspnav-0.2.2.orig/configure 2012-01-31 22:34:01.448356249 +0100 ++++ libspnav-0.2.2/configure 2012-01-31 22:34:39.703355615 +0100 +@@ -4,6 +4,7 @@ echo 'configuring spacenav library...' + + PREFIX=/usr/local + OPT=yes ++LDOPT=yes + DBG=yes + X11=yes + +@@ -26,6 +27,11 @@ for arg; do + --disable-opt) + OPT=no;; + ++ --enable-ldopt) ++ LDOPT=yes;; ++ --disable-ldopt) ++ LDOPT=no;; ++ + --enable-debug) + DBG=yes;; + --disable-debug) +@@ -44,6 +50,8 @@ for arg; do + echo ' --disable-x11: disable X11 communication mode' + echo ' --enable-opt: enable speed optimizations (default)' + echo ' --disable-opt: disable speed optimizations' ++ echo ' --enable-ldopt: enable link optimizations (default)' ++ echo ' --disable-ldopt: disable link optimizations' + echo ' --enable-debug: include debugging symbols (default)' + echo ' --disable-debug: do not include debugging symbols' + echo 'all invalid options are silently ignored' +@@ -54,6 +62,7 @@ done + + echo " prefix: $PREFIX" + echo " optimize for speed: $OPT" ++echo " optimize link: $LDOPT" + echo " include debugging symbols: $DBG" + echo " x11 communication method: $X11" + echo "" +@@ -74,7 +83,11 @@ if [ "$DBG" = 'yes' ]; then + fi + + if [ "$OPT" = 'yes' ]; then +- echo 'opt = -O3' >>Makefile ++ echo "opt = ${CFLAGS:--O3}" >>Makefile ++fi ++ ++if [ "$LDOPT" = 'yes' ]; then ++ echo "ldopt = ${LDFLAGS}" >>Makefile + fi + + if [ "$X11" = 'yes' ]; then diff --git a/dev-libs/libspnav/files/libspnav-0.2.2-makefile.patch b/dev-libs/libspnav/files/libspnav-0.2.2-makefile.patch new file mode 100644 index 000000000000..f65300c5f58a --- /dev/null +++ b/dev-libs/libspnav/files/libspnav-0.2.2-makefile.patch @@ -0,0 +1,27 @@ +diff -Npur libspnav-0.2.2.orig/Makefile.in libspnav-0.2.2/Makefile.in +--- libspnav-0.2.2.orig/Makefile.in 2012-01-31 22:40:36.619349333 +0100 ++++ libspnav-0.2.2/Makefile.in 2012-01-31 22:41:52.554347975 +0100 +@@ -11,7 +11,7 @@ CFLAGS = $(opt) -I. + LDFLAGS = $(ldopt) -shared -Wl,-soname,$(soname) + + .PHONY: all +-all: $(lib_a) $(lib_so) ++all: $(lib_so) + + $(lib_a): $(obj) + $(AR) rcs $@ $(obj) +@@ -31,10 +31,10 @@ distclean: + rm -f $(obj) $(lib_a) $(lib_so) Makefile + + .PHONY: install +-install: $(lib_a) $(lib_so) +- cp $(lib_a) $(PREFIX)/$(libdir)/$(lib_a) +- cp $(lib_so) $(PREFIX)/$(libdir)/$(lib_so) +- for h in $(hdr); do cp -p $(srcdir)/$$h $(PREFIX)/include/; done ++install: $(lib_so) ++ mkdir -p $(DESTDIR)$(PREFIX)/$(libdir) $(DESTDIR)$(PREFIX)/include ++ cp $(lib_so) $(DESTDIR)$(PREFIX)/$(libdir)/$(lib_so) ++ for h in $(hdr); do cp -p $(srcdir)/$$h $(DESTDIR)$(PREFIX)/include/; done + + .PHONY: uninstall + uninstall: diff --git a/dev-libs/libspnav/libspnav-0.2.2.ebuild b/dev-libs/libspnav/libspnav-0.2.2.ebuild new file mode 100644 index 000000000000..b97017ab74ea --- /dev/null +++ b/dev-libs/libspnav/libspnav-0.2.2.ebuild @@ -0,0 +1,47 @@ +# Copyright 1999-2017 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 + +EAPI="4" + +inherit multilib eutils toolchain-funcs + +MY_PN='spacenav' +DESCRIPTION="libspnav is a replacement for the magellan library with a cleaner API" +HOMEPAGE="http://spacenav.sourceforge.net/" +SRC_URI="mirror://sourceforge/project/${MY_PN}/${MY_PN}%20library%20%28SDK%29/${PN}%20${PV}/${P}.tar.gz" +LICENSE="BSD" +SLOT="0" +KEYWORDS="amd64 ppc64 x86" +IUSE="X" + +RDEPEND="app-misc/spacenavd[X?]" +DEPEND="" + +src_prepare() { + epatch "${FILESDIR}"/${P}-makefile.patch + epatch "${FILESDIR}"/${P}-custom-flags.patch +} + +src_configure() { + econf \ + --enable-opt --enable-ldopt \ + $(use_enable X x11) +} + +src_compile() { + emake CC=$(tc-getCC) +} + +src_install() { + default + + # Use proper libdir + if [[ $(get_libdir) != lib ]]; then + mv "${D}"/usr/{lib,$(get_libdir)} || die + fi + + # Create missing symlinks + local target=$(basename "${D}"/usr/$(get_libdir)/libspnav.so.*) + dosym ${target} /usr/$(get_libdir)/libspnav.so.0 || die + dosym ${target} /usr/$(get_libdir)/libspnav.so || die +} diff --git a/dev-libs/libspnav/metadata.xml b/dev-libs/libspnav/metadata.xml new file mode 100644 index 000000000000..9168a893a04d --- /dev/null +++ b/dev-libs/libspnav/metadata.xml @@ -0,0 +1,28 @@ + + + + + anthoine.bourgeois@gmail.com + Anthoine Bourgeois + + + sping@gentoo.org + Sebastian Pipping + + + proxy-maint@gentoo.org + Proxy Maintainers + + + The libspnav library is provided as a replacement of the magellan + library. It provides a cleaner, and more orthogonal interface. libspnav + supports both the original X11 protocol for communicating with the + driver, and the new alternative non-X protocol. Programs that choose to + use the X11 protocol, are automatically compatible with either the free + spacenavd driver or the official 3dxserv, as if they were using the + magellan SDK. + + + spacenav + + -- cgit v1.2.3