/[gentoo-x86]/sci-mathematics/dataplot/dataplot-20090821.ebuild
Gentoo

Contents of /sci-mathematics/dataplot/dataplot-20090821.ebuild

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1.5 - (hide annotations) (download)
Thu Aug 9 18:26:47 2012 UTC (3 years ago) by bicatali
Branch: MAIN
Changes since 1.4: +8 -8 lines
keyword amd64-linux x86-linux

(Portage version: 2.2.01.20796-prefix/cvs/Linux x86_64)

1 jdhore 1.4 # Copyright 1999-2012 Gentoo Foundation
2 bicatali 1.1 # Distributed under the terms of the GNU General Public License v2
3 bicatali 1.5 # $Header: /var/cvsroot/gentoo-x86/sci-mathematics/dataplot/dataplot-20090821.ebuild,v 1.4 2012/05/04 07:46:51 jdhore Exp $
4 bicatali 1.1
5 bicatali 1.5 EAPI=4
6 jlec 1.2
7     inherit eutils fortran-2 toolchain-funcs autotools
8 bicatali 1.1
9     # YEAR MONTH DAY
10     MY_PV=${PV:0:4}_${PV:4:2}_${PV:6:2}
11     MY_P=dpsrc_${MY_PV}
12     # MY_PV_AUX usually ${MY_PV}
13     MY_PV_AUX=2009_07_15
14     MY_P_AUX=dplib.${MY_PV_AUX}
15    
16 bicatali 1.5 DESCRIPTION="Program for scientific visualization and statistical analyis"
17 bicatali 1.1 HOMEPAGE="http://www.itl.nist.gov/div898/software/dataplot/"
18 jlec 1.2 SRC_URI="
19     ftp://ftp.nist.gov/pub/dataplot/unix/${MY_P}.tar.gz
20 bicatali 1.1 ftp://ftp.nist.gov/pub/dataplot/unix/${MY_P_AUX}.tar.gz"
21    
22 jlec 1.2 SLOT="0"
23 bicatali 1.1 LICENSE="public-domain"
24 bicatali 1.5 KEYWORDS="~amd64 ~x86 ~amd64-linux ~x86-linux"
25 bicatali 1.1 IUSE="examples gd opengl X"
26    
27 jlec 1.2 COMMON_DEPEND="
28     media-libs/plotutils
29 bicatali 1.1 opengl? ( virtual/opengl )
30     gd? ( media-libs/gd[png,jpeg] )"
31     DEPEND="${COMMON_DEPEND}
32 jdhore 1.4 virtual/pkgconfig"
33 jlec 1.3 RDEPEND="
34     virtual/fortran
35     ${COMMON_DEPEND}
36 bicatali 1.1 X? ( x11-misc/xdg-utils )"
37    
38     S="${WORKDIR}/${MY_P}"
39     S_AUX="${WORKDIR}/${MY_P_AUX}"
40    
41     src_unpack() {
42     # unpacking and renaming because
43     # upstream does not use directories
44     mkdir "${S_AUX}"
45 jlec 1.2 pushd "${S_AUX}" > /dev/null
46 bicatali 1.1 unpack ${MY_P_AUX}.tar.gz
47 jlec 1.2 popd > /dev/null
48 bicatali 1.1 mkdir ${MY_P}
49     cd "${S}"
50     unpack ${MY_P}.tar.gz
51     }
52    
53     src_prepare() {
54     epatch "${FILESDIR}"/${P}-opengl.patch
55     cp "${FILESDIR}"/Makefile.am.${PV} Makefile.am
56     cp "${FILESDIR}"/configure.ac.${PV} configure.ac
57     sed -e "s:IHOST1='SUN':IHOST1='@HOST@:" \
58     -e "s:/usr/local/lib:@datadir@:g" \
59     dp1_linux.f > dp1_linux.f.in || die
60     sed -e "s/(MAXOBV=.*)/(MAXOBV=@MAXOBV@)/" \
61     -e "s:/usr/local/lib:@datadir@:g" \
62     DPCOPA.INC > DPCOPA.INC.in || die
63     eautoreconf
64     }
65    
66     src_configure() {
67     econf \
68     $(use_enable gd) \
69     $(use_enable opengl gl) \
70     $(use_enable X)
71     }
72    
73     src_install() {
74 bicatali 1.5 emake DESTDIR="${D}" install
75 bicatali 1.1
76     if use examples; then
77     insinto /usr/share/doc/${PF}/examples
78 bicatali 1.5 doins -r "${S_AUX}"/data/*
79 bicatali 1.1 fi
80     insinto /usr/share/dataplot
81 bicatali 1.5 doins "${S_AUX}"/dp{mes,sys,log}f.tex
82     doenvd "${FILESDIR}"/90${PN}
83 bicatali 1.1 }
84    
85     pkg_postinst() {
86     elog "Before using dataplot, please run (as root):"
87     elog "env-update && source /etc/profile"
88     }

  ViewVC Help
Powered by ViewVC 1.1.20