diff options
author | Sebastien Fabbro <bicatali@gentoo.org> | 2009-02-26 17:22:47 +0000 |
---|---|---|
committer | Sebastien Fabbro <bicatali@gentoo.org> | 2009-02-26 17:22:47 +0000 |
commit | 9d2c74fb135c7daffa485d6fce4109a943d4e6a0 (patch) | |
tree | 63cbe72f50ac97e537fcd0364f73804633f65bfe /sci-astronomy/scamp | |
parent | Install documentation (diff) | |
download | gentoo-2-9d2c74fb135c7daffa485d6fce4109a943d4e6a0.tar.gz gentoo-2-9d2c74fb135c7daffa485d6fce4109a943d4e6a0.tar.bz2 gentoo-2-9d2c74fb135c7daffa485d6fce4109a943d4e6a0.zip |
Initial import to the main tree from the sci overlay. Also included autotools from scamp svn public repository for better dependencies
(Portage version: 2.2_rc23/cvs/Linux x86_64)
Diffstat (limited to 'sci-astronomy/scamp')
-rw-r--r-- | sci-astronomy/scamp/ChangeLog | 41 | ||||
-rw-r--r-- | sci-astronomy/scamp/files/scamp-1.4.6-autotools.patch | 331 | ||||
-rw-r--r-- | sci-astronomy/scamp/metadata.xml | 13 | ||||
-rw-r--r-- | sci-astronomy/scamp/scamp-1.4.6.ebuild | 51 |
4 files changed, 436 insertions, 0 deletions
diff --git a/sci-astronomy/scamp/ChangeLog b/sci-astronomy/scamp/ChangeLog new file mode 100644 index 000000000000..b23f489f4862 --- /dev/null +++ b/sci-astronomy/scamp/ChangeLog @@ -0,0 +1,41 @@ +# ChangeLog for sci-astronomy/scamp +# Copyright 1999-2009 Gentoo Foundation; Distributed under the GPL v2 +# $Header: /var/cvsroot/gentoo-x86/sci-astronomy/scamp/ChangeLog,v 1.1 2009/02/26 17:22:47 bicatali Exp $ + +*scamp-1.4.6 (26 Feb 2009) + + 26 Feb 2009; Sébastien Fabbro <bicatali@gentoo.org> + +files/scamp-1.4.6-autotools.patch, +metadata.xml, +scamp-1.4.6.ebuild: + Initial import to the main tree from the sci overlay. Also included + autotools from scamp svn public repository for better dependencies + + 02 Jul 2008; Sébastien Fabbro <bicatali@gentoo.org> + +files/scamp-1.4.6-plplot.patch, -files/scamp-atlas.patch, + -scamp-1.4.0.ebuild, +scamp-1.4.6.ebuild: + Version bump. + + 08 Nov 2007; Sébastien Fabbro <bicatali@gentoo.org> + +files/scamp-atlas.patch, -scamp-1.3.11.ebuild, +scamp-1.4.0.ebuild: + Version bump + + 02 Aug 2007; Sébastien Fabbro <bicatali@gentoo.org> -scamp-1.3.8.ebuild, + +scamp-1.3.11.ebuild: + Version bump + + 18 May 2007; Sébastien Fabbro <bicatali@gentoo.org> -scamp-1.3.5.ebuild, + +scamp-1.3.8.ebuild: + Version bump + + 26 Mar 2007; Sébastien Fabbro <bicatali@gentoo.org> + -scamp-1.2.11-r1.ebuild, +scamp-1.3.5.ebuild: + Version bump. + + 29 Dec 2006; Sebastien Fabbro <seb@ist.utl.pt>; + Removed icc flag, too buggy. + + 15 Oct 2006; Sebastien Fabbro <seb@ist.utl.pt> +scamp-1.2.11-r1.ebuild: + Removed flag filtering, some cleaning. + + 19 Sep 2006; Sebastien Fabbro <seb@ist.utl.pt> +scamp-1.2.11.ebuild: + Initial import. + diff --git a/sci-astronomy/scamp/files/scamp-1.4.6-autotools.patch b/sci-astronomy/scamp/files/scamp-1.4.6-autotools.patch new file mode 100644 index 000000000000..8611352c9eca --- /dev/null +++ b/sci-astronomy/scamp/files/scamp-1.4.6-autotools.patch @@ -0,0 +1,331 @@ +diff -Nur scamp-1.4.6.orig/acx_atlas.m4 scamp-1.4.6/acx_atlas.m4 +--- scamp-1.4.6.orig/acx_atlas.m4 2009-02-26 16:50:10.382847729 +0000 ++++ scamp-1.4.6/acx_atlas.m4 2009-02-26 16:51:08.414884885 +0000 +@@ -194,6 +194,7 @@ + [$ATLAS_LIBPATH -lcblas -latlas -lm]) + if test x$acx_atlas_ok = xyes; then + ATLAS_LIB="$ATLAS_LIBPATH -llapack -lptcblas -lcblas -latlas" ++ LIBS="$OLIBS" + AC_SUBST(ATLAS_LIB) + AC_DEFINE(HAVE_ATLAS_MP,1, + [Define if you have the parallel ATLAS libraries.]) +@@ -205,6 +206,7 @@ + fi + else + ATLAS_LIB="$ATLAS_LIBPATH -llapack -lcblas -latlas" ++ LIBS="$OLIBS" + AC_SUBST(ATLAS_LIB) + $4 + fi +diff -Nur scamp-1.4.6.orig/acx_fftw.m4 scamp-1.4.6/acx_fftw.m4 +--- scamp-1.4.6.orig/acx_fftw.m4 2009-02-26 16:50:10.382847729 +0000 ++++ scamp-1.4.6/acx_fftw.m4 2009-02-26 16:51:08.414884885 +0000 +@@ -89,7 +89,7 @@ + if test x$acx_fftw_ok = xyes && test x$3 = xyes; then + if test x$4 = xyes; then + AC_CHECK_LIB(fftw3f_threads, fftwf_init_threads, +- [acx_fftw_ok=yes], [acx_fftw_ok=no], [-lfftw3f -lm]) ++ [acx_fftw_ok=yes], [acx_fftw_ok=no], [-lfftw3f -lm -lpthread]) + if test x$acx_fftw_ok = xyes; then + AC_DEFINE(HAVE_FFTWFT,1, + [Define if you have the FFTW single precision multithreaded libraries and header files.]) +@@ -99,7 +99,7 @@ + fi + else + AC_CHECK_LIB(fftw3_threads, fftw_init_threads, +- [acx_fftw_ok=yes], [acx_fftw_ok=no], [-lfftw3 -lm]) ++ [acx_fftw_ok=yes], [acx_fftw_ok=no], [-lfftw3 -lm -lpthread]) + if test x$acx_fftw_ok = xyes; then + AC_DEFINE(HAVE_FFTWT,1, + [Define if you have the FFTW double precision multithreaded libraries and header files.]) +@@ -115,7 +115,7 @@ + dnl ------------------------- + if test x$4 = xyes; then + AC_CHECK_LIB(fftw3f, fftwf_execute, [acx_fftw_ok=yes], +- [acx_fftw_ok=no], [-lm]) ++ [acx_fftw_ok=no], [-L$1 -lm]) + if test x$acx_fftw_ok = xyes; then + AC_DEFINE(HAVE_FFTWF,1, + [Define if you have the FFTW single precision libraries and header files.]) +@@ -125,7 +125,7 @@ + fi + else + AC_CHECK_LIB(fftw3, fftw_execute, [acx_fftw_ok=yes], +- [acx_fftw_ok=no], [-lm]) ++ [acx_fftw_ok=no], [-L$1 -lm]) + if test x$acx_fftw_ok = xyes; then + AC_DEFINE(HAVE_FFTW,1, + [Define if you have the FFTW double precision libraries and header files.]) +@@ -136,8 +136,8 @@ + fi + if test x$acx_fftw_ok = xyes && test x$3 = xyes; then + if test x$4 = xyes; then +- AC_CHECK_LIB(fftw3f_threads, fftwf_init_threads, +- [acx_fftw_ok=yes], [acx_fftw_ok=no], [-lfftw3f -lm]) ++ AC_CHECK_LIB(fftw3f_threads, fftwf_init_threads, [acx_fftw_ok=yes], ++ [acx_fftw_ok=no], [-L$1 -lfftw3f -lm -lpthread]) + if test x$acx_fftw_ok = xyes; then + AC_DEFINE(HAVE_FFTWFT,1, + [Define if you have the FFTW single precision multithreaded libraries and header files.]) +@@ -146,8 +146,8 @@ + FFTW_ERROR="FFTW single precision library in $1 was compiled without multithreading support!" + fi + else +- AC_CHECK_LIB(fftw3_threads, fftw_init_threads, +- [acx_fftw_ok=yes], [acx_fftw_ok=no], [-lfftw3 -lm]) ++ AC_CHECK_LIB(fftw3_threads, fftw_init_threads, [acx_fftw_ok=yes], ++ [acx_fftw_ok=no], [-L$1 -lfftw3 -lm -lpthread]) + if test x$acx_fftw_ok = xyes; then + AC_DEFINE(HAVE_FFTWT,1, + [Define if you have the FFTW double precision multithreaded libraries and header files.]) +diff -Nur scamp-1.4.6.orig/acx_plplot.m4 scamp-1.4.6/acx_plplot.m4 +--- scamp-1.4.6.orig/acx_plplot.m4 2009-02-26 16:50:10.382847729 +0000 ++++ scamp-1.4.6/acx_plplot.m4 2009-02-26 16:51:08.414884885 +0000 +@@ -1,4 +1,5 @@ +-dnl @synopsis ACX_PLPLOT([PLPLOT_DIR,[ACTION-IF-FOUND[, ACTION-IF-NOT-FOUND]]]) ++dnl @synopsis ACX_PLPLOT([PLPLOT_LIBDIR, PLPLOT_INCDIR, ++dnl [ACTION-IF-FOUND[, ACTION-IF-NOT-FOUND]]]) + dnl This macro figures out if the PlPlot library and header files + dnl are installed. + dnl You may wish to use these variables in your default LIBS and CFLAGS: +@@ -16,28 +17,71 @@ + AC_DEFUN([ACX_PLPLOT], [ + AC_REQUIRE([AC_CANONICAL_HOST]) + +-AC_CHECK_PROG(acx_plplot_ok, plplot-config, [yes], [no]) +-plpath=`plplot-config --prefix` +-if test x$acx_plplot_ok = xyes; then +-AC_CHECK_HEADER([${plpath}/include/plplot/plplot.h],[acx_plplot_ok=yes]) ++PLPLOT_LIBS="" ++OLIBS="$LIBS" ++LIBS="" ++ ++acx_plplot_ok=yes ++acx_plplotpkg_ok=no ++if test x$2 = x && test x$1 = x; then ++ AC_MSG_CHECKING([for PLPlot pkg-config info]) ++ if pkg-config --exists plplotd; then ++ AC_MSG_RESULT([yes]) ++ [PLPLOT_CFLAGS=`pkg-config --cflags plplotd`] ++ [PLPLOT_LIBS=`pkg-config --libs plplotd`] ++ AC_DEFINE(PLPLOT_H, "plplot.h", [PLPlot header filename.]) ++ AC_DEFINE(PLPLOTP_H, "plplotP.h", [PLPlot private header filename.]) ++ acx_plplotpkg_ok=yes ++ else ++ AC_MSG_RESULT([no]) + fi +-if test x$acx_plplot_ok = xyes; then +- [PLPLOT_CFLAGS=`plplot-config --cflags`] +- [PLPLOT_DIR="${plpath}"] +- [PLPLOT_LIBPATH="-L${plpath}/lib"] ++fi ++if test x$acx_plplotpkg_ok = xno; then ++ if test x$2 = x; then ++ AC_CHECK_HEADER(plplot.h, [acx_plplothead_ok=yes], [acx_plplothead_ok=no]) ++ if test x$acx_plplothead_ok = xyes; then ++ AC_DEFINE(PLPLOT_H, "plplot.h", [PLPlot header filename.]) ++ AC_DEFINE(PLPLOTP_H, "plplotP.h", [PLPlot private header filename.]) ++ else ++ AC_CHECK_HEADER(plplot/plplot.h, ++ [acx_plplothead_ok=yes], [acx_plplothead_ok=no]) ++ if test x$acx_plplothead_ok = xyes; then ++ AC_DEFINE(PLPLOT_H, "plplot/plplot.h", [PLPlot header filename.]) ++ AC_DEFINE(PLPLOTP_H, "plplot/plplotP.h", ++ [PLPlot private header filename.]) ++ else ++ acx_plplot_ok=no ++ fi ++ fi ++ else ++ AC_CHECK_HEADER($2/plplot.h, ++ [acx_plplothead_ok=yes], [acx_plplothead_ok=no]) ++ if test x$acx_plplothead_ok = xyes; then ++ AC_DEFINE(PLPLOT_H, "plplot.h", [PLPlot header filename.]) ++ AC_DEFINE(PLPLOTP_H, "plplotP.h", [PLPlot private header filename.]) ++ [PLPLOT_CFLAGS="-I$2"] ++ else ++ acx_plplot_ok=no ++ fi ++ fi ++ if test x$1 = x; then ++ AC_CHECK_LIB(plplotd, c_plinit,, [acx_plplot_ok=no]) + [PLPLOT_LIBS="-lplplotd"] ++ else ++ AC_CHECK_LIB(plplotd, c_plinit,, [acx_plplot_ok=no], [-L$1]) ++ [PLPLOT_LIBS="-L$1 -lplplotd"] ++ fi + fi + +-AC_SUBST(PLPLOT_LIBS) ++LIBS="$OLIBS" ++if test x$acx_plplot_ok = xyes; then + AC_SUBST(PLPLOT_CFLAGS) +- +-# Finally, execute ACTION-IF-FOUND/ACTION-IF-NOT-FOUND: +-if test x"$acx_plplot_ok" = xyes; then ++ AC_SUBST(PLPLOT_LIBS) + AC_DEFINE(HAVE_PLPLOT,1, + [Define if you have the PLPlot libraries and header files.]) +- $2 +-else + $3 ++else ++ $4 + fi + + ])dnl ACX_PLPLOT +diff -Nur scamp-1.4.6.orig/configure.ac scamp-1.4.6/configure.ac +--- scamp-1.4.6.orig/configure.ac 2009-02-26 16:50:10.382847729 +0000 ++++ scamp-1.4.6/configure.ac 2009-02-26 16:51:08.310883768 +0000 +@@ -53,15 +53,13 @@ + # GCC is chosen last because it is likely to yield less optimized code + AC_LANG(C) + AC_PROG_CC([$cclist]) +-# C Compiler: Check that it is ANSI C ++# C Compiler: Check that it is ANSI C and POSIX-compliant + AM_PROG_CC_STDC +-AC_DISABLE_STATIC +-AC_PROG_LIBTOOL +- +-# C Compiler: Check that it is POSIX-compliant + AC_ISC_POSIX + ACX_PROG_CC_OPTIM ++AC_DISABLE_STATIC + #AC_DISABLE_SHARED ++AC_PROG_LIBTOOL + AC_PROG_INSTALL + + # Checks for libraries. +@@ -89,21 +87,11 @@ + AC_CHECK_FUNC([isnan], AC_DEFINE_UNQUOTED([HAVE_ISNAN2], 1, + [Second isnan check])) + +-datadir2=$(URBI_RESOLVE_DIR([$datadir])) ++# Check support for large files ++AC_SYS_LARGEFILE ++AC_FUNC_FSEEKO + +-# Provide a special option for PlPLOT +-AC_ARG_WITH(plplot, +- [AC_HELP_STRING([--with-plplot@<:@=<PLPlot dir>@:>@], +- [Provide an alternative path to the PLPlot library])], +- use_plplot="yes" +- if "$withval" == "no"; then +- use_plplot="no" +- fi +- if test "$withval" != "yes"; then +- plplot_dir=$withval +- fi, +- use_plplot="yes" +- ) ++datadir2=$(URBI_RESOLVE_DIR([$datadir])) + + # Provide special option for debugging + AC_MSG_CHECKING([for debugger mode]) +@@ -115,6 +103,27 @@ + use_debug="no" + AC_MSG_RESULT([no])) + ++# Provide special options for PLPLOT ++AC_ARG_WITH(plplot, ++ [AC_HELP_STRING([--with-plplot@<:@=<PLPlot library dir>@:>@], ++ [Activate PLPlot library (default = yes)])], ++ if test "$withval" = "no"; then ++ use_plplot="no" ++ else ++ use_plplot="yes" ++ if test "$withval" != "yes"; then ++ plplot_dir=$withval ++ fi ++ fi, ++ use_plplot="yes" ++ ) ++AC_ARG_WITH(plplot-incdir, ++ [AC_HELP_STRING([--with-plplot-incdir=<PLPlot include dir>], ++ [Provide an alternative path to the PLPlot include directory])], ++ plplot_incdir=$withval, ++ plplot_incdir="" ++ ) ++ + # Provide special options for ATLAS + AC_ARG_WITH(atlas, + [AC_HELP_STRING([--with-atlas=<ATLAS library path>], +@@ -162,17 +171,19 @@ + AC_DEFINE_UNQUOTED([XSL_URL], "$xsl_url",[Default URL of the XSLT filter]) + + # Set flags for multithreading ++n_pthreads=16 + AC_ARG_ENABLE(threads, + [AC_HELP_STRING([--enable-threads@<:@=<max_number_of_threads>@:>@], +- [Enable multhreading (off by default)])], +- if test "$enableval" = "yes"; then +- n_pthreads=16 ++ [Enable multhreading (on with up to $n_pthreads threads by default)])], ++ if test "$enableval" = "no"; then ++ use_pthreads="no" + else ++ use_pthreads="yes" ++ if test "$enableval" != "yes"; then + n_pthreads=$enableval + fi +- use_pthreads=yes, +- n_pthreads=1 +- use_pthreads=no ++ fi, ++ use_pthreads=yes + ) + + # Provide special option for profiling +@@ -239,34 +250,35 @@ + fi + + ################# handle the PLPlot library (graphic plots) ################## ++AC_MSG_CHECKING([for PLPlot configure option]) + if test "$use_plplot" = "yes"; then +- ACX_PLPLOT(,,[use_plplot=no]) +- if test "$use_plplot" = "no"; then +- AC_MSG_WARN(PLPlot library not found! Plotting deactivated.) +- fi +-fi +- ++ AC_MSG_RESULT([yes]) ++ ACX_PLPLOT($plplot_dir,$plplot_incdir,,[use_plplot=no]) + if test "$use_plplot" = "yes"; then +- AC_SUBST(PLPLOT_CFLAGS) + [CFLAGS="$CFLAGS $PLPLOT_CFLAGS"] +- [LIBS="$PLPLOT_LIBS $PTHREAD_LIBS $LIBS"] ++ [LIBS="$PLPLOT_LIBS $LIBS"] ++ else ++ AC_MSG_WARN(PLPlot library not found/incomplete! Plotting deactivated.) + fi +-AM_CONDITIONAL(USE_PLPLOT, test $use_plplot = "yes") +- +-# Special optimization options for the INTEL C compiler +-if test $use_icc = "yes" && test $CC = "icc"; then +- CFLAGS="$CFLAGS -O3 -axPW -ip -unroll" +- LDFLAGS="$LDFLAGS -static-intel" ++else ++ AC_MSG_RESULT([no]) ++ AC_MSG_WARN(Plotting deactivated.) + fi ++AM_CONDITIONAL(USE_PLPLOT, test $use_plplot = "yes") + + # Debugging + if test "$use_debug" = "yes"; then + CFLAGS="-g $CFLAGS" + fi + +-# Profiling +-if test "$use_prof" = "yes"; then +- CFLAGS="-pg -O3 -Wall $CFLAGS" ++# Link with gprof option ++if test "$use_gprof" = "yes"; then ++ if test "$use_icc" = "yes"; then ++ CFLAGS="$CFLAGS -pq" ++ else ++ CFLAGS="$CFLAGS -pg" ++ fi ++ use_static="no" + fi + + # Static linking option diff --git a/sci-astronomy/scamp/metadata.xml b/sci-astronomy/scamp/metadata.xml new file mode 100644 index 000000000000..54e3f603c97d --- /dev/null +++ b/sci-astronomy/scamp/metadata.xml @@ -0,0 +1,13 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd"> +<pkgmetadata> +<herd>sci</herd> +<longdescription lang="en"> + SCAMP computes astrometric and photometric solutions from SExtractor catalogs + and stores them in header files. These headers files can be read by SWarp to + coadd images. +</longdescription> +<use> + <flag name="plplot">Build with <pkg>sci-libs/plplot</pkg> to allow diagnostic plots during processing</flag> +</use> +</pkgmetadata> diff --git a/sci-astronomy/scamp/scamp-1.4.6.ebuild b/sci-astronomy/scamp/scamp-1.4.6.ebuild new file mode 100644 index 000000000000..130179d668ec --- /dev/null +++ b/sci-astronomy/scamp/scamp-1.4.6.ebuild @@ -0,0 +1,51 @@ +# Copyright 1999-2009 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Header: /var/cvsroot/gentoo-x86/sci-astronomy/scamp/scamp-1.4.6.ebuild,v 1.1 2009/02/26 17:22:47 bicatali Exp $ + +EAPI=2 +inherit eutils autotools + +DESCRIPTION="Computes astrometric and photometric solutions for astronomical images" +HOMEPAGE="http://terapix.iap.fr/soft/scamp" +SRC_URI="ftp://ftp.iap.fr/pub/from_users/bertin/${PN}/${P}.tar.gz" + +LICENSE="GPL-2" +SLOT="0" +KEYWORDS="~amd64 ~x86" +IUSE="doc threads plplot" + +RDEPEND="sci-astronomy/cdsclient + virtual/cblas + >=sci-libs/lapack-atlas-3.8.0 + sci-libs/fftw:3.0 + plplot? ( >=sci-libs/plplot-5.9 )" +DEPEND="${RDEPEND} + dev-util/pkgconfig" + +src_prepare() { + # use better autotools from svn repo + epatch "${FILESDIR}"/${P}-autotools.patch + # gentoo uses cblas instead of ptcblas + sed -i \ + -e 's/ptcblas/cblas/g' \ + acx_atlas.m4 || die "sed acx_atlas.m4 failed" + # use pkgconfig instead of obsolete plplot-config + # epatch "${FILESDIR}"/${P}-plplot.patch + eautoreconf +} + +src_configure() { + econf \ + --with-atlas="/usr/$(get_libdir)/lapack/atlas" \ + $(use_with plplot) \ + $(use_enable threads) +} + +src_install () { + emake DESTDIR="${D}" install || die "emake install failed" + dodoc AUTHORS ChangeLog HISTORY README THANKS BUGS + if use doc; then + insinto /usr/share/doc/${PF} + doins doc/*.pdf || die "pdf doc install failed" + fi +} |