configure.ac 3.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105
  1. #----------------------------------------------------------------
  2. #
  3. # configure.ac
  4. #
  5. # Autoconf source file for Boundary Element MMTL (bem).
  6. # This file, along with aclocal, autoconf, Makefile.am,
  7. # and automake can produce a highly functional configuration
  8. # script and Makefile.
  9. #
  10. # Sharon Zahn, Bob Techentin
  11. # October 3, 2002
  12. #
  13. # Copyright 2002-2004 Mayo Foundation. All Rights Reserved
  14. # $Id: configure.ac,v 1.6 2004/06/29 14:06:43 techenti Exp $
  15. #
  16. #----------------------------------------------------------------
  17. #----------------------------------------------------------------
  18. # Declare the package name and version.
  19. # All the bouquets and brickbats go to Sharon. :-)
  20. #----------------------------------------------------------------
  21. AC_INIT(CALCRL, 1.0, zahn.sharon@mayo.edu)
  22. #----------------------------------------------------------------
  23. # Give autoconf a point of reference, and tell it that
  24. # we're going to use automake later.
  25. #----------------------------------------------------------------
  26. AC_CONFIG_SRCDIR(src/calcRL.cpp)
  27. AM_INIT_AUTOMAKE
  28. #----------------------------------------------------------------
  29. # Check platform name so we can specify particular
  30. # compilers and switches that we like.
  31. #----------------------------------------------------------------
  32. AC_CANONICAL_HOST
  33. case "${host}" in
  34. *hpux11*)
  35. CC=cc
  36. CXX=aCC
  37. CXXFLAGS="+O3 -DFORTRAN_UNDERBARS"
  38. F77=f90
  39. FFLAGS="+ppu -O2"
  40. ;;
  41. *cygwin*)
  42. # On Windows using Cygwin
  43. # Use the GNU compilers, but not the cygwin.dll,
  44. # which would infect our code with the GPL.
  45. # Note that we must also specify the gcc compiler,
  46. # as the -mno-cygwin switch makes it behave differently
  47. # for many of the configure tests.
  48. CC="gcc -mno-cygwin"
  49. CXX="g++ -mno-cygwin"
  50. F77="g77 -mno-cygwin"
  51. AM_CXXFLAGS="-DFORTRAN_UNDERBARS"
  52. ;;
  53. esac
  54. #----------------------------------------------------------------
  55. # Portabiliy checks were, for the most part, generated by
  56. # an initial 'autoscan' of the source code. The configure
  57. # script checks the system for features and generates the
  58. # compile commands with flags like -DHAVE_STDLIB_H=1, but
  59. # the nmmtl source code does not (as of this writing) take
  60. # advantage of those flags.
  61. #----------------------------------------------------------------
  62. #----------------------------------------------------------------
  63. # Checks for programs.
  64. #----------------------------------------------------------------
  65. AC_PROG_CXX
  66. AC_PROG_CC
  67. AC_PROG_F77
  68. #----------------------------------------------------------------
  69. # Checks for header files.
  70. #----------------------------------------------------------------
  71. AC_HEADER_STDC
  72. AC_CHECK_HEADERS([fcntl.h float.h limits.h malloc.h stddef.h stdlib.h string.h sys/times.h unistd.h])
  73. #----------------------------------------------------------------
  74. # Checks for typedefs, structures, and compiler characteristics.
  75. #----------------------------------------------------------------
  76. AC_C_CONST
  77. AC_TYPE_UID_T
  78. AC_C_INLINE
  79. AC_TYPE_MODE_T
  80. AC_TYPE_SIZE_T
  81. AC_STRUCT_TM
  82. #----------------------------------------------------------------
  83. # Checks for library functions.
  84. #----------------------------------------------------------------
  85. AC_FUNC_GETGROUPS
  86. AC_FUNC_MALLOC
  87. AC_FUNC_STAT
  88. AC_FUNC_STRFTIME
  89. AC_FUNC_VPRINTF
  90. AC_CHECK_FUNCS([getcwd pow rmdir sqrt strchr strdup strrchr strstr])
  91. AC_CONFIG_FILES([Makefile])
  92. AC_OUTPUT