/[gentoo-x86]/media-libs/lcms/lcms-1.19.ebuild
Gentoo

Diff of /media-libs/lcms/lcms-1.19.ebuild

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

Revision 1.9 Revision 1.10
1# Copyright 1999-2010 Gentoo Foundation 1# Copyright 1999-2011 Gentoo Foundation
2# Distributed under the terms of the GNU General Public License v2 2# Distributed under the terms of the GNU General Public License v2
3# $Header: /var/cvsroot/gentoo-x86/media-libs/lcms/Attic/lcms-1.19.ebuild,v 1.9 2010/09/28 16:19:42 ssuominen Exp $ 3# $Header: /var/cvsroot/gentoo-x86/media-libs/lcms/Attic/lcms-1.19.ebuild,v 1.10 2011/02/26 18:18:37 arfrever Exp $
4 4
5EAPI=2 5EAPI="3"
6inherit libtool multilib 6PYTHON_DEPEND="python? 2"
7SUPPORT_PYTHON_ABIS="1"
8RESTRICT_PYTHON_ABIS="3.* *-jython"
9
10inherit autotools eutils multilib python
7 11
8DESCRIPTION="A lightweight, speed optimized color management engine" 12DESCRIPTION="A lightweight, speed optimized color management engine"
9HOMEPAGE="http://www.littlecms.com/" 13HOMEPAGE="http://www.littlecms.com/"
10SRC_URI="http://www.littlecms.com/${P}.tar.gz" 14SRC_URI="http://www.littlecms.com/${P}.tar.gz"
11 15
18 jpeg? ( virtual/jpeg ) 22 jpeg? ( virtual/jpeg )
19 zlib? ( sys-libs/zlib )" 23 zlib? ( sys-libs/zlib )"
20DEPEND="${RDEPEND} 24DEPEND="${RDEPEND}
21 python? ( >=dev-lang/swig-1.3.31 )" 25 python? ( >=dev-lang/swig-1.3.31 )"
22 26
27pkg_setup() {
28 if use python; then
29 python_pkg_setup
30 fi
31}
32
23src_prepare() { 33src_prepare() {
34 # Python bindings are built/installed manually.
35 sed -e "/SUBDIRS =/s/ python//" -i Makefile.am
36
37 epatch "${FILESDIR}/${P}-disable_static_modules.patch"
38
39 eautoreconf
40
24 # run swig to regenerate lcms_wrap.cxx and lcms.py (bug #148728) 41 # run swig to regenerate lcms_wrap.cxx and lcms.py (bug #148728)
25 if use python; then 42 if use python; then
26 cd python 43 cd python
27 ./swig_lcms || die 44 ./swig_lcms || die
28 fi 45 fi
36 $(use_with python) \ 53 $(use_with python) \
37 $(use_with tiff) \ 54 $(use_with tiff) \
38 $(use_with zlib) 55 $(use_with zlib)
39} 56}
40 57
58src_compile() {
59 default
60
61 if use python; then
62 python_copy_sources python
63
64 building() {
65 emake \
66 LCMS_PYEXECDIR="$(python_get_sitedir)" \
67 LCMS_PYINCLUDE="$(python_get_includedir)" \
68 LCMS_PYLIB="$(python_get_libdir)" \
69 PYTHON_VERSION="$(python_get_version)"
70 }
71 python_execute_function -s --source-dir python building
72 fi
73}
74
41src_install() { 75src_install() {
42 emake \ 76 emake \
43 DESTDIR="${D}" \ 77 DESTDIR="${D}" \
44 BINDIR="${D}"/usr/bin \ 78 BINDIR="${D}"/usr/bin \
45 libdir=/usr/$(get_libdir) \ 79 libdir=/usr/$(get_libdir) \
46 install || die 80 install || die
81
82 if use python; then
83 installation() {
84 emake \
85 DESTDIR="${D}" \
86 LCMS_PYEXECDIR="$(python_get_sitedir)" \
87 LCMS_PYLIB="$(python_get_libdir)" \
88 PYTHON_VERSION="$(python_get_version)" \
89 install
90 }
91 python_execute_function -s --source-dir python installation
92
93 python_clean_installation_image
94 fi
47 95
48 insinto /usr/share/lcms/profiles 96 insinto /usr/share/lcms/profiles
49 doins testbed/*.icm 97 doins testbed/*.icm
50 98
51 dodoc AUTHORS README* INSTALL NEWS doc/* 99 dodoc AUTHORS README* INSTALL NEWS doc/*
52 100
53 find "${D}" -name '*.la' -exec rm -f '{}' + 101 find "${D}" -name '*.la' -exec rm -f '{}' +
54} 102}
103
104pkg_postinst() {
105 if use python; then
106 python_mod_optimize lcms.py
107 fi
108}
109
110pkg_postrm() {
111 if use python; then
112 python_mod_cleanup lcms.py
113 fi
114}

Legend:
Removed from v.1.9  
changed lines
  Added in v.1.10

  ViewVC Help
Powered by ViewVC 1.1.20