[Getdata-commits] SF.net SVN: getdata:[896] trunk/getdata
Scientific Database Format
Brought to you by:
ketiltrout
|
From: <ket...@us...> - 2014-05-05 21:17:06
|
Revision: 896
http://sourceforge.net/p/getdata/code/896
Author: ketiltrout
Date: 2014-05-05 21:16:59 +0000 (Mon, 05 May 2014)
Log Message:
-----------
Make gd_encoding_support() work with modules. Do some sorting of configure.ac.
Modified Paths:
--------------
trunk/getdata/ChangeLog
trunk/getdata/configure.ac
trunk/getdata/src/encoding.c
Modified: trunk/getdata/ChangeLog
===================================================================
--- trunk/getdata/ChangeLog 2014-05-05 20:38:45 UTC (rev 895)
+++ trunk/getdata/ChangeLog 2014-05-05 21:16:59 UTC (rev 896)
@@ -1,3 +1,6 @@
+2014-05-05 D. V. Wiebe <ge...@ke...> svn:896
+ * src/encoding.c (gd_encoding_support): Call _GD_InitialiseFramework().
+
2014-05-05 D. V. Wiebe <ge...@ke...> svn:895
* src/getdata.h.in: Remove GD_MAX_CARRAY_LENGTH.
* src/add.c (_GD_Add) src/mod.c (_GD_Change) src/parse.c (_GD_ParseArray):
Modified: trunk/getdata/configure.ac
===================================================================
--- trunk/getdata/configure.ac 2014-05-05 20:38:45 UTC (rev 895)
+++ trunk/getdata/configure.ac 2014-05-05 21:16:59 UTC (rev 896)
@@ -183,8 +183,8 @@
dnl Fortran 77 bindings
AC_ARG_ENABLE(fortran, AS_HELP_STRING([--disable-fortran],
- [don't build the Fortran 77 bindings (libfgetdata) nor the
- Fortran 95 bindings (libf95getdata)]),
+ [don't build the Fortran 77 bindings (libfgetdata) nor ]dnl'
+ [the Fortran 95 bindings (libf95getdata)]),
[
case "${enableval}" in
no) make_f77bindings="no" ;;
@@ -194,7 +194,7 @@
dnl Fortran 95 bindings
AC_ARG_ENABLE(fortran95, AS_HELP_STRING([--disable-fortran95],
- [don't build the Fortran 95 bindings (libf95getdata)]),
+ [don't build the Fortran 95 bindings (libf95getdata)]),dnl'
[
case "${enableval}" in
no) make_f95bindings="no" ;;
@@ -212,29 +212,10 @@
AC_MSG_CHECKING([whether to include the Fortran 77 bindings])
AC_MSG_RESULT([$make_f77bindings])
-dnl DL library path munging for test suite
-case "${host}" in
- *-apple-darwin*) DL_LIBRARY_PATH="DYLD_LIBRARY_PATH" ;;
- *) DL_LIBRARY_PATH="LD_LIBRARY_PATH" ;;
-esac
-AC_SUBST([DL_LIBRARY_PATH])
-
-dnl Python bindings
-AC_ARG_ENABLE(python, AS_HELP_STRING([--disable-python],
- [don't build the Python bindings (pygetdata)]),
- [
- case "${enableval}" in
- no) make_pybindings="no" ;;
- *) make_pybindings="yes" ;;
- esac
- ])
-
-AC_MSG_CHECKING([whether to include the Python bindings])
-AC_MSG_RESULT([$make_pybindings])
-
dnl IDL bindings
AC_ARG_ENABLE(idl, AS_HELP_STRING([--disable-idl],
- [don't build the Interactive Data Language (IDL) bindings (IDL_GetData)]),
+ [don't build the Interactive Data Language (IDL) bindings ]dnl'
+ [(IDL_GetData)]),
[
case "${enableval}" in
no) make_idlbindings="no" ;;
@@ -245,6 +226,19 @@
AC_MSG_CHECKING([whether to include the IDL bindings])
AC_MSG_RESULT([$make_idlbindings])
+dnl MATLAB bindings
+AC_ARG_ENABLE(matlab, AS_HELP_STRING([--disable-matlab],
+ [don't build the MATLAB bindings]),dnl'
+ [
+ case "${enableval}" in
+ no) make_matlabbindings="no" ;;
+ *) make_matlabbindings="yes" ;;
+ esac
+ ])
+
+AC_MSG_CHECKING([whether to include the MATLAB bindings])
+AC_MSG_RESULT([$make_matlabbindings])
+
dnl Perl bindings
AC_ARG_ENABLE(perl, AS_HELP_STRING([--disable-perl],
[don't build the Perl bindings (GetData)]),dnl'
@@ -258,19 +252,6 @@
AC_MSG_CHECKING([whether to include the Perl bindings])
AC_MSG_RESULT([$make_perlbindings])
-dnl MATLAB bindings
-AC_ARG_ENABLE(matlab, AS_HELP_STRING([--disable-matlab],
- [don't build the MATLAB bindings]),dnl'
- [
- case "${enableval}" in
- no) make_matlabbindings="no" ;;
- *) make_matlabbindings="yes" ;;
- esac
- ])
-
-AC_MSG_CHECKING([whether to include the MATLAB bindings])
-AC_MSG_RESULT([$make_matlabbindings])
-
dnl PHP bindings
AC_ARG_ENABLE(php, AS_HELP_STRING([--disable-php],
[don't build the PHP bindings]),dnl'
@@ -281,6 +262,19 @@
esac
])
+dnl Python bindings
+AC_ARG_ENABLE(python, AS_HELP_STRING([--disable-python],
+ [don't build the Python bindings (pygetdata)]),dnl'
+ [
+ case "${enableval}" in
+ no) make_pybindings="no" ;;
+ *) make_pybindings="yes" ;;
+ esac
+ ])
+
+AC_MSG_CHECKING([whether to include the Python bindings])
+AC_MSG_RESULT([$make_pybindings])
+
AC_MSG_CHECKING([whether to include the PHP bindings])
AC_MSG_RESULT([$make_phpbindings])
@@ -451,6 +445,13 @@
AC_MSG_RESULT([yes])
fi
+dnl DL library path munging for test suite
+case "${host}" in
+ *-apple-darwin*) DL_LIBRARY_PATH="DYLD_LIBRARY_PATH" ;;
+ *) DL_LIBRARY_PATH="LD_LIBRARY_PATH" ;;
+esac
+AC_SUBST([DL_LIBRARY_PATH])
+
echo
echo "*** Checking C compiler characteristics"
echo
@@ -865,48 +866,6 @@
#endif
])
-dnl python
-if test "x$make_pybindings" = "xyes"; then
- echo
- echo "*** Configuring python bindings"
- echo
- GD_PYTHON([2.3])
- have_numpy="no"
- if test "x$have_python" = "xno"; then
- make_pybindings="no"
- else
- AC_MSG_CHECKING([for NumPy])
- cat > conftest.py << EOF
-import sys
-try:
- import numpy
-except ImportError:
- sys.exit(1)
-EOF
- if $PYTHON conftest.py > /dev/null 2>&1; then
- have_numpy="yes"
- fi
- AC_MSG_RESULT([$have_numpy])
- fi
- if test "x$have_numpy" = "xyes"; then
- AC_MSG_CHECKING([NumPy includes])
- NUMPY_CPPFLAGS=-I`$PYTHON -c "import numpy; print numpy.get_include()"`
- AC_MSG_RESULT([$NUMPY_CPPFLAGS])
-
- saved_cppflags=$CPPFLAGS
- CPPFLAGS="${CPPFLAGS} ${PYTHON_CPPFLAGS} ${NUMPY_CPPFLAGS}"
- AC_CHECK_HEADERS([numpy/arrayobject.h],,[have_numpy="no"],[
-#include<Python.h>
-])
- CPPFLAGS=$saved_cppflags
- fi
-
- if test "x$have_numpy" = "xyes"; then
- AC_DEFINE([USE_NUMPY], [],
- [ Define to enable NumPy support in the Python bindings ])
- fi
-fi
-
dnl idl
if test "x$make_idlbindings" = "xyes"; then
echo
@@ -927,6 +886,17 @@
fi
fi
+dnl matlab
+if test "x$make_matlabbindings" = "xyes"; then
+ echo
+ echo "*** Configuring MATLAB bindings"
+ echo
+ GD_MATLAB
+ if test "x$have_matlab" = "xno"; then
+ make_matlabbindings=no
+ fi
+fi
+
dnl perl
if test "x$make_perlbindings" = "xyes"; then
echo
@@ -938,17 +908,6 @@
fi
fi
-dnl matlab
-if test "x$make_matlabbindings" = "xyes"; then
- echo
- echo "*** Configuring MATLAB bindings"
- echo
- GD_MATLAB
- if test "x$have_matlab" = "xno"; then
- make_matlabbindings=no
- fi
-fi
-
dnl php
if test "x$make_phpbindings" = "xyes"; then
echo
@@ -969,6 +928,48 @@
fi
fi
+dnl python
+if test "x$make_pybindings" = "xyes"; then
+ echo
+ echo "*** Configuring python bindings"
+ echo
+ GD_PYTHON([2.3])
+ have_numpy="no"
+ if test "x$have_python" = "xno"; then
+ make_pybindings="no"
+ else
+ AC_MSG_CHECKING([for NumPy])
+ cat > conftest.py << EOF
+import sys
+try:
+ import numpy
+except ImportError:
+ sys.exit(1)
+EOF
+ if $PYTHON conftest.py > /dev/null 2>&1; then
+ have_numpy="yes"
+ fi
+ AC_MSG_RESULT([$have_numpy])
+ fi
+ if test "x$have_numpy" = "xyes"; then
+ AC_MSG_CHECKING([NumPy includes])
+ NUMPY_CPPFLAGS=-I`$PYTHON -c "import numpy; print numpy.get_include()"`
+ AC_MSG_RESULT([$NUMPY_CPPFLAGS])
+
+ saved_cppflags=$CPPFLAGS
+ CPPFLAGS="${CPPFLAGS} ${PYTHON_CPPFLAGS} ${NUMPY_CPPFLAGS}"
+ AC_CHECK_HEADERS([numpy/arrayobject.h],,[have_numpy="no"],[
+#include<Python.h>
+])
+ CPPFLAGS=$saved_cppflags
+ fi
+
+ if test "x$have_numpy" = "xyes"; then
+ AC_DEFINE([USE_NUMPY], [],
+ [ Define to enable NumPy support in the Python bindings ])
+ fi
+fi
+
dnl external encodings
GD_CHECK_ENCODING([bzip2],[bz2],[BZ2_bzReadOpen],[bzlib.h],[bzip2],[bunzip2],[])
GD_CHECK_ENCODING([gzip],[z],[gzopen],[zlib.h],[gzip],[gunzip],[])
@@ -980,8 +981,8 @@
dnl zzslim hackery -- there's no easy way to check whether slim supports zzip
AC_ARG_ENABLE(zzslim, AS_HELP_STRING([--enable-zzslim],
[skip probing for zzslim required features and enable the zzslim
- encoding. The default is to autodetect support. Note: zzslim
- encoding support requires both slim and zzip encoding support.]),
+ encoding. Note: zzslim encoding support requires both slim and
+ zzip encoding support. [default: autodetect]]),
[
case "${enableval}" in
no) zzslim_override="no" ;;
Modified: trunk/getdata/src/encoding.c
===================================================================
--- trunk/getdata/src/encoding.c 2014-05-05 20:38:45 UTC (rev 895)
+++ trunk/getdata/src/encoding.c 2014-05-05 21:16:59 UTC (rev 896)
@@ -933,6 +933,9 @@
dtrace("0x%lX", encoding);
+ /* spin up ltdl if needed */
+ _GD_InitialiseFramework();
+
/* make sure we have a valid encoding */
if (!_GD_EncodingUnderstood(encoding)) {
dreturn("%i", -1);
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|