aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorbicatali <bicatali@32389bae-6d03-0410-99cf-db05cde120eb>2007-02-24 01:38:55 +0000
committerbicatali <bicatali@32389bae-6d03-0410-99cf-db05cde120eb>2007-02-24 01:38:55 +0000
commit9a91ba700afe3972f94c14519518afb4bbe35032 (patch)
tree19c36169e4c34827a967d3412f9d8a6d921aa617
parentroot-5.14 fixes (diff)
downloadsci-9a91ba700afe3972f94c14519518afb4bbe35032.tar.gz
sci-9a91ba700afe3972f94c14519518afb4bbe35032.tar.bz2
sci-9a91ba700afe3972f94c14519518afb4bbe35032.zip
fixed cfitsio
git-svn-id: http://overlays.gentoo.org/svn/proj/science/overlay@506 32389bae-6d03-0410-99cf-db05cde120eb
-rw-r--r--sci-libs/cfitsio/Manifest32
-rw-r--r--sci-libs/cfitsio/cfitsio-3.030.ebuild26
-rw-r--r--sci-libs/cfitsio/files/cfitsio-3.030-Makefile.am37
-rw-r--r--sci-libs/cfitsio/files/cfitsio-3.030-configure.ac33
-rw-r--r--sci-libs/cfitsio/metadata.xml14
5 files changed, 93 insertions, 49 deletions
diff --git a/sci-libs/cfitsio/Manifest b/sci-libs/cfitsio/Manifest
index 1042f5e6c..9be90377e 100644
--- a/sci-libs/cfitsio/Manifest
+++ b/sci-libs/cfitsio/Manifest
@@ -1,28 +1,28 @@
-AUX cfitsio-3.030-Makefile.am 1129 RMD160 c5fc764515ee6aad29859f14c8a1e42937c36db7 SHA1 d26d9da4634a847425476b2b2f436c08eebbc673 SHA256 2a3c0235ab2257becc9ed65f2d36921040cdfbac4bddc949b6770f88eeef3934
-MD5 ad23360f22cab53c477348423aba27e7 files/cfitsio-3.030-Makefile.am 1129
-RMD160 c5fc764515ee6aad29859f14c8a1e42937c36db7 files/cfitsio-3.030-Makefile.am 1129
-SHA256 2a3c0235ab2257becc9ed65f2d36921040cdfbac4bddc949b6770f88eeef3934 files/cfitsio-3.030-Makefile.am 1129
-AUX cfitsio-3.030-configure.ac 6748 RMD160 365ed19dcd11f0881349829fdfd1c8cec0ae50ab SHA1 c9d707ae8401dfdc3764d0da4140e0e2f6165db5 SHA256 bac82f8384b48924abadc69631cdbd1f6b3817b437f65c26c004b0851324b1e0
-MD5 3e03752c686ae9819b2a7e11954a65d2 files/cfitsio-3.030-configure.ac 6748
-RMD160 365ed19dcd11f0881349829fdfd1c8cec0ae50ab files/cfitsio-3.030-configure.ac 6748
-SHA256 bac82f8384b48924abadc69631cdbd1f6b3817b437f65c26c004b0851324b1e0 files/cfitsio-3.030-configure.ac 6748
+AUX cfitsio-3.030-Makefile.am 1257 RMD160 d128f882df5354c7a9e547c880a75c9a92640602 SHA1 50d515064a7236fa8d6897a60708e10d5a07a205 SHA256 b611b193bf1676ec267db875713c09d48d2e194e6e9350add3a166ba39fdca77
+MD5 e5729854ff3690cffbcd4de67884086f files/cfitsio-3.030-Makefile.am 1257
+RMD160 d128f882df5354c7a9e547c880a75c9a92640602 files/cfitsio-3.030-Makefile.am 1257
+SHA256 b611b193bf1676ec267db875713c09d48d2e194e6e9350add3a166ba39fdca77 files/cfitsio-3.030-Makefile.am 1257
+AUX cfitsio-3.030-configure.ac 7796 RMD160 97da559f8b45c164de34304f588f288ed4712d7a SHA1 7c131b6a6880ceba1ca5550062aad0a6e3e00b6a SHA256 df53d54d8ee07703c21ea35153f1f7980c763b969a51096f3853c716eec7db1f
+MD5 e5207d33f9d711c7bcb81ec76a672c03 files/cfitsio-3.030-configure.ac 7796
+RMD160 97da559f8b45c164de34304f588f288ed4712d7a files/cfitsio-3.030-configure.ac 7796
+SHA256 df53d54d8ee07703c21ea35153f1f7980c763b969a51096f3853c716eec7db1f files/cfitsio-3.030-configure.ac 7796
AUX cfitsio-cfortran.patch 348 RMD160 7a9bbcf6a724c2ec7563dfc1d3dd38f232ddeaf0 SHA1 35fa55f871dc187c479a68a621acdf77f2231e6f SHA256 9a45d0d7efc3492e2323c601841b98d1de17356b30a50709f02aa266d05180e2
MD5 f2f05a0eeac7137fe4ddd0d99a63aa6b files/cfitsio-cfortran.patch 348
RMD160 7a9bbcf6a724c2ec7563dfc1d3dd38f232ddeaf0 files/cfitsio-cfortran.patch 348
SHA256 9a45d0d7efc3492e2323c601841b98d1de17356b30a50709f02aa266d05180e2 files/cfitsio-cfortran.patch 348
DIST cfitsio3030.tar.gz 2236701 RMD160 0a8935a17161fad16016aba6219a347c6891d994 SHA1 cbaadf586ec760071edf2968820de98d8541a9d0 SHA256 f21774a31274b851eb6d2d366266a6fe48a265b4ba87dc0ac8abacb48de77383
-EBUILD cfitsio-3.030.ebuild 1009 RMD160 9d7aa088e9f04895881649ccc10544b76a221655 SHA1 a5fa4ee496bfbf82a0730034f12559e7f1efcbe2 SHA256 44c1ea3b5183a60a7c01d3d3f8895b2bddf6c2cf7d7ac711aadcd9f149b48ea0
-MD5 98950824de98ccefd4ea4be220eefd65 cfitsio-3.030.ebuild 1009
-RMD160 9d7aa088e9f04895881649ccc10544b76a221655 cfitsio-3.030.ebuild 1009
-SHA256 44c1ea3b5183a60a7c01d3d3f8895b2bddf6c2cf7d7ac711aadcd9f149b48ea0 cfitsio-3.030.ebuild 1009
+EBUILD cfitsio-3.030.ebuild 1247 RMD160 0bdd2a5387d556b785963d47957dc17fe7c123a9 SHA1 6ed2ab7ead933c415e67b0f90435df728b1fdf12 SHA256 a3ec32c49f8b4ec948c146f05e6e9439c2c072814b11fbd85b9f3f821f1d7ed0
+MD5 f5f9ce9a5a9ad8aa3a21c843805b3666 cfitsio-3.030.ebuild 1247
+RMD160 0bdd2a5387d556b785963d47957dc17fe7c123a9 cfitsio-3.030.ebuild 1247
+SHA256 a3ec32c49f8b4ec948c146f05e6e9439c2c072814b11fbd85b9f3f821f1d7ed0 cfitsio-3.030.ebuild 1247
MISC ChangeLog 1202 RMD160 a933b24c3b0b8156029106556aefb0bcf5946263 SHA1 4fe333e8f873bff4d70b93b8e1c1d062d623ddcc SHA256 df517a88c6476479726650c60d1f79244ae43485a5e35631563f56e641a3fbbc
MD5 006532e19f3c10dafe8376550131ffca ChangeLog 1202
RMD160 a933b24c3b0b8156029106556aefb0bcf5946263 ChangeLog 1202
SHA256 df517a88c6476479726650c60d1f79244ae43485a5e35631563f56e641a3fbbc ChangeLog 1202
-MISC metadata.xml 682 RMD160 3d948185e7f50b2204fe0cd7f3b5f9f69bbe1fa3 SHA1 16d40c60a6140b93b0dcf1f53c1e9d161a641038 SHA256 5e52e553d1de1284403b19d3783036f5abb2d384a203053de4e85c70104fc24c
-MD5 ca9445640206098f48ec8d2620c3b6a1 metadata.xml 682
-RMD160 3d948185e7f50b2204fe0cd7f3b5f9f69bbe1fa3 metadata.xml 682
-SHA256 5e52e553d1de1284403b19d3783036f5abb2d384a203053de4e85c70104fc24c metadata.xml 682
+MISC metadata.xml 663 RMD160 fa865916cf612ed4d4510e2ac1a5aebd6568bad4 SHA1 4e58f56c8f6ebed1b013bc2c81509a7ebf569a9a SHA256 b3bf5af66a3c0b34c9f62155b3cf0207072cfae8695575dd194061e80873ec7e
+MD5 0598245dcf91c4c25294ad6da25d4e99 metadata.xml 663
+RMD160 fa865916cf612ed4d4510e2ac1a5aebd6568bad4 metadata.xml 663
+SHA256 b3bf5af66a3c0b34c9f62155b3cf0207072cfae8695575dd194061e80873ec7e metadata.xml 663
MD5 28870c9035a06f780c6ea425d724fe82 files/digest-cfitsio-3.030 238
RMD160 016faa3f1b5bd07e59380bfab84edeccef02cfcd files/digest-cfitsio-3.030 238
SHA256 98b81405e59975402e014c015fae52e687cf5ef2cb594550dd19cc9eb6d6d26f files/digest-cfitsio-3.030 238
diff --git a/sci-libs/cfitsio/cfitsio-3.030.ebuild b/sci-libs/cfitsio/cfitsio-3.030.ebuild
index 69c8b0790..ec2dcf6de 100644
--- a/sci-libs/cfitsio/cfitsio-3.030.ebuild
+++ b/sci-libs/cfitsio/cfitsio-3.030.ebuild
@@ -1,10 +1,8 @@
-# Copyright 1999-2006 Gentoo Foundation
+# Copyright 1999-2007 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
# $Header: $
-inherit autotools
-
-IUSE="doc"
+inherit fortran autotools
DESCRIPTION="C and Fortran library for manipulating FITS files"
HOMEPAGE="http://heasarc.gsfc.nasa.gov/docs/software/fitsio/fitsio.html"
@@ -13,15 +11,27 @@ SRC_URI="ftp://heasarc.gsfc.nasa.gov/software/fitsio/c/${PN}${PV//.}.tar.gz"
LICENSE="GPL-2"
SLOT="0"
KEYWORDS="~amd64 ~x86"
+IUSE="doc fortran"
-DEPEND="dev-lang/cfortran"
-
+DEPEND="fortran? ( dev-lang/cfortran )"
+FORTRAN="gfortran g77 ifc"
S=${WORKDIR}/${PN}
+pkg_setup() {
+ use fortran && fortran_pkg_setup
+}
+
src_unpack() {
- unpack ${A}
+ if use fortran; then
+ fortran_src_unpack ${A}
+ export FC="${FORTRANC}"
+ sed -i \
+ -e 's:"cfortran.h":<cfortran.h>:' \
+ "${S}"/f77_wrap.h || die "sed failed"
+ else
+ unpack ${A}
+ fi
cd "${S}"
- epatch "${FILESDIR}"/${PN}-cfortran.patch
cp "${FILESDIR}"/${P}-Makefile.am Makefile.am
cp "${FILESDIR}"/${P}-configure.ac configure.ac
eautoreconf
diff --git a/sci-libs/cfitsio/files/cfitsio-3.030-Makefile.am b/sci-libs/cfitsio/files/cfitsio-3.030-Makefile.am
index 8e3ad4377..ea67cd40d 100644
--- a/sci-libs/cfitsio/files/cfitsio-3.030-Makefile.am
+++ b/sci-libs/cfitsio/files/cfitsio-3.030-Makefile.am
@@ -1,24 +1,31 @@
+AM_CPPFLAGS = -D_REENTRANT
lib_LTLIBRARIES = libcfitsio.la
-libcfitsio_la_SOURCES = \
- buffers.c cfileio.c checksum.c compress.c drvrfile.c drvrmem.c \
- drvrnet.c drvrsmem.c editcol.c edithdu.c eval_l.c eval_y.c \
- eval_f.c fitscore.c getcol.c getcolb.c getcold.c getcole.c \
- getcoli.c getcolj.c getcolk.c getcoll.c getcols.c getcolsb.c \
- getcoluk.c getcolui.c getcoluj.c getkey.c group.c grparser.c \
- histo.c iraffits.c drvrgsiftp.c \
- modkey.c putcol.c putcolb.c putcold.c putcole.c putcoli.c \
- putcolj.c putcolk.c putcoluk.c putcoll.c putcols.c putcolsb.c \
- putcolu.c putcolui.c putcoluj.c putkey.c region.c scalnull.c \
- swapproc.c wcssub.c wcsutil.c imcompress.c quantize.c ricecomp.c \
- pliocomp.c fits_hcompress.c fits_hdecompress.c \
- f77_wrap1.c f77_wrap2.c f77_wrap3.c f77_wrap4.c
-libcfitsio_la_LIBADD = -lm
+FITSIO_SRC = f77_wrap1.c f77_wrap2.c f77_wrap3.c f77_wrap4.c
+CORE_SOURCES = buffers.c cfileio.c checksum.c compress.c drvrfile.c drvrmem.c \
+ drvrnet.c drvrsmem.c drvrgsiftp.c editcol.c edithdu.c eval_l.c \
+ eval_y.c eval_f.c fitscore.c getcol.c getcolb.c getcold.c getcole.c \
+ getcoli.c getcolj.c getcolk.c getcoll.c getcols.c getcolsb.c \
+ getcoluk.c getcolui.c getcoluj.c getkey.c group.c grparser.c \
+ histo.c iraffits.c \
+ modkey.c putcol.c putcolb.c putcold.c putcole.c putcoli.c \
+ putcolj.c putcolk.c putcoluk.c putcoll.c putcols.c putcolsb.c \
+ putcolu.c putcolui.c putcoluj.c putkey.c region.c scalnull.c \
+ swapproc.c wcssub.c wcsutil.c imcompress.c quantize.c ricecomp.c \
+ pliocomp.c fits_hcompress.c fits_hdecompress.c
+
+if F77BUILD
+libcfitsio_la_SOURCES = ${CORE_SOURCES} ${FITSIO_SRC}
+else
+libcfitsio_la_SOURCES = ${CORE_SOURCES}
+endif
+
include_HEADERS = fitsio.h fitsio2.h longnam.h drvrsmem.h
+
LDADD = libcfitsio.la
noinst_PROGRAMS = testprog speed cookbook
bin_PROGRAMS = fitscopy imcopy listhead
-testprog_SOURCES = testprog.c
+testprog_SOURCES = testprog.c
fitscopy_SOURCES = fitscopy.c
speed_SOURCES = speed.c
imcopy_SOURCES = imcopy.c
diff --git a/sci-libs/cfitsio/files/cfitsio-3.030-configure.ac b/sci-libs/cfitsio/files/cfitsio-3.030-configure.ac
index 68ffff440..0167ea41c 100644
--- a/sci-libs/cfitsio/files/cfitsio-3.030-configure.ac
+++ b/sci-libs/cfitsio/files/cfitsio-3.030-configure.ac
@@ -6,6 +6,34 @@ AC_INIT(cfitsio, 3.030, pence@tetra.gsfc.nasa.gov)
AM_INIT_AUTOMAKE([foreign])
AC_PROG_LIBTOOL
+AC_CHECK_PROGS(FC, f77 xlf cf77 gf77 gfortran g77 af77 ncf f2c ifort g95 , nope)
+if test $FC = 'nope' ; then
+ AC_MSG_WARN(cfitsio: == No acceptable f77 found in \$PATH)
+ AC_MSG_WARN(cfitsio: == Cfitsio will be built without Fortran wrapper support)
+ FC=
+ F77_WRAPPERS=
+else
+ CFORTRANFLAGS=
+ F77_WRAPPERS="\${FITSIO_SRC}"
+ echo $ac_n "checking whether we are using GNU Fortran""... $ac_c" 1>&6
+ if test `$FC --version -c < /dev/null 2> /dev/null | grep -c GNU` -gt 0 -o \
+ `$FC --version -c < /dev/null 2> /dev/null | grep -ic egcs` -gt 0
+ then
+ echo "$ac_t""yes" 1>&6
+ echo $ac_n "cfitsio: == Adding wrapper support for GNU Fortran""... $ac_c" 1>&6
+ CFORTRANFLAGS="-Dg77Fortran"
+ echo "$ac_t"" done" 1>&6
+ else
+ echo "$ac_t""no" 1>&6
+ if test $FC = 'f2c' ; then
+ echo $ac_n "cfitsio: == Adding wrapper support for f2c""... $ac_c" 1>&6
+ CFORTRANFLAGS="-Df2cFortran"
+ echo "$ac_t"" done" 1>&6
+ fi
+ fi
+fi
+
+
# taken from configure.in
# determine system type
#--------------------------------------------------------------------
@@ -223,8 +251,7 @@ AC_CHECK_FUNC(gethostbyname, , AC_CHECK_LIB(nsl, main, [LIBS="$LIBS -lnsl"]))
AC_DEFINE(HAVE_NET_SERVICES)
# ==================== END OF unix networking SECTION ================
-
-
+AM_CONDITIONAL(F77BUILD, test x$F77WRAPPERS )
+AC_CHECK_LIB(m, cos, [LIBS="$LIBS -lm"])
AC_CONFIG_FILES([Makefile])
AC_OUTPUT
-
diff --git a/sci-libs/cfitsio/metadata.xml b/sci-libs/cfitsio/metadata.xml
index 036b82de0..cbd007c16 100644
--- a/sci-libs/cfitsio/metadata.xml
+++ b/sci-libs/cfitsio/metadata.xml
@@ -4,12 +4,12 @@
<herd>sci</herd>
<maintainer><email>nerdboy@gentoo.org</email></maintainer>
<longdescription lang="en">
- CFITSIO is a library of C and Fortran subroutines for reading and
- writing data files in FITS (Flexible Image Transport System) data
- format. CFITSIO provides simple high-level routines for reading and
- writing FITS files that insulate the programmer from the internal
- complexities of the FITS format. CFITSIO also provides many advanced
- features for manipulating and filtering the information in FITS
- files.
+CFITSIO is a library of C and Fortran subroutines for reading and
+writing data files in FITS (Flexible Image Transport System) data
+format. CFITSIO provides simple high-level routines for reading and
+writing FITS files that insulate the programmer from the internal
+complexities of the FITS format. CFITSIO also provides advanced
+features for manipulating and filtering the information in FITS
+files.
</longdescription>
</pkgmetadata>