diff options
author | Leo <thinkabit.ukim@gmail.com> | 2020-03-16 02:26:02 -0300 |
---|---|---|
committer | Leo <thinkabit.ukim@gmail.com> | 2020-03-23 12:07:30 -0300 |
commit | 41ab224df12b8487004a1522b4f671680c082954 (patch) | |
tree | 9ebbc4ea5d1cfb82757ca1fd862b67e444a712a2 /community/libcrystalhd | |
parent | 1f40937c55d742c7ae05db34c966c3dd2d6595e7 (diff) | |
download | aports-41ab224df12b8487004a1522b4f671680c082954.tar.bz2 aports-41ab224df12b8487004a1522b4f671680c082954.tar.xz |
community/*: move lots of stuff from main and modernize
Diffstat (limited to 'community/libcrystalhd')
-rw-r--r-- | community/libcrystalhd/APKBUILD | 50 | ||||
-rw-r--r-- | community/libcrystalhd/gcc-opts-fix.patch | 17 |
2 files changed, 67 insertions, 0 deletions
diff --git a/community/libcrystalhd/APKBUILD b/community/libcrystalhd/APKBUILD new file mode 100644 index 0000000000..eadf0f116d --- /dev/null +++ b/community/libcrystalhd/APKBUILD @@ -0,0 +1,50 @@ +# Contributor: Carlo Landmeter <clandmeter@gmail.com> +# Maintainer: Natanael Copa <ncopa@alpinelinux.org> +pkgname=libcrystalhd +pkgver=20130708 +_date=$pkgver +pkgrel=3 +pkgdesc="Broadcom CrystalHD kernel driver library" +url="https://git.linuxtv.org/jarod/crystalhd.git" +arch="x86 x86_64" +license="LGPL-2.1-only" +options="!check" # No test suite +makedepends="linux-headers" +subpackages="$pkgname-dev" +source="https://dev.alpinelinux.org/archive/libcrystalhd/libcrystalhd-$_date.tar.gz + gcc-opts-fix.patch + " + +_giturl="git://linuxtv.org/jarod/crystalhd.git" +_upload="dev.alpinelinux.org:/archive/$pkgname/" +builddir="$srcdir/$pkgname-$_date/linux_lib/libcrystalhd" + +snapshot() { + local _date=$(date +%Y%m%d) + local _pkg=$pkgname-$_date.tar.gz + mkdir -p "$srcdir" + cd "$srcdir" + msg "Creating snapshot: $_pkg" + rm -rf ${_giturl##*/} + git clone --depth=1 --bare $_giturl + git --git-dir ${_giturl##*/} archive -o $_pkg \ + --prefix=$pkgname-$_date/ HEAD + msg "Uploading to $_upload" + rsync -Lave ssh $_pkg $_upload + cd "$startdir" + sed -i -e "s/^pkgver=.*/pkgver=$_date/" \ + APKBUILD + abuild checksum +} + +build() { + msg "Building library" + make +} + +package() { + make DESTDIR="$pkgdir" install +} + +sha512sums="70a84f8102250a797b658153d7cd2ed2b05d00d801b52a0b6f877e0feecd55a83c32032c5b66dba8cb53863dabc5536dde6405087403d8fe730c27f6ea3ee1b2 libcrystalhd-20130708.tar.gz +8ff2710dfd1580d1dc05a67e2bf07679f37de67768df6267a7037bc25f94a4ea46be4c52057b4a849fe8774bd9c80f75df8f95a62eeec2f7b7a1e6622f6d9bae gcc-opts-fix.patch" diff --git a/community/libcrystalhd/gcc-opts-fix.patch b/community/libcrystalhd/gcc-opts-fix.patch new file mode 100644 index 0000000000..8c27216cdc --- /dev/null +++ b/community/libcrystalhd/gcc-opts-fix.patch @@ -0,0 +1,17 @@ +Description: Patch to fix build failures on non x86 machines. +Origin: Debian + +--- a/Makefile ++++ b/Makefile +@@ -24,7 +24,10 @@ + # -D_USE_SHMEM_ + + CPPFLAGS += ${INCLUDES} +-CPPFLAGS += -O2 -Wall -fPIC -shared -fstrict-aliasing -msse2 ++CPPFLAGS += -O2 -Wall -fPIC -shared -fstrict-aliasing ++MACHINE_OPTS = $(shell gcc -xc -c /dev/null -msse2 -o /dev/null \ ++ >/dev/null 2>&1 && echo -msse2) ++CPPFLAGS += $(MACHINE_OPTS) + LDFLAGS = -Wl,-soname,${BCLIB_SL} -pthread + + SRCFILES = libcrystalhd_if.cpp \ |