From 25a0117e910463b26b981c3d6f1afb31c97f0432 Mon Sep 17 00:00:00 2001 From: bra1nwave Date: Tue, 31 Jul 2018 09:35:15 +0200 Subject: [PATCH] New package: hamlib-3.3 closes #1326 --- common/shlibs | 2 ++ srcpkgs/hamlib-devel | 1 + srcpkgs/hamlib/patches/fix-cross-perl.patch | 12 +++++++ srcpkgs/hamlib/template | 36 +++++++++++++++++++++ 4 files changed, 51 insertions(+) create mode 120000 srcpkgs/hamlib-devel create mode 100644 srcpkgs/hamlib/patches/fix-cross-perl.patch create mode 100644 srcpkgs/hamlib/template diff --git a/common/shlibs b/common/shlibs index b0484c27a5b..7b44ef4262d 100644 --- a/common/shlibs +++ b/common/shlibs @@ -3332,3 +3332,5 @@ libfstrcmp.so.0 libfstrcmp-0.7.D001_1 libUMP.so.3 libump-git-20181122_2 libdri2.so.1 libdri2-git-20140317_2 libpst.so.4 libpst-0.6.72_1 +libhamlib.so.2 hamlib-3.3_1 +libhamlib++.so.2 hamlib-3.3_1 diff --git a/srcpkgs/hamlib-devel b/srcpkgs/hamlib-devel new file mode 120000 index 00000000000..aa339f5db7f --- /dev/null +++ b/srcpkgs/hamlib-devel @@ -0,0 +1 @@ +hamlib \ No newline at end of file diff --git a/srcpkgs/hamlib/patches/fix-cross-perl.patch b/srcpkgs/hamlib/patches/fix-cross-perl.patch new file mode 100644 index 00000000000..04f44d94458 --- /dev/null +++ b/srcpkgs/hamlib/patches/fix-cross-perl.patch @@ -0,0 +1,12 @@ +--- bindings/Makefile.am.orig ++++ bindings/Makefile.am +@@ -47,6 +47,9 @@ + PREFIX="$(prefix)" \ + INC="$(AM_CPPFLAGS)" \ + CC="$(CC)" \ ++ LD="$(CC)" \ ++ CCFLAGS="${CFLAGS}" \ ++ OPTIMIZE="${CFLAGS}" \ + OBJECT="hamlibperl_wrap.o" \ + VERSION="$(PACKAGE_VERSION)" \ + LIBS="-L$(top_builddir)/src/.libs -lhamlib" diff --git a/srcpkgs/hamlib/template b/srcpkgs/hamlib/template new file mode 100644 index 00000000000..a5e5d68629c --- /dev/null +++ b/srcpkgs/hamlib/template @@ -0,0 +1,36 @@ +# Template file for 'hamlib' +pkgname=hamlib +version=3.3 +revision=1 +build_style=gnu-configure +configure_args="--disable-static --with-perl-binding --with-python-binding + --with-tcl-binding --with-xml-support" +pycompile_module="Hamlib.py" +hostmakedepends="automake libtool pkg-config python3 swig" +makedepends="gettext-devel libusb-devel libxml2-devel python3-devel readline-devel + tcl-devel" +depends="perl" +short_desc="Library to control radio transceivers and receivers" +maintainer="bra1nwave " +license="LGPL-2.1-or-later, GPL-2.0-or-later" +homepage="https://sourceforge.net/projects/hamlib/" +distfiles="${SOURCEFORGE_SITE}/hamlib/${version}/${pkgname}-${version}.tar.gz" +checksum=c90b53949c767f049733b442cd6e0a48648b55d99d4df5ef3f852d985f45e880 + +pre_configure() { + CFLAGS+=" -DNO_POSIX_2008_LOCALE -D_GNU_SOURCE" + export PYTHON_CPPFLAGS="-I${XBPS_CROSS_BASE}/${py3_inc}" + export PYTHON_LIBS="-L${XBPS_CROSS_BASE}/usr/lib -lpython${py3_ver}${py3_abiver}" + autoreconf -fi +} + +hamlib-devel_package() { + short_desc+=" - development files" + depends="${sourcepkg}>=${version}_${revision}" + pkg_install() { + vmove usr/include + vmove "usr/lib/*.so" + vmove usr/lib/pkgconfig + vmove usr/share/aclocal + } +}