summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorKenneth Prugh <ken69267@gentoo.org>2010-07-25 22:02:46 +0000
committerKenneth Prugh <ken69267@gentoo.org>2010-07-25 22:02:46 +0000
commit6311f9a5f705825e48abbbf4b52f4d9c4c8e8670 (patch)
tree7ce6a3986a20f700dd15d27d11bc441713d725fb /media-libs/libmtp
parentactually drop perl-app inherit too (diff)
downloadgentoo-2-6311f9a5f705825e48abbbf4b52f4d9c4c8e8670.tar.gz
gentoo-2-6311f9a5f705825e48abbbf4b52f4d9c4c8e8670.tar.bz2
gentoo-2-6311f9a5f705825e48abbbf4b52f4d9c4c8e8670.zip
Set group to plugdev with udev
(Portage version: 2.2_rc67/cvs/Linux x86_64)
Diffstat (limited to 'media-libs/libmtp')
-rw-r--r--media-libs/libmtp/ChangeLog8
-rw-r--r--media-libs/libmtp/files/permissions.patch11
-rw-r--r--media-libs/libmtp/libmtp-1.0.3-r1.ebuild50
3 files changed, 68 insertions, 1 deletions
diff --git a/media-libs/libmtp/ChangeLog b/media-libs/libmtp/ChangeLog
index 3af684b674bc..bc4f558e9e48 100644
--- a/media-libs/libmtp/ChangeLog
+++ b/media-libs/libmtp/ChangeLog
@@ -1,6 +1,12 @@
# ChangeLog for media-libs/libmtp
# Copyright 1999-2010 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/media-libs/libmtp/ChangeLog,v 1.83 2010/07/25 15:39:38 jer Exp $
+# $Header: /var/cvsroot/gentoo-x86/media-libs/libmtp/ChangeLog,v 1.84 2010/07/25 22:02:45 ken69267 Exp $
+
+*libmtp-1.0.3-r1 (25 Jul 2010)
+
+ 25 Jul 2010; Kenneth Prugh <ken69267@gentoo.org> +libmtp-1.0.3-r1.ebuild,
+ +files/permissions.patch:
+ Set group to plugdev with udev
25 Jul 2010; Jeroen Roovers <jer@gentoo.org> libmtp-1.0.3.ebuild:
Stable for PPC (bug #327675).
diff --git a/media-libs/libmtp/files/permissions.patch b/media-libs/libmtp/files/permissions.patch
new file mode 100644
index 000000000000..e473c24eb781
--- /dev/null
+++ b/media-libs/libmtp/files/permissions.patch
@@ -0,0 +1,11 @@
+--- examples/hotplug.c.orig 2010-07-23 21:32:12.000000000 -0400
++++ examples/hotplug.c 2010-07-25 16:39:22.000000000 -0400
+@@ -54,7 +54,7 @@
+ extern int optind;
+ extern char *optarg;
+ char *udev_action = NULL;
+- char default_udev_action[] = "SYMLINK+=\"libmtp-%k\", MODE=\"666\"";
++ char default_udev_action[] = "SYMLINK+=\"libmtp-%k\", MODE=\"0660\", GROUP=\"plugdev\"";
+ char *action; // To hold the action actually used.
+ uint16_t last_vendor = 0x0000U;
+
diff --git a/media-libs/libmtp/libmtp-1.0.3-r1.ebuild b/media-libs/libmtp/libmtp-1.0.3-r1.ebuild
new file mode 100644
index 000000000000..110ef28f56cd
--- /dev/null
+++ b/media-libs/libmtp/libmtp-1.0.3-r1.ebuild
@@ -0,0 +1,50 @@
+# Copyright 1999-2010 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: /var/cvsroot/gentoo-x86/media-libs/libmtp/libmtp-1.0.3-r1.ebuild,v 1.1 2010/07/25 22:02:45 ken69267 Exp $
+
+EAPI=2
+
+inherit eutils
+
+DESCRIPTION="An implementation of Microsoft's Media Transfer Protocol (MTP)."
+HOMEPAGE="http://libmtp.sourceforge.net"
+SRC_URI="mirror://sourceforge/${PN}/${P}.tar.gz"
+
+LICENSE="LGPL-2.1"
+SLOT="0"
+KEYWORDS="~amd64 ~hppa ~ppc ~ppc64 ~sparc ~x86"
+IUSE="doc examples static-libs"
+
+RDEPEND="virtual/libusb:0"
+DEPEND="${RDEPEND}
+ doc? ( app-doc/doxygen )
+ sys-apps/findutils"
+
+src_prepare() {
+ # Fix device permissions
+ epatch "${FILESDIR}"/permissions.patch
+}
+
+src_configure() {
+ econf \
+ --enable-shared \
+ $(use_enable static-libs static)
+}
+
+src_install() {
+ emake DESTDIR="${D}" install || die "emake install failed"
+
+ rm -f $(find "${D}" -name '*.la')
+ dodoc AUTHORS ChangeLog README TODO || die "dodoc failed"
+
+ insinto /etc/udev/rules.d
+ newins libmtp.rules 65-mtp.rules
+
+ insinto /usr/share/hal/fdi/information/20thirdparty
+ newins libmtp.fdi 10-libmtp.fdi
+
+ if use examples; then
+ docinto examples
+ dodoc examples/*.{c,h,sh}
+ fi
+}