# $Id$ PNAME="networkmanager" PVER="0.8.5.91" PBUILD="r1" PCATEGORIE="net-misc" DESCRIPTION="Network configuration and management in an easy way." HOMEPAGE="http://projects.gnome.org/NetworkManager/" DEPEND=">= sys-apps/dbus-1.4 >= dev-libs/glib2-2.28 >= dev-libs/dbus-glib-0.92 >= dev-libs/libnl-1.1 >= dev-libs/nss-3.12.10 >= sys-fs/e2fsprogs-1.41.14 >= sys-fs/udev-171 >= sys-apps/polkit-0.101 >= net-misc/modemmanager-0.4 >= net-wlan/wireless-tools-30_pre9 >= net-wlan/wpa-supplicant-0.7.3 >= net-wlan/bluez-4.95 >= net-dns/avahi-0.6.30 >= net-misc/dhcpcd-5.2.12 >= net-dialup/ppp-2.4.5 >= sys-apps/iproute2-2.6.38 >= net-misc/iptables-1.4.11" SDEPEND=">= dev-util/pkgconfig-0.25 >= dev-util/intltool-0.41" SRCFILE="NetworkManager-${PVER}.tar.bz2" SRCDIR="${BUILDDIR}/NetworkManager-${PVER}" sminclude gnome2 mtools SRC_URI=( gnome://NetworkManager/${PVER%.*}/${SRCFILE} mirror://${PNAME}/${SRCFILE} mirror://${PNAME}/nm-system-settings.conf mirror://${PNAME}/${PNAME}-0.8.1-magellan.patch mirror://${PNAME}/${PNAME}-0.8.1-plugdev.patch mirror://${PNAME}/${PNAME}-0.8.1-hostname.patch ) UP2DATE="updatecmd_gnome NetworkManager" src_prepare() { munpack ${SRCFILE} || die cd ${SRCDIR} # support our distro mpatch ${PNAME}-0.8.1-magellan.patch || die # allow plugdev group to do things mpatch ${PNAME}-0.8.1-plugdev.patch || die # do not change the hostname on magellan mpatch ${PNAME}-0.8.1-hostname.patch || die # regen configure files autoreconf --verbose --install --force || die } src_compile() { cd ${SRCDIR} mconfigure \ --libexecdir=/usr/$(mlibdir)/${PNAME} \ --localstatedir=/var \ --disable-more-warnings \ --disable-gtk-doc \ --with-distro=magellan \ --with-dbus-sys-dir=/etc/dbus-1/system.d \ --with-udev-dir=/lib/udev \ --with-iptables=/sbin/iptables \ --with-dhcp-client=dhcpcd \ --with-crypto=nss \ --without-docs \ --without-resolvconf \ || die mmake || die } src_install() { cd ${SRCDIR} mmake DESTDIR=${BINDIR} install || die # needed directories mkeepdir /etc/NetworkManager/dispatcher.d || die mkeepdir /var/run/NetworkManager || die # add keyfile plugin support mkeepdir /etc/NetworkManager/system-connections || die minstallfile -s nm-system-settings.conf /etc/NetworkManager/ || die minstalldocs AUTHORS ChangeLog NEWS README TODO || die } postinstall() { # restart dbus to load the nm config mstartservice dbus /usr/bin/dbus-daemon echo echo "To save system-wide settings as a user, that user needs to have the" echo "right policykit privileges. You can add them by running:" echo 'polkit-auth --grant org.freedesktop.network-manager-settings.system.modify --user "USERNAME"' echo } postremove() { if [ ! -f ${MROOT}/usr/bin/dbus-daemon ] then mstopservice dbus /usr/bin/dbus-daemon fi }