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

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

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1.4 - (show annotations) (download)
Wed Jul 8 23:45:08 2009 UTC (5 years, 3 months ago) by markusle
Branch: MAIN
CVS Tags: HEAD
Changes since 1.3: +1 -1 lines
FILE REMOVED
Removed old ebuild and patches and beautified 3.2.0 ebuild a bit.
(Portage version: 2.2_rc33/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.2.ebuild,v 1.3 2009/06/21 18:47:58 graaff 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="~amd64 ~x86 ~alpha ~hppa ~ppc ~ppc64 ~sparc"
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/dejagnu
41 dev-util/gperf
42 dev-util/pkgconfig"
43
44 FORTRAN="gfortran ifc g77 f2c"
45
46 src_unpack() {
47 unpack ${A}
48 cd "${S}"
49 epatch "${FILESDIR}"/${PN}-3.0.0-pkg.patch
50 epatch "${FILESDIR}"/${PN}-3.0.1-test-fix.patch
51 epatch "${FILESDIR}"/${PN}-3.0.1-add_syspath.patch
52 epatch "${FILESDIR}"/${PN}-3.0.1-fix_handle_for_plotyy.patch
53 epatch "${FILESDIR}"/${PN}-3.0.1-no_helvetica.patch
54 epatch "${FILESDIR}"/${PN}-3.0.1-chi2rnd.patch
55 }
56
57 src_compile() {
58
59 econf \
60 --localstatedir=/var/state/octave \
61 --enable-shared \
62 --with-blas="$(pkg-config --libs blas)" \
63 --with-lapack="$(pkg-config --libs lapack)" \
64 $(use_with hdf5) \
65 $(use_with curl) \
66 $(use_with zlib) \
67 $(use_with fftw) \
68 $(use_with sparse umfpack) \
69 $(use_with sparse colamd) \
70 $(use_with sparse ccolamd) \
71 $(use_with sparse cholmod) \
72 $(use_with sparse cxsparse) \
73 $(use_enable readline) \
74 || die "econf failed"
75
76 emake || die "emake failed"
77
78 if use xemacs; then
79 cd "${S}/emacs"
80 xemacs-elisp-comp *.el
81 fi
82 }
83
84 src_install() {
85 emake install DESTDIR="${D}" || die "emake install failed"
86
87 if use doc; then
88 einfo "Installing documentation..."
89 insinto /usr/share/doc/${PF}
90 doins $(find doc -name \*.pdf)
91 fi
92
93 if use emacs || use xemacs; then
94 cd emacs
95 exeinto /usr/bin
96 doexe octave-tags || die "Failed to install octave-tags"
97 doman octave-tags.1 || die "Failed to install octave-tags.1"
98 if use xemacs; then
99 xemacs-elisp-install ${PN} *.el *.elc
100 fi
101 cd ..
102 fi
103
104 echo "LDPATH=/usr/$(get_libdir)/octave-${PV}" > 99octave
105 doenvd 99octave || die
106
107 # Fixes ls-R files to remove /var/tmp/portage references.
108 sed -i \
109 -e "s:${D}::g" \
110 "${D}"/usr/*/${PN}/ls-R \
111 || die "Failed to fix ls-R files."
112 }

  ViewVC Help
Powered by ViewVC 1.1.20