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

Last change on this file since 1668 was 1663, checked in by aubourg, 24 years ago

darwin

File size: 2.2 KB
Line 
1dnl Process this file with autoconf to produce a configure script.
2AC_INIT(kernel/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_CC
19AC_PROG_CXX
20
21AC_CHECK_SIZEOF(short)
22AC_CHECK_SIZEOF(int)
23AC_CHECK_SIZEOF(long)
24AC_CHECK_SIZEOF(long long)
25AC_CHECK_SIZEOF(float)
26AC_CHECK_SIZEOF(double)
27AC_CHECK_SIZEOF(long double)
28
29dnl look for cfitsio include and cfitsio library
30dnl if installed in /usr/local, nothing to do
31
32AC_MSG_CHECKING("for cfitsio lib")
33MACHDIR=`uname`-$CXX
34if test -f $ARCHBASEREP/$MACHDIR/Libs/libcfitsio.a; then
35 cfitslibdir='-L$(ARCHBASEREP)/$(MACHDIR)/Libs'
36elif test -f $CFITSIOLIBDIR/$MACHDIR/Libs/libcfitsio.a; then
37 cfitslibdir='-L$(CFITSIOLIBDIR)/$(MACHDIR)/Libs'
38elif test -f $CFITSIOLIBDIR/$MACHDIR/libcfitsio.a; then
39 cfitslibdir='-L$(CFITSIOLIBDIR)/$(MACHDIR)'
40elif test -f $CFITSIOLIBDIR/`uname`/lib/libcfitsio.a; then
41 cfitslibdir='-L$(CFITSIOLIBDIR)/'`uname`/lib
42elif test -f $CFITSIOLIBDIR/`uname`/libcfitsio.a; then
43 cfitslibdir='-L$(CFITSIOLIBDIR)/'`uname`
44elif test -f $CFITSIOLIBDIR/libcfitsio.a; then
45 cfitslibdir='-L$(CFITSIOLIBDIR)'
46elif test -f $CFITSIODIR/libcfitsio.a; then
47 cfitslibdir='-L$(CFITSIODIR)'
48elif test -f /usr/local/lib/libcfitsio.a; then
49 cfitslibdir=""
50else
51 AC_MSG_ERROR("Cannot find cfitsio library")
52fi
53AC_MSG_RESULT($cfitslibdir)
54AC_SUBST(cfitslibdir)
55
56AC_MSG_CHECKING("for cfitsio includes")
57if test -f $CFITSIODIR/fitsio.h; then
58 cfitsincdir='-I$(CFITSIODIR)'
59elif test -f /usr/local/include/fitsio.h; then
60 cfitsincdir=""
61else
62 AC_MSG_ERROR("Cannot find cfitsio include fitsio.h")
63fi
64AC_MSG_RESULT($cfitsincdir)
65AC_SUBST(cfitsincdir)
66
67dnl Checks for libraries.
68dnl AC_CHECK_LIB(cfitsio, ffread,,AC_MSG_ERROR("Cannot find cfitsio library"))
69AC_CHECK_LIB(m, sin)
70
71dnl Checks for header files.
72AC_HEADER_STDC
73AC_CHECK_HEADERS(values.h stdint.h)
74
75outfiles="Makefile kernel/Makefile processors/Makefile pipes/Makefile"
76if [[ $use_sophya = 1 ]]; then
77 outfiles="$outfiles sophya/Makefile"
78fi
79
80AC_OUTPUT($outfiles)
81
Note: See TracBrowser for help on using the repository browser.