# $Id$ PNAME="networkmanager" PVER="0.7.999" PBUILD="r1" PCATEGORIE="net-misc" STATE="unstable" DESCRIPTION="Network configuration and management in an easy way." HOMEPAGE="http://projects.gnome.org/NetworkManager/" DEPEND=">= sys-apps/dbus-1.3 >= dev-libs/glib2-2.22 >= dev-libs/dbus-glib-0.82 >= dev-libs/libnl-1.1 >= dev-libs/nss-3.12.4 >= sys-fs/e2fsprogs-1.41.9 >= sys-fs/udev-146 >= sys-apps/polkit-0.96 >= net-misc/modemmanager-0.2 >= net-wlan/wireless-tools-30_pre8 >= net-wlan/wpa_supplicant-0.6.9 >= net-wireless/bluez-4.56 >= net-dns/avahi-0.6.25 >= net-misc/dhcpcd-5.1.1 >= net-dialup/ppp-2.4.4 >= sys-apps/iproute2-2.6.29 >= net-misc/iptables1-1.4.5" SDEPEND=">= dev-util/pkgconfig-0.23 >= dev-util/intltool-0.40" 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}-${PVER}-magellan.patch mirror://${PNAME}/${PNAME}-${PVER}-plugdev.patch mirror://${PNAME}/${PNAME}-${PVER}-hostname.patch ) UP2DATE="updatecmd_gnome NetworkManager" src_prepare() { munpack ${SRCFILE} || die cd ${SRCDIR} # support our distro mpatch ${PNAME}-${PVER}-magellan.patch || die # allow plugdev group to do things mpatch ${PNAME}-${PVER}-plugdev.patch || die # do not change the hostname on magellan mpatch ${PNAME}-${PVER}-hostname.patch || die } src_compile() { cd ${SRCDIR} mconfigure \ --localstatedir=/var \ --disable-more-warnings \ --disable-gtk-doc \ --with-distro=magellan \ --with-dbus-sys-dir=/etc/dbus-1/system.d \ --with-udev-dir=/etc/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 }