summaryrefslogtreecommitdiff
path: root/configure.ac
diff options
context:
space:
mode:
authorDavid Thompson <dthompson2@worcester.edu>2015-11-11 21:43:07 -0500
committerDavid Thompson <dthompson2@worcester.edu>2015-11-11 21:49:25 -0500
commitc3b48241ff333f453fd3dd1c9db50396d76376cc (patch)
tree1707de72e5ebcf0e085da07de61028b212d590a4 /configure.ac
parent52792b80c9c41efcd354768ab49526a6de6a218e (diff)
configure: Add FreeImage and GSL prefix/libdir options.
Diffstat (limited to 'configure.ac')
-rw-r--r--configure.ac46
1 files changed, 46 insertions, 0 deletions
diff --git a/configure.ac b/configure.ac
index 1dfa107..0b2ba97 100644
--- a/configure.ac
+++ b/configure.ac
@@ -23,6 +23,52 @@ dnl test instead.
AC_CHECK_LIB([freeimage], [FreeImage_GetVersion],,
[AC_MSG_ERROR([freeimage not found.])])
+LIBFREEIMAGE="libfreeimage"
+LIBFREEIMAGE_LIBDIR="no"
+LIBFREEIMAGE_PREFIX="no"
+
+AC_ARG_WITH([libfreeimage-prefix],
+ [AS_HELP_STRING([--with-libfreeimage-prefix=DIR], [search for FreeImage in DIR])],
+ [case "$withval" in
+ yes|no)
+ ;;
+ *)
+ LIBFREEIMAGE="$withval/lib/libfreeimage"
+ LIBFREEIMAGE_PREFIX="$withval"
+ LIBFREEIMAGE_LIBDIR="$withval/lib"
+ ;;
+ esac])
+
+dnl Library name suitable for `dynamic-link'.
+AC_MSG_CHECKING([for libfreeimage shared library name])
+AC_MSG_RESULT([$LIBFREEIMAGE])
+AC_SUBST([LIBFREEIMAGE])
+AC_SUBST([LIBFREEIMAGE_PREFIX])
+AC_SUBST([LIBFREEIMAGE_LIBDIR])
+
+LIBGSLCBLAS="libgslcblas"
+LIBGSLCBLAS_LIBDIR="no"
+LIBGSLCBLAS_PREFIX="no"
+
+AC_ARG_WITH([libgslcblas-prefix],
+ [AS_HELP_STRING([--with-libgslcblas-prefix=DIR], [search for GSL CBLAS in DIR])],
+ [case "$withval" in
+ yes|no)
+ ;;
+ *)
+ LIBGSLCBLAS="$withval/lib/libgslcblas"
+ LIBGSLCBLAS_PREFIX="$withval"
+ LIBGSLCBLAS_LIBDIR="$withval/lib"
+ ;;
+ esac])
+
+dnl Library name suitable for `dynamic-link'.
+AC_MSG_CHECKING([for libgslcblas shared library name])
+AC_MSG_RESULT([$LIBGSLCBLAS])
+AC_SUBST([LIBGSLCBLAS])
+AC_SUBST([LIBGSLCBLAS_PREFIX])
+AC_SUBST([LIBGSLCBLAS_LIBDIR])
+
PKG_CHECK_MODULES([GSL], [gsl])
AC_OUTPUT