/[gentoo-x86]/sci-mathematics/octave/octave-3.0.3.ebuild
Gentoo

Contents of /sci-mathematics/octave/octave-3.0.3.ebuild

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1.11 - (show annotations) (download)
Thu Jun 24 17:12:17 2010 UTC (4 years, 1 month ago) by bicatali
Branch: MAIN
CVS Tags: HEAD
Changes since 1.10: +1 -1 lines
FILE REMOVED
Cleaning old versions
(Portage version: 2.2_rc67/cvs/Linux x86_64)

1 # Copyright 1999-2009 Gentoo Foundation
2 # Distributed under the terms of the GNU General Public License v2
3 # $Header: /var/cvsroot/gentoo-x86/sci-mathematics/octave/octave-3.0.3.ebuild,v 1.10 2009/10/12 20:06:24 jer Exp $
4
5 inherit flag-o-matic fortran xemacs-elisp-common
6
7 DESCRIPTION="High-level interactive language for numerical computations"
8 LICENSE="GPL-3"
9 HOMEPAGE="http://www.octave.org/"
10 SRC_URI="ftp://ftp.gnu.org/pub/gnu/${PN}/${P}.tar.bz2"
11
12 SLOT="0"
13 IUSE="emacs readline zlib doc hdf5 curl fftw xemacs sparse"
14 KEYWORDS="alpha amd64 hppa ppc ~ppc64 sparc x86"
15
16 RDEPEND="virtual/lapack
17 dev-libs/libpcre
18 sys-libs/ncurses
19 sci-visualization/gnuplot
20 >=sci-mathematics/glpk-4.15
21 media-libs/qhull
22 fftw? ( >=sci-libs/fftw-3.1.2 )
23 zlib? ( sys-libs/zlib )
24 hdf5? ( sci-libs/hdf5 )
25 curl? ( net-misc/curl )
26 xemacs? ( app-editors/xemacs )
27 sparse? ( sci-libs/umfpack
28 sci-libs/colamd
29 sci-libs/camd
30 sci-libs/ccolamd
31 sci-libs/cholmod
32 sci-libs/cxsparse )
33 !sci-mathematics/octave-forge"
34
35 DEPEND="${RDEPEND}
36 virtual/latex-base
37 sys-apps/texinfo
38 || ( dev-texlive/texlive-genericrecommended
39 app-text/ptex )
40 dev-util/gperf
41 dev-util/pkgconfig"
42
43 FORTRAN="gfortran ifc g77 f2c"
44
45 src_unpack() {
46 unpack ${A}
47 cd "${S}"
48 epatch "${FILESDIR}"/${PN}-3.0.0-pkg.patch
49 epatch "${FILESDIR}"/${P}-test-fix.patch
50 epatch "${FILESDIR}"/${PN}-3.0.1-fix_handle_for_plotyy.patch
51 epatch "${FILESDIR}"/${PN}-3.0.1-no_helvetica.patch
52 }
53
54 src_compile() {
55 econf \
56 --localstatedir=/var/state/octave \
57 --enable-shared \
58 --with-blas="$(pkg-config --libs blas)" \
59 --with-lapack="$(pkg-config --libs lapack)" \
60 $(use_with hdf5) \
61 $(use_with curl) \
62 $(use_with zlib) \
63 $(use_with fftw) \
64 $(use_with sparse umfpack) \
65 $(use_with sparse colamd) \
66 $(use_with sparse ccolamd) \
67 $(use_with sparse cholmod) \
68 $(use_with sparse cxsparse) \
69 $(use_enable readline)
70
71 emake || die "emake failed"
72
73 if use xemacs; then
74 cd "${S}/emacs"
75 xemacs-elisp-comp *.el
76 fi
77 }
78
79 src_install() {
80 emake install DESTDIR="${D}" || die "emake install failed"
81
82 if use doc; then
83 einfo "Installing documentation..."
84 insinto /usr/share/doc/${PF}
85 doins $(find doc -name \*.pdf)
86 fi
87
88 if use emacs || use xemacs; then
89 cd emacs
90 exeinto /usr/bin
91 doexe octave-tags || die "Failed to install octave-tags"
92 doman octave-tags.1 || die "Failed to install octave-tags.1"
93 if use xemacs; then
94 xemacs-elisp-install ${PN} *.el *.elc
95 fi
96 cd ..
97 fi
98
99 echo "LDPATH=/usr/$(get_libdir)/octave-${PV}" > 99octave
100 doenvd 99octave || die
101
102 # Fixes ls-R files to remove /var/tmp/portage references.
103 sed -i \
104 -e "s:${D}::g" \
105 "${D}"/usr/*/${PN}/ls-R \
106 || die "Failed to fix ls-R files."
107 }

  ViewVC Help
Powered by ViewVC 1.1.20