Gitlab will migrate to a new storage backend starting 0300 UTC on 2020-04-04. We do not anticipate a maintenance window for this migration. Performance may be impacted over the weekend. Thanks for your patience.

Commit 05a81b82 authored by Karl Wette's avatar Karl Wette

SWIG: check version of SWIG used to generate source files

Original: bc694a8a031938e2707caf857b070af5b7381043
parent a84e518f
......@@ -2,7 +2,7 @@
# lalsuite_swig.m4 - SWIG configuration
# Author: Karl Wette, 2011--2014
# serial 71
# serial 72
# $0: check the version of $1, and store it in ${swig_version}
......@@ -150,6 +150,35 @@ AC_DEFUN([LALSUITE_USE_SWIG],[
# if SWIG bindings are not being generated, check that the SWIG version
# used to generate the bindings satisfies ${swig_min_version}
srcfile_swig_version_regex='s/^#.*define *SWIGVERSION *0x\([0-9][0-9]\)\([0-9][0-9]\)\([0-9][0-9]\).*$/\1 \2 \3/p'
AS_IF([test "${swig_generate}" != true],[
for file in ${swig_dep_files}; do
AS_IF([test "${swig_generate}" = true],[
test -f "swig/${file}" || echo '#empty' > "swig/${file}"
],[test -f "${depfile}"],[
srcfilename=`cat "${depfile}" | ${SED} -n -e '1p' | ${SED} -e 's/:.*$//'`
AS_IF([test -f "${srcfile}"],[
AC_MSG_CHECKING([if SWIG version ${swig_min_version} or later generated ${srcfilename}])
srcfile_swig_verargs=[`${SED} -n -e "${srcfile_swig_version_regex}" "${srcfile}"`]
srcfile_swig_version=[`printf '%d.%d.%d' ${srcfile_swig_verargs}`]
AC_MSG_RESULT([no (${srcfile_swig_version})])
AC_MSG_ERROR([SWIG version ${swig_min_version} or later is required ${swig_min_version_info}])
AC_MSG_RESULT([yes (${srcfile_swig_version})])
AC_MSG_ERROR([could not determine source file from ${depfile}])
AC_MSG_ERROR([${depfile} does not exist])
# extract -I and -D flags from LALSuite library preprocessor flags
for flag in ${CPPFLAGS}; do
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment