diff options
author | Jonathan Callen <abcd@gentoo.org> | 2009-09-11 05:58:13 +0000 |
---|---|---|
committer | Jonathan Callen <abcd@gentoo.org> | 2009-09-11 05:58:13 +0000 |
commit | 012c41f6aa50267d8b41a8ee3cf2125650b993cf (patch) | |
tree | d75922a317737dd313e9b9fc6fe8791b410e50b7 /dev-libs/lockdev | |
parent | Version bump. (diff) | |
download | gentoo-2-012c41f6aa50267d8b41a8ee3cf2125650b993cf.tar.gz gentoo-2-012c41f6aa50267d8b41a8ee3cf2125650b993cf.tar.bz2 gentoo-2-012c41f6aa50267d8b41a8ee3cf2125650b993cf.zip |
New ebuild. Thanks to Nick Fortino <nfortino@gmail.com> for initial autotools patch (bug #257333).
(Portage version: -svn/cvs/Linux i686)
Diffstat (limited to 'dev-libs/lockdev')
-rw-r--r-- | dev-libs/lockdev/ChangeLog | 12 | ||||
-rw-r--r-- | dev-libs/lockdev/files/lockdev-1.0.3-add-autotools.patch | 55 | ||||
-rw-r--r-- | dev-libs/lockdev/files/lockdev-1.0.3-fix-perl.patch | 11 | ||||
-rw-r--r-- | dev-libs/lockdev/lockdev-1.0.3.1.2.ebuild | 99 | ||||
-rw-r--r-- | dev-libs/lockdev/metadata.xml | 9 |
5 files changed, 186 insertions, 0 deletions
diff --git a/dev-libs/lockdev/ChangeLog b/dev-libs/lockdev/ChangeLog new file mode 100644 index 000000000000..858fd010df1c --- /dev/null +++ b/dev-libs/lockdev/ChangeLog @@ -0,0 +1,12 @@ +# ChangeLog for dev-libs/lockdev +# Copyright 1999-2009 Gentoo Foundation; Distributed under the GPL v2 +# $Header: /var/cvsroot/gentoo-x86/dev-libs/lockdev/ChangeLog,v 1.1 2009/09/11 05:58:12 abcd Exp $ + +*lockdev-1.0.3.1.2 (11 Sep 2009) + + 11 Sep 2009; Jonathan Callen <abcd@gentoo.org> +lockdev-1.0.3.1.2.ebuild, + +files/lockdev-1.0.3-add-autotools.patch, + +files/lockdev-1.0.3-fix-perl.patch, +metadata.xml: + New ebuild, required for schroot. Thanks to Nick Fortino + <nfortino@gmail.com> for initial autotools patch (bug #257333). + diff --git a/dev-libs/lockdev/files/lockdev-1.0.3-add-autotools.patch b/dev-libs/lockdev/files/lockdev-1.0.3-add-autotools.patch new file mode 100644 index 000000000000..0c223b35cb8b --- /dev/null +++ b/dev-libs/lockdev/files/lockdev-1.0.3-add-autotools.patch @@ -0,0 +1,55 @@ +Adds an autotools build system to fix the many issues with the custom build +system (ignoring CC, CFLAGS, DESTDIR, not installing the .so file properly). + +Contributed by Nick Fortino (nfortino@gmail.com) 2/1/2009 + +Updated by Jonathan Callen <abcd@gentoo.org> 2009-09-11 + +--- Makefile.am ++++ Makefile.am +@@ -0,0 +1,20 @@ ++include_HEADERS = src/lockdev.h src/ttylock.h ++ ++lib_LTLIBRARIES = liblockdev.la ++liblockdev_la_SOURCES = src/lockdev.c ++liblockdev_version = -version-info $(LOCKDEV_CURRENT_INTERFACE):$(LOCKDEV_INTERFACE_AGE):$(LOCKDEV_BINARY_AGE) ++liblockdev_la_LDFLAGS = $(liblockdev_version) ++ ++man_MANS = docs/lockdev.3 ++ ++manpage_links = \ ++ dev_lock.3 \ ++ dev_unlock.3 \ ++ dev_relock.3 \ ++ dev_testlock.3 \ ++ liblockdev.3 ++ ++install-data-hook: ++ for page in $(manpage_links); do \ ++ $(LN_S) lockdev.3 $(DESTDIR)$(man3dir)/$${page} ; \ ++ done +--- configure.ac ++++ configure.ac +@@ -0,0 +1,22 @@ ++AC_INIT([lockdev], [1.0.3], [BUG-REPORT-ADDRESS]) ++AC_CONFIG_AUX_DIR([scripts]) ++AM_INIT_AUTOMAKE ++ ++LOCKDEV_CURRENT_INTERFACE=1 ++LOCKDEV_INTERFACE_AGE=0 ++LOCKDEV_BINARY_AGE=0 ++ ++AC_SUBST([LOCKDEV_CURRENT_INTERFACE]) ++AC_SUBST([LOCKDEV_INTERFACE_AGE]) ++AC_SUBST([LOCKDEV_BINARY_AGE]) ++ ++LT_INIT([disable-static]) ++ ++AC_CANONICAL_BUILD ++AC_CANONICAL_HOST ++ ++# Checks for programs. ++AC_PROG_LN_S ++ ++AC_CONFIG_FILES([Makefile]) ++AC_OUTPUT diff --git a/dev-libs/lockdev/files/lockdev-1.0.3-fix-perl.patch b/dev-libs/lockdev/files/lockdev-1.0.3-fix-perl.patch new file mode 100644 index 000000000000..7b25f82e7e48 --- /dev/null +++ b/dev-libs/lockdev/files/lockdev-1.0.3-fix-perl.patch @@ -0,0 +1,11 @@ +--- lockdev-1.0.3.orig/LockDev/Makefile.PL ++++ lockdev-1.0.3/LockDev/Makefile.PL +@@ -7,7 +7,7 @@ WriteMakefile( + 'LIBS' => [''], + 'DEFINE' => '', + 'INC' => '-I../src', +- 'MYEXTLIB' => '../src/lockdev.z', ++ 'MYEXTLIB' => '../.libs/liblockdev.so', + ); + + sub MY::postamble { diff --git a/dev-libs/lockdev/lockdev-1.0.3.1.2.ebuild b/dev-libs/lockdev/lockdev-1.0.3.1.2.ebuild new file mode 100644 index 000000000000..5349e5c1b9b1 --- /dev/null +++ b/dev-libs/lockdev/lockdev-1.0.3.1.2.ebuild @@ -0,0 +1,99 @@ +# Copyright 1999-2009 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Header: /var/cvsroot/gentoo-x86/dev-libs/lockdev/lockdev-1.0.3.1.2.ebuild,v 1.1 2009/09/11 05:58:12 abcd Exp $ + +EAPI="2" + +GENTOO_DEPEND_ON_PERL="no" +inherit toolchain-funcs base perl-module eutils versionator autotools + +MAJOR=$(get_major_version) +MY_PV=$(get_version_component_range 1-3) +MY_P=${PN}-${MY_PV} +DEB_PV=$(replace_version_separator 3 '-') +DEB_P=${PN}_${DEB_PV} + +DESCRIPTION="Library for locking devices" +HOMEPAGE="http://packages.debian.org/source/sid/lockdev" +SRC_URI=" + mirror://debian/pool/main/${PN:0:1}/${PN}/${PN}_${MY_PV}.orig.tar.gz + mirror://debian/pool/main/${PN:0:1}/${PN}/${DEB_P}.diff.gz +" + +LICENSE="LGPL-2.1" +SLOT="0" +KEYWORDS="~x86" +IUSE="perl" + +DEPEND=" + perl? ( dev-lang/perl[-build] ) +" +RDEPEND="${DEPEND}" + +PATCHES=( + "${FILESDIR}/${MY_P}-add-autotools.patch" + "${FILESDIR}/${MY_P}-fix-perl.patch" +) + +S=${WORKDIR}/${PN}-${MY_PV} +PERL_S=${S}/LockDev + +pkg_setup() { + use perl && perl-module_pkg_setup +} + +src_prepare() { + cd "${WORKDIR}" + # Note: we do *not* want to be in ${S} for this, as that breaks the patch + epatch "${WORKDIR}/${DEB_P}.diff" + + cd "${S}" + base_src_prepare + + eautoreconf +} + +src_configure() { + econf + + if use perl; then + cd "${PERL_S}" + perl-module_src_configure + fi +} + +src_compile() { + emake || die "emake failed" + + if use perl; then + cd "${PERL_S}" + perl-module_src_compile + fi +} + +src_test() { + if use perl; then + cd "${PERL_S}" + SRC_TEST="do" + export LD_LIBRARY_PATH="${LD_LIBRARY_PATH:+${LD_LIBRARY_PATH}:}${S}/.libs" + perl-module_src_test + fi +} + +src_install() { + emake DESTDIR="${D}" install || die "make install failed" + + dodoc AUTHORS ChangeLog* debian/NEWS README.debug || die "dodoc failed" + newdoc debian/changelog changelog.debian || die "newdoc changelog.debian failed" + + if use perl; then + cd "${PERL_S}" + mytargets="pure_install" + docinto perl + perl-module_src_install + fi +} + +pkg_preinst() { + use perl && perl-module_pkg_preinst +} diff --git a/dev-libs/lockdev/metadata.xml b/dev-libs/lockdev/metadata.xml new file mode 100644 index 000000000000..564ef9db9aa9 --- /dev/null +++ b/dev-libs/lockdev/metadata.xml @@ -0,0 +1,9 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd"> +<pkgmetadata> +<herd>no-herd</herd> +<maintainer> + <email>abcd@gentoo.org</email> + <name>Jonathan Callen</name> +</maintainer> +</pkgmetadata> |