void-packages/srcpkgs/libdbus-c++/template
Jürgen Buchmüller fcc85e5c21 libdbus-c++: update to 0.9.1pw
Enable cross build and change distfiles to use the fork
at https://github.com/pkgw/dbus-cplusplus.

Signed-off-by: Jürgen Buchmüller <pullmoll@t-online.de>
2018-03-20 12:08:29 +01:00

51 lines
1.4 KiB
Bash

# Template file for 'libdbus-c++'
pkgname=libdbus-c++
version=0.9.1pw
revision=1
wrksrc="${pkgname//+/-}-${version}"
build_style=gnu-configure
configure_args="--enable-glib --disable-ecore"
hostmakedepends="automake libtool pkg-config"
makedepends="dbus-devel glib-devel"
short_desc="A C++ API for D-BUS"
maintainer="Duncaen <mail@duncano.de>"
license="LGPL-2"
homepage="http://dbus-cplusplus.sourceforge.net/"
distfiles="https://github.com/pkgw/dbus-cplusplus/releases/download/v${version}/libdbus-c---${version}.tar.gz"
checksum=a762af8fbee01434f925ce8c3140cb43088390d5cab492e802fe6873d809cc6c
if [ -n "$CROSS_BUILD" ]; then
hostmakedepends+=" libdbus-c++-devel dbus-devel glib-devel"
fi
pre_configure() {
NOCONFIGURE=1 autoreconf -fi
}
post_install() {
if [ -n "$CROSS_BUILD" ]; then
# Re-build tools for the target architecture
sed -i tools/Makefile \
-e "s;^\(CXX =\).*;\1 $CXX;" \
-e "s;^\(CFLAGS =\).*;\1 $CFLAGS;" \
-e "s;^\(CXXFLAGS =\).*;\1 $CXXFLAGS;" \
-e "s;^\(LDFLAGS =\).*;\1 $LDFLAGS;" \
-e "/^libdbus_cxx_la/d" \
-e "s;#\(libdbus_cxx_la = .*\);\1;"
make -C tools clean
make -C tools ${makejobs}
vbin tools/dbusxx-xml2cpp
vbin tools/dbusxx-introspect
fi
}
libdbus-c++-devel_package() {
short_desc+=" - development files"
depends="${sourcepkg}-${version}_${revision}"
pkg_install() {
vmove usr/include
vmove "usr/lib/*.a"
vmove "usr/lib/*.so"
vmove usr/lib/pkgconfig
}
}