/[gentoo-x86]/net-misc/modemmanager/modemmanager-1.4.0.ebuild
Gentoo

Contents of /net-misc/modemmanager/modemmanager-1.4.0.ebuild

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1.1 - (hide annotations) (download)
Tue Sep 23 12:28:41 2014 UTC (5 years, 4 months ago) by pacho
Branch: MAIN
Version bump, drop old

(Portage version: 2.2.12/cvs/Linux x86_64, signed Manifest commit with key A188FBD4)

1 pacho 1.1 # Copyright 1999-2014 Gentoo Foundation
2     # Distributed under the terms of the GNU General Public License v2
3     # $Header: /var/cvsroot/gentoo-x86/net-misc/modemmanager/modemmanager-1.2.0-r1.ebuild,v 1.7 2014/09/12 19:28:47 vincent Exp $
4    
5     EAPI="5"
6     GCONF_DEBUG="no"
7     GNOME2_LA_PUNT="yes"
8     VALA_MIN_API_VERSION="0.18"
9     VALA_USE_DEPEND="vapigen"
10    
11     inherit gnome2 user readme.gentoo udev vala
12    
13     DESCRIPTION="Modem and mobile broadband management libraries"
14     HOMEPAGE="http://cgit.freedesktop.org/ModemManager/ModemManager/"
15     SRC_URI="http://www.freedesktop.org/software/ModemManager/ModemManager-${PV}.tar.xz"
16    
17     LICENSE="GPL-2+"
18     SLOT="0/1" # subslot = dbus interface version, i.e. N in org.freedesktop.ModemManager${N}
19     KEYWORDS="~alpha ~amd64 ~arm ~ia64 ~mips ~ppc ~ppc64 ~sparc ~x86"
20     IUSE="+introspection mbim policykit +qmi qmi-newest vala"
21     REQUIRED_USE="
22     qmi-newest? ( qmi )
23     vala? ( introspection )
24     "
25    
26     RDEPEND="
27     >=dev-libs/glib-2.32:2
28     virtual/libgudev:=
29     introspection? ( >=dev-libs/gobject-introspection-0.9.6 )
30     mbim? ( >=net-libs/libmbim-1.10 )
31     policykit? ( >=sys-auth/polkit-0.106[introspection] )
32     qmi? ( >=net-libs/libqmi-1.6.0:= )
33     "
34     DEPEND="${RDEPEND}
35     dev-util/gdbus-codegen
36     >=dev-util/intltool-0.40
37     sys-devel/gettext
38     virtual/pkgconfig
39     vala? ( $(vala_depend) )
40     "
41    
42     S="${WORKDIR}/ModemManager-${PV}"
43    
44     src_prepare() {
45     DOC_CONTENTS="If your USB modem shows up as a Flash drive when you plug it in,
46     You should install sys-apps/usb_modeswitch which will automatically
47     switch it over to USB modem mode whenever you plug it in.\n"
48    
49     if use policykit; then
50     DOC_CONTENTS+="\nTo control your modem without needing to enter the root password,
51     add your user account to the 'plugdev' group."
52     fi
53    
54     use vala && vala_src_prepare
55     gnome2_src_prepare
56     }
57    
58     src_configure() {
59     gnome2_src_configure \
60     --disable-more-warnings \
61     --with-udev-base-dir="$(get_udevdir)" \
62     --disable-static \
63     --with-dist-version=${PVR} \
64     $(use_enable introspection) \
65     $(use_with mbim) \
66     $(use_with policykit polkit) \
67     $(use_with qmi) \
68     $(use_with qmi-newest newest-qmi-commands) \
69     $(use_enable vala)
70     }
71    
72     src_install() {
73     gnome2_src_install
74    
75     # Allow users in plugdev group full control over their modem
76     if use policykit; then
77     insinto /usr/share/polkit-1/rules.d/
78     doins "${FILESDIR}"/01-org.freedesktop.ModemManager1.rules
79     fi
80    
81     readme.gentoo_create_doc
82     }
83    
84     pkg_postinst() {
85     gnome2_pkg_postinst
86    
87     use policykit && enewgroup plugdev
88    
89     # The polkit rules file moved to /usr/share
90     old_rules="${EROOT}etc/polkit-1/rules.d/01-org.freedesktop.ModemManager.rules"
91     if [[ -f "${old_rules}" ]]; then
92     case "$(md5sum ${old_rules})" in
93     c5ff02532cb1da2c7545c3069e5d0992* | 5c50f0dc603c0a56e2851a5ce9389335* )
94     # Automatically delete the old rules.d file if the user did not change it
95     elog
96     elog "Removing old ${old_rules} ..."
97     rm -f "${old_rules}" || eerror "Failed, please remove ${old_rules} manually"
98     ;;
99     * )
100     elog "The ${old_rules}"
101     elog "file moved to /usr/share/polkit-1/rules.d/ in >=modemmanager-0.5.2.0-r2"
102     elog "If you edited ${old_rules}"
103     elog "without changing its behavior, you may want to remove it."
104     ;;
105     esac
106     fi
107    
108     readme.gentoo_print_elog
109     }

  ViewVC Help
Powered by ViewVC 1.1.20