dnl Process this file with autoconf to produce a configure script. AC_REVISION($Revision: 1.13 $) AC_INIT(RNAforester,1.5,mhoechsm@techfak.uni-bielefeld.de,RNAforester) AC_PREREQ(2.53) AM_INIT_AUTOMAKE dnl create a config.h file (Automake will add -DHAVE_CONFIG_H) AM_CONFIG_HEADER(config.h) dnl Checks for programs. AC_PROG_CXX AC_PROG_CC AC_LANG(C++) dnl Checks for libraries. dnl AC_CHECK_LIB(g2,g2_open_vd,,AC_MSG_WARN(Compiling without support for graphical output. Install the g2 library that comes with the RNAforester distribution or download the latest version at http://g2.sourceforge.net/)) AC_ARG_WITH(ViennaRNA-lib, [--with-ViennaRNA-lib where to search for libRNA.a], LIBS=["$withval/libRNA.a ${LIBS}"] && AC_DEFINE(HAVE_LIBRNA,1,Define to 1 if you have the `RNA' library (-lRNA).), LDFLAGS="-L../../lib ${LDFLAGS}" if test -r "../lib/fold.c"; then AC_DEFINE(HAVE_LIBRNA) LIBS=["-lRNA ${LIBS}"] AC_MSG_RESULT([using (to be built) libRNA.a in ../lib]) fi ) dnl AC_CHECK_LIB(RNA, fold,,AC_MSG_WARN(Vienna RNA library libRNA.a was not found. RNAforester will be compiled without the structure prediction option -p and graphical output)) save_CPPFLAGS=$CPPFLAGS CPPFLAGS=["-Ig2-0.70/src/ -Lg2-0.70/ ${CPPFLAGS}"] AC_CHECK_LIB(gd,gdImageLine,,) dnl Checks for header files. AC_HEADER_STDC AC_CHECK_HEADER(g2.h,AC_DEFINE(HAVE_LIBG2,1,Define to 1 if you have the `g2' library (-lg2).),AC_MSG_WARN(Compiling without support for graphical output. Install the g2 library that comes with the RNAforester distribution or download the latest version at http://g2.sourceforge.net/)) dnl AC_CHECK_HEADER(g2_PS.h,,AC_MSG_WARN(Compiling without support for graphical output. Install the g2 library that comes with the RNAforester distribution or download the latest version at http://g2.sourceforge.net/)) dnl Checks for typedefs, structures, and compiler characteristics. AC_C_CONST AC_C_INLINE AC_TYPE_SIZE_T CPPFLAGS="$save_CPPFLAGS -I../g2-0.70/include/" LDFLAGS=["-L../g2-0.70 ${LDFLAGS}"] if ${HAVE_LIBG2}; then LIBS=["-lg2 ${LIBS}"] fi AC_SUBST(CXX) AC_SUBST(CPPFLAGS) AC_SUBST(LIBS) AC_SUBST(LDFLAGS) dnl Checks for library functions. AC_CONFIG_SUBDIRS(g2-0.70) AC_OUTPUT(Makefile src/Makefile man/Makefile)