/[gentoo-x86]/sci-libs/udunits/udunits-1.12.1.ebuild
Gentoo

Contents of /sci-libs/udunits/udunits-1.12.1.ebuild

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1.3 - (show annotations) (download)
Wed Dec 1 16:48:33 2010 UTC (9 years, 11 months ago) by bicatali
Branch: MAIN
CVS Tags: HEAD
Changes since 1.2: +1 -1 lines
FILE REMOVED
Removed old

(Portage version: 2.1.9.25/cvs/Linux x86_64)

1 # Copyright 1999-2005 Gentoo Foundation
2 # Distributed under the terms of the GNU General Public License v2
3 # $Header: /var/cvsroot/gentoo-x86/sci-libs/udunits/udunits-1.12.1.ebuild,v 1.2 2005/11/28 12:04:37 mcummings Exp $
4
5 inherit eutils flag-o-matic
6
7 IUSE=""
8
9 S=${WORKDIR}/${P}/src
10 SP=${WORKDIR}/${P}/src/perl
11 DESCRIPTION="The UCAR/Unidata Units library"
12 HOMEPAGE="http://www.unidata.ucar.edu/packages/udunits/"
13 SRC_URI="ftp://unidata.ucar.edu/pub/udunits/udunits-${PV}.tar.Z"
14
15 SLOT="0"
16 LICENSE="UCAR-Unidata"
17 KEYWORDS="x86 ~amd64 ~ppc ~sparc alpha ~mips ~hppa"
18
19 DEPEND="dev-lang/perl
20 sys-apps/sed"
21
22 RDEPEND="dev-lang/perl"
23
24 src_unpack() {
25 unpack ${A}
26 cd ${S}
27 epatch ${FILESDIR}/udunits_customize.patch || die "epatch failed"
28 }
29
30 src_compile() {
31 export CPPFLAGS="-Df2cFortran -D_POSIX_SOURCE"
32 append-flags -fPIC
33 econf || die "econf failed"
34
35 cd lib
36 emake || die
37 cd ..
38
39 cd perl
40 perl Makefile.PL PREFIX=${D}/usr
41 cd ..
42
43 emake || die
44 emake test || die
45 }
46
47 src_install() {
48 sed "s?/usr?${D}/usr?" Makefile > Makefile.install
49 emake -f Makefile.install install
50
51 dodir /etc /usr/share/man/man3 /usr/share/man/man3f
52
53 insinto /etc
54 insopts -m 644
55 doins lib/udunits.dat
56
57 insinto /usr/share/man/man3
58 doins lib/udunits.3
59 insinto /usr/share/man/man3f
60 doins lib/udunits.3f
61
62 cd perl
63 make PREFIX=${D}/usr install INSTALLSITEMAN1DIR=${D}/usr/share/man/man1
64 cd ..
65
66 find ${D} -type f -a \( -name perllocal.pod -o -name .packlist \
67 -o \( -name '*.bs' -a -empty \) \) -exec rm -f {} ';'
68 find ${D} -type d -depth -exec rmdir {} 2>/dev/null ';'
69
70 chmod -R u+w ${D}/*
71
72 dodoc COPYRIGHT README RELEASE_NOTES VERSION CUSTOMIZE INSTALL
73 }
74
75 pkg_postinst() {
76 ewarn "This package requires a Fortran compiler for maximum utility."
77 ewarn "For now, make sure you have at least g77 for the f77 interface."
78 ewarn "The internal configure should detect many f77 compilers, however,"
79 ewarn "if you have the PG compiler you will need to change the above"
80 ewarn "preprocessor macro to something like -Dpgifortran."
81 }

  ViewVC Help
Powered by ViewVC 1.1.20