source: Sophya/trunk/ArchTOIPipe/configure.in@ 1454

Last change on this file since 1454 was 1365, checked in by aubourg, 25 years ago

pipeline TOI archeops

File size: 2.2 KB
RevLine 
[1365]1dnl Process this file with autoconf to produce a configure script.
2AC_INIT(toi.cc)
3AC_CONFIG_HEADER(conf.h)
4
5AC_ARG_WITH(sophya, [ --with-sophya Compile and link with SOPHYA],
6 use_sophya=1, use_sophya=0)
7
8AC_SUBST(use_sophya)
9
10if test `uname` = OSF1 -a -z "$CXX"; then
11 if test -x /usr/bin/cxx; then
12 echo "using cxx on alpha"
13 CXX=cxx
14 export CXX
15 fi
16fi
17
18AC_PROG_CXX
19
20AC_CHECK_SIZEOF(short)
21AC_CHECK_SIZEOF(int)
22AC_CHECK_SIZEOF(long)
23AC_CHECK_SIZEOF(float)
24AC_CHECK_SIZEOF(double)
25AC_CHECK_SIZEOF(long double)
26
27dnl look for cfitsio include and cfitsio library
28dnl if installed in /usr/local, nothing to do
29
30AC_MSG_CHECKING("for cfitsio lib")
31MACHDIR=`uname`-$CXX
32if test -f $ARCHBASEREP/$MACHDIR/Libs/libcfitsio.a; then
33 cfitslibdir='-L$(ARCHBASEREP)/$(MACHDIR)/Libs'
34elif test -f $CFITSIOLIBDIR/$MACHDIR/Libs/libcfitsio.a; then
35 cfitslibdir='-L$(CFITSIOLIBDIR)/$(MACHDIR)/Libs'
36elif test -f $CFITSIOLIBDIR/$MACHDIR/libcfitsio.a; then
37 cfitslibdir='-L$(CFITSIOLIBDIR)/$(MACHDIR)'
38elif test -f $CFITSIOLIBDIR/`uname`/lib/libcfitsio.a; then
39 cfitslibdir='-L$(CFITSIOLIBDIR)/'`uname`/lib
40elif test -f $CFITSIOLIBDIR/`uname`/libcfitsio.a; then
41 cfitslibdir='-L$(CFITSIOLIBDIR)/'`uname`
42elif test -f $CFITSIOLIBDIR/libcfitsio.a; then
43 cfitslibdir='-L$(CFITSIOLIBDIR)'
44elif test -f $CFITSIODIR/libcfitsio.a; then
45 cfitslibdir='-L$(CFITSIODIR)'
46elif test -f /usr/local/lib/libcfitsio.a; then
47 cfitslibdir=""
48else
49 AC_MSG_ERROR("Cannot find cfitsio library")
50fi
51AC_MSG_RESULT($cfitslibdir)
52AC_SUBST(cfitslibdir)
53
54AC_MSG_CHECKING("for cfitsio includes")
55if test -f $CFITSIODIR/fitsio.h; then
56 cfitsincdir='-I$(CFITSIODIR)'
57elif test -f /usr/local/include/fitsio.h; then
58 cfitsincdir=""
59else
60 AC_MSG_ERROR("Cannot find cfitsio include fitsio.h")
61fi
62AC_MSG_RESULT($cfitsincdir)
63AC_SUBST(cfitsincdir)
64
65dnl Checks for libraries.
66dnl AC_CHECK_LIB(cfitsio, ffread,,AC_MSG_ERROR("Cannot find cfitsio library"))
67AC_CHECK_LIB(m, sin)
68
69AC_MSG_CHECKING("for source files in distribution")
70srcfiles=""
71curd=`pwd`
72cd $srcdir
73for n in *.cc; do
74 grep -q 'main(.*)' $n || srcfiles="$srcfiles $n"
75done
76cd $curd
77AC_SUBST(srcfiles)
78AC_MSG_RESULT("done")
79
80dnl Checks for header files.
81AC_HEADER_STDC
82
83AC_OUTPUT(Makefile)
Note: See TracBrowser for help on using the repository browser.