Skip to content
Browse files

FL-460: fork upower, reduce virtual/udev dependency

  • Loading branch information...
1 parent 3ba39a2 commit 0d78410c86189403c2c239619d17d480afd9e83f @angryvincent angryvincent committed Mar 21, 2013
View
2 sys-power/upower/Manifest
@@ -0,0 +1,2 @@
+DIST upower-0.9.19.tar.xz 411604 SHA256 54c7facb3049f3c1b6ff9510c46aa378f53a2eb606a3ce7be3f6b0a227547e14 SHA512 616502dddec23108fc51662e0e08efc2cd7893043558696ea87cc02c05b85322362be3740c81674b619f5e7acfaa42bdbd56444faab8c11820ebc427e127a9b7 WHIRLPOOL 0cbe033a8ace8520f86f025b513e20d24dbe5e529baa1df1aaebf67ec548a7433ae4f6ba433fd96611722bc7722311c57506270593bb29a942f69f0abb2b4ab1
+DIST upower-0.9.20.tar.xz 413632 SHA256 6817237486561294b1004a9a50a01a4d69f17e8d708c6baf9d92104fe2e6e184 SHA512 d78fc0f53a89e72753c6807ccec70209efa0660c9b93ecdf450c43d33a6f8e39e55ad790ce19c67d335ec137655cf701b09069dbfc68707a8ba6fdbda72fde72 WHIRLPOOL 7fc09931304ef53373cb335d912f4a61c15f5522220fde88c829a4b02ea9dd8eeb42f1070e42e2532fb17d2fea7d3b228539efdfe3337d6b32bccb4e76cbfd6d
View
11 sys-power/upower/metadata.xml
@@ -0,0 +1,11 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
+<pkgmetadata>
+ <herd>freedesktop</herd>
+ <maintainer>
+ <email>freedesktop-bugs@gentoo.org</email>
+ </maintainer>
+ <use>
+ <flag name='deprecated'>Use <pkg>sys-power/pm-utils</pkg> (deprecated) instead of <pkg>sys-apps/systemd</pkg></flag>
+ </use>
+</pkgmetadata>
View
83 sys-power/upower/upower-0.9.19.ebuild
@@ -0,0 +1,83 @@
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=5
+
+# PYTHON_DEPEND="test? 3"
+# inherit python
+
+inherit eutils systemd udev
+
+DESCRIPTION="D-Bus abstraction for enumerating power devices and querying history and statistics"
+HOMEPAGE="http://upower.freedesktop.org/"
+SRC_URI="http://${PN}.freedesktop.org/releases/${P}.tar.xz"
+
+LICENSE="GPL-2"
+SLOT="0"
+KEYWORDS="*"
+IUSE="debug doc +introspection ios kernel_FreeBSD kernel_linux systemd" # test
+
+COMMON_DEPEND=">=dev-libs/dbus-glib-0.100
+ >=dev-libs/glib-2.22
+ sys-apps/dbus
+ >=sys-auth/polkit-0.104-r1
+ introspection? ( dev-libs/gobject-introspection )
+ kernel_linux? (
+ virtual/libusb:1
+ virtual/udev[gudev]
+ ios? (
+ >=app-pda/libimobiledevice-1
+ >=app-pda/libplist-1
+ )
+ )
+ systemd? ( sys-apps/systemd )"
+RDEPEND="${COMMON_DEPEND}
+ kernel_linux? ( >=sys-power/pm-utils-1.4.1 )
+ systemd? ( app-shells/bash )"
+DEPEND="${COMMON_DEPEND}
+ dev-libs/libxslt
+ app-text/docbook-xsl-stylesheets
+ dev-util/intltool
+ virtual/pkgconfig
+ doc? (
+ dev-util/gtk-doc
+ app-text/docbook-xml-dtd:4.1.2
+ )"
+
+src_prepare() {
+ sed -i -e '/DISABLE_DEPRECATED/d' configure || die
+}
+
+src_configure() {
+ local backend
+
+ if use kernel_linux; then
+ backend=linux
+ elif use kernel_FreeBSD; then
+ backend=freebsd
+ else
+ backend=dummy
+ fi
+
+ econf \
+ --localstatedir="${EPREFIX}"/var \
+ $(use_enable introspection) \
+ --disable-static \
+ $(use_enable debug verbose-mode) \
+ --enable-man-pages \
+ $(use_enable doc gtk-doc) \
+ $(use_enable systemd) \
+ --disable-tests \
+ --with-html-dir="${EPREFIX}"/usr/share/doc/${PF}/html \
+ --with-backend=${backend} \
+ $(use_with ios idevice) \
+ "$(systemd_with_utildir)" \
+ "$(systemd_with_unitdir)"
+}
+
+src_install() {
+ emake DESTDIR="${D}" udevrulesdir="$(udev_get_udevdir)"/rules.d install
+
+ dodoc AUTHORS HACKING NEWS README
+ keepdir /var/lib/upower #383091
+ prune_libtool_files
+}
View
86 sys-power/upower/upower-0.9.20-r1.ebuild
@@ -0,0 +1,86 @@
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=5
+inherit eutils systemd udev
+
+DESCRIPTION="D-Bus abstraction for enumerating power devices and querying history and statistics"
+HOMEPAGE="http://upower.freedesktop.org/"
+SRC_URI="http://${PN}.freedesktop.org/releases/${P}.tar.xz"
+
+LICENSE="GPL-2"
+SLOT="0"
+KEYWORDS="~*"
+IUSE="+deprecated doc +introspection ios kernel_FreeBSD kernel_linux systemd"
+
+COMMON_DEPEND=">=dev-libs/dbus-glib-0.100
+ >=dev-libs/glib-2.22
+ sys-apps/dbus
+ >=sys-auth/polkit-0.110
+ introspection? ( dev-libs/gobject-introspection )
+ kernel_linux? (
+ virtual/libusb:1
+ >=virtual/udev-171[gudev]
+ ios? (
+ >=app-pda/libimobiledevice-1
+ >=app-pda/libplist-1
+ )
+ systemd? ( sys-apps/systemd )
+ )"
+RDEPEND="${COMMON_DEPEND}
+ kernel_linux? (
+ deprecated? ( >=sys-power/pm-utils-1.4.1 )
+ systemd? ( app-shells/bash )
+ )"
+DEPEND="${COMMON_DEPEND}
+ dev-libs/libxslt
+ app-text/docbook-xsl-stylesheets
+ dev-util/intltool
+ virtual/pkgconfig
+ doc? (
+ dev-util/gtk-doc
+ app-text/docbook-xml-dtd:4.1.2
+ )"
+REQUIRED_USE="kernel_linux? ( !deprecated? ( systemd ) )"
+
+QA_MULTILIB_PATHS="usr/lib/${PN}/.*"
+
+src_prepare() {
+ sed -i -e '/DISABLE_DEPRECATED/d' configure || die
+}
+
+src_configure() {
+ local backend myconf
+
+ if use kernel_linux; then
+ backend=linux
+ myconf="$(use_enable deprecated)"
+ elif use kernel_FreeBSD; then
+ backend=freebsd
+ else
+ backend=dummy
+ fi
+
+ econf \
+ --libexecdir="${EPREFIX}"/usr/lib/${PN} \
+ --localstatedir="${EPREFIX}"/var \
+ $(use_enable introspection) \
+ --disable-static \
+ ${myconf} \
+ --enable-man-pages \
+ $(use_enable doc gtk-doc) \
+ $(use_enable systemd) \
+ --disable-tests \
+ --with-html-dir="${EPREFIX}"/usr/share/doc/${PF}/html \
+ --with-backend=${backend} \
+ $(use_with ios idevice) \
+ "$(systemd_with_utildir)" \
+ "$(systemd_with_unitdir)"
+}
+
+src_install() {
+ emake DESTDIR="${D}" udevrulesdir="$(get_udevdir)"/rules.d install
+
+ dodoc AUTHORS HACKING NEWS README
+ keepdir /var/lib/upower #383091
+ prune_libtool_files
+}
View
81 sys-power/upower/upower-0.9.20.ebuild
@@ -0,0 +1,81 @@
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=5
+inherit eutils systemd udev
+
+DESCRIPTION="D-Bus abstraction for enumerating power devices and querying history and statistics"
+HOMEPAGE="http://upower.freedesktop.org/"
+SRC_URI="http://${PN}.freedesktop.org/releases/${P}.tar.xz"
+
+LICENSE="GPL-2"
+SLOT="0"
+KEYWORDS="~*"
+IUSE="doc +introspection ios kernel_FreeBSD kernel_linux systemd"
+
+COMMON_DEPEND=">=dev-libs/dbus-glib-0.100
+ >=dev-libs/glib-2.22
+ sys-apps/dbus
+ >=sys-auth/polkit-0.110
+ introspection? ( dev-libs/gobject-introspection )
+ kernel_linux? (
+ virtual/libusb:1
+ =virtual/udev-171[gudev]
+ ios? (
+ >=app-pda/libimobiledevice-1
+ >=app-pda/libplist-1
+ )
+ systemd? ( sys-apps/systemd )
+ )"
+RDEPEND="${COMMON_DEPEND}
+ kernel_linux? (
+ systemd? ( app-shells/bash )
+ !systemd? ( >=sys-power/pm-utils-1.4.1 )
+ )"
+DEPEND="${COMMON_DEPEND}
+ dev-libs/libxslt
+ app-text/docbook-xsl-stylesheets
+ dev-util/intltool
+ virtual/pkgconfig
+ doc? (
+ dev-util/gtk-doc
+ app-text/docbook-xml-dtd:4.1.2
+ )"
+
+src_prepare() {
+ sed -i -e '/DISABLE_DEPRECATED/d' configure || die
+}
+
+src_configure() {
+ local backend
+
+ if use kernel_linux; then
+ backend=linux
+ elif use kernel_FreeBSD; then
+ backend=freebsd
+ else
+ backend=dummy
+ fi
+
+ econf \
+ --localstatedir="${EPREFIX}"/var \
+ $(use_enable introspection) \
+ --disable-static \
+ $(use_enable !systemd deprecated) \
+ --enable-man-pages \
+ $(use_enable doc gtk-doc) \
+ $(use_enable systemd) \
+ --disable-tests \
+ --with-html-dir="${EPREFIX}"/usr/share/doc/${PF}/html \
+ --with-backend=${backend} \
+ $(use_with ios idevice) \
+ "$(systemd_with_utildir)" \
+ "$(systemd_with_unitdir)"
+}
+
+src_install() {
+ emake DESTDIR="${D}" udevrulesdir="$(get_udevdir)"/rules.d install
+
+ dodoc AUTHORS HACKING NEWS README
+ keepdir /var/lib/upower #383091
+ prune_libtool_files
+}

0 comments on commit 0d78410

Please sign in to comment.
Something went wrong with that request. Please try again.