libgudev: add gir build option; disabled in cross builds.
This commit is contained in:
parent
626066819d
commit
c5c5832799
1 changed files with 25 additions and 6 deletions
|
@ -4,23 +4,40 @@
|
|||
unset -f systemd_package systemd-libs_package systemd-devel_package
|
||||
unset -f libudev_package libudev-devel_package post_install
|
||||
|
||||
# XXX keep ${version} and ${revision} sync with systemd/template.
|
||||
pkgname=libgudev
|
||||
version=208
|
||||
revision=4
|
||||
revision=5
|
||||
wrksrc="systemd-${version}"
|
||||
configure_args+=" --enable-gudev --with-python --enable-introspection"
|
||||
configure_args+=" --enable-gudev --with-python"
|
||||
short_desc="GUdev shared library"
|
||||
|
||||
hostmakedepends+=" gobject-introspection"
|
||||
hostmakedepends+=" glib-devel python-devel"
|
||||
makedepends+=" libglib-devel python-devel"
|
||||
|
||||
# Package build options
|
||||
build_options="gir"
|
||||
desc_option_gir="Enable support for building gobject introspection data"
|
||||
|
||||
# Disable gir for cross builds.
|
||||
if [ -z "$CROSS_BUILD" ]; then
|
||||
build_options_default="gir"
|
||||
fi
|
||||
|
||||
if [ "$build_option_gir" ]; then
|
||||
configure_args+=" --enable-introspection"
|
||||
hostmakedepends+=" gobject-introspection"
|
||||
else
|
||||
configure_args+=" --disable-introspection"
|
||||
fi
|
||||
|
||||
libgudev_package() {
|
||||
short_desc="GObject-based wrapper library for libudev"
|
||||
depends="libudev>=${version}"
|
||||
pkg_install() {
|
||||
vmove "usr/lib/libgudev*.so.*"
|
||||
vmove usr/lib/girepository-1.0
|
||||
if [ "$build_option_gir" ]; then
|
||||
vmove usr/lib/girepository-1.0
|
||||
fi
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -31,7 +48,9 @@ libgudev-devel_package() {
|
|||
vmove usr/include/gudev-1.0
|
||||
vmove "usr/lib/libgudev*.so"
|
||||
vmove "usr/lib/pkgconfig/gudev*"
|
||||
vmove usr/share/gir-1.0
|
||||
if [ "$build_option_gir" ]; then
|
||||
vmove usr/share/gir-1.0
|
||||
fi
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue