/[gentoo-x86]/eclass/emboss.eclass
Gentoo

Contents of /eclass/emboss.eclass

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1.3 - (show annotations) (download)
Thu Sep 27 16:35:41 2012 UTC (23 months, 2 weeks ago) by axs
Branch: MAIN
CVS Tags: HEAD
Changes since 1.2: +3 -3 lines
naive bump of all EAPI-specific checks in eclasses to permit EAPI=5 where EAPI=4 was previously allowed

1 # Copyright 1999-2012 Gentoo Foundation
2 # Distributed under the terms of the GNU General Public License v2
3 # $Header: /var/cvsroot/gentoo-x86/eclass/emboss.eclass,v 1.2 2011/08/22 04:46:31 vapier Exp $
4
5 # @ECLASS: emboss.eclass
6 # @MAINTAINER:
7 # sci-biology@gentoo.org
8 # jlec@gentoo.org
9 # @AUTHOR:
10 # Original author: Author Olivier Fisette <ofisette@gmail.com>
11 # Next gen author: Justin Lecher <jlec@gentoo.org>
12 # @BLURB: Use this to easy install EMBOSS and EMBASSY programs (EMBOSS add-ons).
13 # @DESCRIPTION:
14 # The inheriting ebuild must set EAPI=4 and provide EBO_DESCRIPTION before the inherit line.
15 # KEYWORDS should be set. Additionally "(R|P)DEPEND"encies and other standard
16 # ebuild variables can be extended (FOO+=" bar").
17 # Default installation of following DOCS="AUTHORS ChangeLog NEWS README"
18 #
19 # Example:
20 #
21 # EAPI="4"
22 #
23 # EBO_DESCRIPTION="applications from the CBS group"
24 #
25 # inherit emboss
26
27 # @ECLASS-VARIABLE: EBO_DESCRIPTION
28 # @DESCRIPTION:
29 # Should be set. Completes the generic description of the embassy module as follows:
30 #
31 # EMBOSS integrated version of ${EBO_DESCRIPTION},
32 # e.g.
33 # "EMBOSS integrated version of applications from the CBS group"
34 #
35 # Defaults to the upstream name of the module.
36
37 # @ECLASS-VARIABLE: EBO_EAUTORECONF
38 # @DESCRIPTION:
39 # Set to 'no', if you don't want eautoreconf to be run after patching.
40 : ${EBO_EAUTORECONF:=yes}
41
42 # @ECLASS-VARIABLE: EBO_EXTRA_ECONF
43 # @DEFAULT_UNSET
44 # @DESCRIPTION:
45 # Extra config options passed to econf, similar to EXTRA_ECONF.
46
47 case ${EAPI:-0} in
48 4|5) ;;
49 *) die "this eclass doesn't support < EAPI 4" ;;
50 esac
51
52 inherit autotools eutils
53
54 HOMEPAGE="http://emboss.sourceforge.net/"
55 LICENSE="LGPL-2 GPL-2"
56
57 SLOT="0"
58 IUSE="mysql pdf png postgres static-libs X"
59
60 DEPEND="
61 dev-libs/expat
62 dev-libs/libpcre:3
63 sci-libs/plplot
64 sys-libs/zlib
65 mysql? ( dev-db/mysql )
66 pdf? ( media-libs/libharu )
67 png? ( media-libs/gd[png] )
68 postgres? ( dev-db/postgresql-base )
69 X? ( x11-libs/libXt )"
70 RDEPEND="${DEPEND}"
71
72 if [[ ${PN} == embassy-* ]]; then
73 # The EMBASSY package name, retrieved from the inheriting ebuild's name
74 EN=${PN:8}
75 # The full name and version of the EMBASSY package (excluding the Gentoo
76 # revision number)
77 EF=$(echo ${EN} | tr "[:lower:]" "[:upper:]")-${PV}
78 : ${EBO_DESCRIPTION:=${EN}}
79 DESCRIPTION="EMBOSS integrated version of ${EBO_DESCRIPTION}"
80 SRC_URI="ftp://emboss.open-bio.org/pub/EMBOSS/${EF}.tar.gz -> embassy-${EN}-${PV}.tar.gz"
81 DEPEND+=" >=sci-biology/emboss-6.3.1_p4[mysql=,pdf=,png=,postgres=,static-libs=,X=]"
82
83 S="${WORKDIR}"/${EF}
84 fi
85
86 DOCS="AUTHORS ChangeLog NEWS README"
87
88 # @FUNCTION: emboss_src_prepare
89 # @DESCRIPTION:
90 # Does following things
91 #
92 # 1. Patches with "${FILESDIR}"/${PF}.patch, if present
93 # 2. Runs eautoreconf, unless EBO_EAUTORECONF is set to no
94 #
95
96 emboss_src_prepare() {
97 [[ -f ${FILESDIR}/${PF}.patch ]] && epatch "${FILESDIR}"/${PF}.patch
98 [[ ${EBO_EAUTORECONF} == yes ]] && eautoreconf
99 }
100
101 # @FUNCTION: emboss_src_configure
102 # @DESCRIPTION:
103 # runs econf with following options.
104 #
105 # $(use_with X x)
106 # $(use_with png pngdriver)
107 # $(use_with pdf hpdf)
108 # $(use_with mysql mysql)
109 # $(use_with postgres postgresql)
110 # $(use_enable static-libs static)
111 # --enable-large
112 # --without-java
113 # --enable-systemlibs
114 # --docdir="${EPREFIX}/usr/share/doc/${PF}"
115 # ${EBO_EXTRA_ECONF}
116
117 emboss_src_configure() {
118 econf \
119 $(use_with X x) \
120 $(use_with png pngdriver) \
121 $(use_with pdf hpdf) \
122 $(use_with mysql mysql) \
123 $(use_with postgres postgresql) \
124 $(use_enable static-libs static) \
125 --enable-large \
126 --without-java \
127 --enable-systemlibs \
128 --docdir="${EPREFIX}/usr/share/doc/${PF}" \
129 ${EBO_EXTRA_ECONF}
130 }
131
132 EXPORT_FUNCTIONS src_prepare src_configure

  ViewVC Help
Powered by ViewVC 1.1.20