/[gentoo-x86]/sci-libs/cbflib/cbflib-0.9.0-r3.ebuild
Gentoo

Contents of /sci-libs/cbflib/cbflib-0.9.0-r3.ebuild

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1.9 - (show annotations) (download)
Tue Dec 4 11:49:31 2012 UTC (21 months, 3 weeks ago) by jlec
Branch: MAIN
CVS Tags: HEAD
Changes since 1.8: +1 -1 lines
FILE REMOVED
sci-libs/cbflib: Drop old

(Portage version: 2.2.0_alpha144/cvs/Linux x86_64, signed Manifest commit with key 70EB7916)

1 # Copyright 1999-2012 Gentoo Foundation
2 # Distributed under the terms of the GNU General Public License v2
3 # $Header: /var/cvsroot/gentoo-x86/sci-libs/cbflib/cbflib-0.9.0-r3.ebuild,v 1.8 2012/10/18 21:33:44 jlec Exp $
4
5 EAPI=3
6
7 PYTHON_DEPEND="python? 2"
8 SUPPORT_PYTHON_ABIS="1"
9 RESTRICT_PYTHON_ABIS="3.*"
10
11 inherit distutils eutils flag-o-matic fortran-2 toolchain-funcs
12
13 PYTHON_MODNAME="pycbf.py"
14 MY_P1="CBFlib-${PV}"
15 MY_P2="CBFlib_${PV}"
16
17 DESCRIPTION="Library providing a simple mechanism for accessing CBF files and imgCIF files"
18 HOMEPAGE="http://www.bernstein-plus-sons.com/software/CBF/"
19 #BASE_TEST_URI="http://arcib.dowling.edu/software/CBFlib/downloads/version_${PV}/"
20 SRC_URI="mirror://sourceforge/${PN}/${MY_P1}_14Feb10.tar.gz"
21 # test? (
22 # ${BASE_TEST_URI}/${MY_P2}_Data_Files_Input.tar.gz
23 # ${BASE_TEST_URI}/${MY_P2}_Data_Files_Output.tar.gz
24 # )"
25
26 LICENSE="GPL-2"
27 SLOT="0"
28 KEYWORDS="amd64 ppc x86 ~amd64-linux ~x86-linux"
29 IUSE="doc python"
30
31 S="${WORKDIR}/${MY_P1}"
32
33 src_prepare(){
34 rm -rf Py* drel* dRel* ply*
35 epatch "${FILESDIR}"/${PV}-Makefile.patch
36 edos2unix pycbf/setup.py
37 epatch "${FILESDIR}"/${PV}-python.patch
38 cp Makefile_LINUX_gcc42 Makefile
39
40 append-fflags -fno-range-check
41 append-cflags -D_USE_XOPEN_EXTENDED
42
43 sed \
44 -e "s|^CC.*$|CC = $(tc-getCC)|" \
45 -e "s|^C++.*$|C++ = $(tc-getCXX)|" \
46 -e "s|C++|CXX|g" \
47 -e "s|^CFLAGS.*$|CFLAGS = ${CFLAGS}|" \
48 -e "s|^F90C.*$|F90C = $(tc-getFC)|" \
49 -e "s|^F90FLAGS.*$|F90FLAGS = ${FFLAGS}|" \
50 -e "s|^SOLDFLAGS.*$|SOLDFLAGS = -shared ${LDFLAGS}|g" \
51 -e "s| /bin| ${EPREFIX}/bin|g" \
52 -e "s|/usr|${EPREFIX}/usr|g" \
53 -i Makefile || die
54 }
55
56 src_compile() {
57 emake -j1 shared || die
58
59 if use python; then
60 cd pycbf
61 distutils_src_compile
62 fi
63 }
64
65 # test app is borked in this version
66 # produces buffer overflows
67 #src_test(){
68 # emake -j1 tests || die
69 #}
70
71 src_install() {
72 insinto /usr/include/${PN}
73 doins include/*.h || die
74
75 dolib.so solib/lib* || die
76
77 dodoc README || die
78 if use doc; then
79 dohtml -r README.html html_graphics doc || die
80 fi
81 if use python; then
82 cd pycbf
83 distutils_src_install
84 fi
85 }
86
87 pkg_postinst() {
88 use python && distutils_pkg_postinst
89 }
90
91 pkg_postrm() {
92 use python && distutils_pkg_postrm
93 }

  ViewVC Help
Powered by ViewVC 1.1.20