diff options
author | Michael Weber <xmw@gentoo.org> | 2013-06-08 10:36:47 +0000 |
---|---|---|
committer | Michael Weber <xmw@gentoo.org> | 2013-06-08 10:36:47 +0000 |
commit | 8e0bbf251a5b2f9640a6f06fb9efbf7418f5c67c (patch) | |
tree | 58f7f1a15d80674b3c1b0c3a2042e415594c7b8c /media-libs | |
parent | Revison bump. Add test USE flag. (diff) | |
download | gentoo-2-8e0bbf251a5b2f9640a6f06fb9efbf7418f5c67c.tar.gz gentoo-2-8e0bbf251a5b2f9640a6f06fb9efbf7418f5c67c.tar.bz2 gentoo-2-8e0bbf251a5b2f9640a6f06fb9efbf7418f5c67c.zip |
Add static-libs, fix pkg-config for static.
(Portage version: 2.2.0_alpha177/cvs/Linux x86_64, signed Manifest commit with key 62EEF090)
Diffstat (limited to 'media-libs')
-rw-r--r-- | media-libs/openjpeg/files/openjpeg-2.0.0-pkgconfig-static.patch | 10 | ||||
-rw-r--r-- | media-libs/openjpeg/openjpeg-1.5.1.ebuild | 6 | ||||
-rw-r--r-- | media-libs/openjpeg/openjpeg-2.0.0.ebuild | 41 | ||||
-rw-r--r-- | media-libs/openjpeg/openjpeg-9999.ebuild | 42 |
4 files changed, 82 insertions, 17 deletions
diff --git a/media-libs/openjpeg/files/openjpeg-2.0.0-pkgconfig-static.patch b/media-libs/openjpeg/files/openjpeg-2.0.0-pkgconfig-static.patch new file mode 100644 index 000000000000..60a5a47adbda --- /dev/null +++ b/media-libs/openjpeg/files/openjpeg-2.0.0-pkgconfig-static.patch @@ -0,0 +1,10 @@ +Upstream issue 223, http://code.google.com/p/openjpeg/issues/detail?id=223 + +--- openjpeg-2.0.0/src/lib/openjp2/libopenjp2.pc.cmake.in ++++ openjpeg-2.0.0/src/lib/openjp2/libopenjp2.pc.cmake.in +@@ -10,4 +10,5 @@ + URL: http://www.openjpeg.org/ + Version: @OPENJPEG_VERSION@ + Libs: -L${libdir} -lopenjp2 ++Libs.private: -L${libdir} -lopenjp2 -lm + Cflags: -I${includedir} diff --git a/media-libs/openjpeg/openjpeg-1.5.1.ebuild b/media-libs/openjpeg/openjpeg-1.5.1.ebuild index cc9f16c71c89..d43827e44039 100644 --- a/media-libs/openjpeg/openjpeg-1.5.1.ebuild +++ b/media-libs/openjpeg/openjpeg-1.5.1.ebuild @@ -1,9 +1,9 @@ # Copyright 1999-2013 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 -# $Header: /var/cvsroot/gentoo-x86/media-libs/openjpeg/openjpeg-1.5.1.ebuild,v 1.2 2013/06/08 00:20:19 xmw Exp $ +# $Header: /var/cvsroot/gentoo-x86/media-libs/openjpeg/openjpeg-1.5.1.ebuild,v 1.3 2013/06/08 10:36:47 xmw Exp $ EAPI=5 -inherit cmake-utils multilib toolchain-funcs +inherit cmake-utils multilib DESCRIPTION="An open-source JPEG 2000 library" HOMEPAGE="http://code.google.com/p/openjpeg/" @@ -12,7 +12,7 @@ SRC_URI="http://${PN}.googlecode.com/files/${P}.tar.gz" LICENSE="BSD-2" SLOT="0" KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~amd64-fbsd ~sparc-fbsd ~x86-fbsd ~x64-freebsd ~x86-freebsd ~x86-interix ~amd64-linux ~arm-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos ~sparc-solaris ~x64-solaris ~x86-solaris" -IUSE="doc test static-libs" +IUSE="doc static-libs test" RDEPEND="media-libs/lcms:2=[static-libs?] media-libs/libpng:0=[static-libs?] diff --git a/media-libs/openjpeg/openjpeg-2.0.0.ebuild b/media-libs/openjpeg/openjpeg-2.0.0.ebuild index 21b442e49049..624b3b161bf3 100644 --- a/media-libs/openjpeg/openjpeg-2.0.0.ebuild +++ b/media-libs/openjpeg/openjpeg-2.0.0.ebuild @@ -1,6 +1,6 @@ # Copyright 1999-2013 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 -# $Header: /var/cvsroot/gentoo-x86/media-libs/openjpeg/openjpeg-2.0.0.ebuild,v 1.2 2013/06/06 13:54:04 xmw Exp $ +# $Header: /var/cvsroot/gentoo-x86/media-libs/openjpeg/openjpeg-2.0.0.ebuild,v 1.3 2013/06/08 10:36:47 xmw Exp $ EAPI=5 inherit cmake-utils multilib @@ -12,19 +12,20 @@ SRC_URI="http://${PN}.googlecode.com/files/${P}.tar.gz" LICENSE="BSD-2" SLOT="2" KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~amd64-fbsd ~sparc-fbsd ~x86-fbsd ~x64-freebsd ~x86-freebsd ~x86-interix ~amd64-linux ~arm-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos ~sparc-solaris ~x64-solaris ~x86-solaris" -IUSE="doc test" +IUSE="doc static-libs test" -RDEPEND="media-libs/lcms:2= - media-libs/libpng:0= - media-libs/tiff:0= - sys-libs/zlib:=" +RDEPEND="media-libs/lcms:2=[static-libs?] + media-libs/libpng:0=[static-libs?] + media-libs/tiff:0=[static-libs?] + sys-libs/zlib:=[static-libs?]" DEPEND="${RDEPEND} doc? ( app-doc/doxygen )" DOCS=( AUTHORS CHANGES NEWS README THANKS ) PATCHES=( "${FILESDIR}"/${P}-build.patch - "${FILESDIR}"/${P}-pkgconfig.patch ) + "${FILESDIR}"/${P}-pkgconfig.patch + "${FILESDIR}"/${P}-pkgconfig-static.patch ) RESTRICT="test" #409263 @@ -36,4 +37,30 @@ src_configure() { ) cmake-utils_src_configure + + if use static-libs ; then + mycmakeargs=( + -DOPENJPEG_INSTALL_LIB_DIR="$(get_libdir)" + $(cmake-utils_use_build test TESTING) + -DBUILD_SHARED_LIBS=OFF + ) + BUILD_DIR=${BUILD_DIR}_static cmake-utils_src_configure + fi +} + +src_compile() { + cmake-utils_src_compile + + if use static-libs ; then + BUILD_DIR=${BUILD_DIR}_static cmake-utils_src_compile + fi +} + +src_install() { + if use static-libs ; then + BUILD_DIR=${BUILD_DIR}_static cmake-utils_src_install + #static bins overwritten by shared install + fi + + cmake-utils_src_install } diff --git a/media-libs/openjpeg/openjpeg-9999.ebuild b/media-libs/openjpeg/openjpeg-9999.ebuild index 28d56e890bea..9180265d2dd9 100644 --- a/media-libs/openjpeg/openjpeg-9999.ebuild +++ b/media-libs/openjpeg/openjpeg-9999.ebuild @@ -1,6 +1,6 @@ # Copyright 1999-2013 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 -# $Header: /var/cvsroot/gentoo-x86/media-libs/openjpeg/openjpeg-9999.ebuild,v 1.2 2013/06/06 22:19:04 xmw Exp $ +# $Header: /var/cvsroot/gentoo-x86/media-libs/openjpeg/openjpeg-9999.ebuild,v 1.3 2013/06/08 10:36:47 xmw Exp $ EAPI=5 inherit cmake-utils eutils multilib subversion @@ -12,12 +12,12 @@ ESVN_REPO_URI="http://openjpeg.googlecode.com/svn/trunk/" LICENSE="BSD-2" SLOT="2" KEYWORDS="" -IUSE="doc test +vanilla" +IUSE="doc static-libs test +vanilla" -RDEPEND="media-libs/lcms:2= - media-libs/libpng:0= - media-libs/tiff:0= - sys-libs/zlib:=" +RDEPEND="media-libs/lcms:2=[static-libs?] + media-libs/libpng:0=[static-libs?] + media-libs/tiff:0=[static-libs?] + sys-libs/zlib:=[static-libs?]" DEPEND="${RDEPEND} doc? ( app-doc/doxygen )" @@ -26,7 +26,9 @@ DOCS=( AUTHORS NEWS README THANKS ) RESTRICT="test" #409263 src_prepare() { - epatch "${FILESDIR}"/${P}-build.patch + epatch \ + "${FILESDIR}"/${P}-build.patch \ + "${FILESDIR}"/${PN}-2.0.0-pkgconfig-static.patch if ! use vanilla ; then epatch "${FILESDIR}"/${P}-mupdf.patch fi @@ -40,4 +42,30 @@ src_configure() { ) cmake-utils_src_configure + + if use static-libs ; then + mycmakeargs=( + -DOPENJPEG_INSTALL_LIB_DIR="$(get_libdir)" + $(cmake-utils_use_build test TESTING) + -DBUILD_SHARED_LIBS=OFF + ) + BUILD_DIR=${BUILD_DIR}_static cmake-utils_src_configure + fi +} + +src_compile() { + cmake-utils_src_compile + + if use static-libs ; then + BUILD_DIR=${BUILD_DIR}_static cmake-utils_src_compile + fi +} + +src_install() { + if use static-libs ; then + BUILD_DIR=${BUILD_DIR}_static cmake-utils_src_install + #static bins overwritten by shared install + fi + + cmake-utils_src_install } |