Home My Page Projects Code Snippets Project Openings diderot
Summary Activity Tracker Tasks SCM

SCM Repository

[diderot] View of /tests/configure.ac
ViewVC logotype

View of /tests/configure.ac

Parent Directory Parent Directory | Revision Log Revision Log


Revision 4718 - (download) (annotate)
Tue Oct 11 18:58:31 2016 UTC (2 years, 9 months ago) by glk
File size: 3153 byte(s)
removing this as something that can be configured, because the utility of the script depends on Teem being built with PNG support, but we do not do that because the diderot compiler does not link with libpng when creating stand-alone executables
dnl Process this file with autoconf to produce a configure script.
dnl
dnl This code is part of the Diderot Project (http://diderot-language.cs.uchicago.edu)
dnl
dnl COPYRIGHT (c) 2016 The University of Chicago
dnl All rights reserved.
dnl

AC_INIT(diderot-tests,0.1,)

AC_PREREQ(2.60)
AC_COPYRIGHT([[COPYRIGHT (c) 2016 The University of Chicago]])
AC_CONFIG_SRCDIR(rtest/tests/heron/heron.diderot)
AC_CONFIG_AUX_DIR(config)
AC_CONFIG_MACRO_DIR(config)

dnl check for standard programs
dnl
AC_PROG_INSTALL

dnl the path can be specified using "--with-teem=..." too
dnl
AC_ARG_WITH(teem,
  AC_HELP_STRING([--with-teem=<path>], [specify path to teem installation]),
  [ac_cv_use_teem=$withval], [ac_cv_use_teem=no])

if test x"$ac_cv_use_teem" = xno ; then
dnl search for Teem in some standard places
dnl
  AC_MSG_CHECKING([for teem])
  TEEM_DIR=none
  POSSIBLE_TEEM_DIRS="/usr/local/teem /usr/local"
  for dir in $POSSIBLE_TEEM_DIRS ; do
    if test -f $dir/include/teem/nrrd.h ; then
      TEEM_DIR=$dir
      AC_MSG_RESULT([$TEEM_DIR])
      break
    fi
  done
  if test $TEEM_DIR = none ; then
    AC_MSG_ERROR([unable to find teem; use --with-teem option to specify location])
  fi
else
  AC_MSG_CHECKING([path to teem ($ac_cv_use_teem)])
  case $ac_cv_use_teem in
    /*) ;;
    *) AC_MSG_ERROR([path to teem must be absolute]) ;;
  esac
  if test -x $ac_cv_use_teem ; then
    TEEM_DIR=$ac_cv_use_teem
    # check that TEEM_DIR actually points to something that looks like teem
    if test -f $TEEM_DIR/bin/unu ; then
      AC_MSG_RESULT([yes])
    else
      TEEM_DIR=none
      AC_MSG_RESULT([invalid path to teem])
    fi
  else
    TEEM_DIR=none
    AC_MSG_RESULT([invalid path to teem])
  fi
fi
if test x"$TEEM_DIR" = xnone ; then
  AC_MSG_ERROR([unable to find teem])
fi
TEEM_BIN=$TEEM_DIR/bin
AC_SUBST(TEEM_DIR)
AC_SUBST(TEEM_BIN)

dnl ******************** Diderot configuration ********************
dnl

dnl
dnl get the path to the diderot executable
dnl
AC_ARG_WITH(diderotc,
  AC_HELP_STRING([--with-diderotc=<path>], [specify path to Diderot compiler]),
  [ac_cv_use_diderotc=$withval], [ac_cv_use_diderotc=no])
if test x"$ac_cv_use_diderotc" = xno ; then
  DIDEROTC=none
else
  AC_MSG_CHECKING([path to diderotc ($ac_cv_use_diderotc)])
  case $ac_cv_use_diderotc in
    /*) DIDEROTC=$ac_cv_use_diderotc ;;
    *) DIDEROTC=$BMARKS_ROOT$ac_cv_use_diderotc ;;
  esac
  # check that diderotc exists and is executable
  if test -x $DIDEROTC ; then
    AC_MSG_RESULT([ okay])
  else
    DIDEROTC=none
    AC_MSG_RESULT([ invalid])
  fi
fi
if test x"$DIDEROTC" = xnone ; then
  AC_MSG_ERROR([unable to find diderotc; use --with-diderotc option to specify location])
fi
AC_SUBST(DIDEROTC)

dnl
dnl ******************** write output ********************
dnl

dnl
dnl generate script files with proper paths
dnl
dnl usage: MK_SCRIPT(<prefix-path>)
dnl
dnl generates <prefix-path>.sh from <prefix-path>_sh.in
dnl
AC_DEFUN([MK_SCRIPT], [
    AC_CONFIG_FILES([$1.sh:$1_sh.in], [chmod +x $1.sh])
  ])

MK_SCRIPT(rtest/scripts/run)
MK_SCRIPT(rtest/scripts/run-one)
MK_SCRIPT(vis15-bugs/sphere-snapbug)
MK_SCRIPT(vis15-bugs/halftone-bug2)

AC_OUTPUT


root@smlnj-gforge.cs.uchicago.edu
ViewVC Help
Powered by ViewVC 1.0.0