[GIT] ppl/ppl(devel): Improved support for cross-compilation.

Module: ppl/ppl Branch: devel Commit: c72beb5765670121435d230a9b31d3f6a8c49d09 URL: http://www.cs.unipr.it/git/gitweb.cgi?p=ppl/ppl.git;a=commit;h=c72beb5765670...
Author: Roberto Bagnara roberto.bagnara@bugseng.com Date: Sun Nov 1 16:02:59 2020 +0100
Improved support for cross-compilation.
---
m4/ac_check_swi_prolog.m4 | 20 +++++++++++++++----- 1 file changed, 15 insertions(+), 5 deletions(-)
diff --git a/m4/ac_check_swi_prolog.m4 b/m4/ac_check_swi_prolog.m4 index 04c8309ff..a4b173e9b 100644 --- a/m4/ac_check_swi_prolog.m4 +++ b/m4/ac_check_swi_prolog.m4 @@ -45,11 +45,21 @@ then fi if test x$swi_prolog != x then - swi_prolog_base=`$swi_prolog --dump-runtime-variables | grep PLBASE= | sed 's/PLBASE="([[a-z]]:){0,1}(.*)";.*/\2/'` - swi_prolog_version=`$swi_prolog --dump-runtime-variables | grep PLVERSION= | sed 's/PLVERSION="(.*)";.*/\1/'` - swi_prolog_arch=`$swi_prolog --dump-runtime-variables | grep PLARCH= | sed 's/PLARCH="(.*)";.*/\1/'` - swi_prolog_libs=`$swi_prolog --dump-runtime-variables | grep PLLIBS= | sed 's/PLLIBS="(.*)";.*/\1/'` - swi_prolog_lib=`$swi_prolog --dump-runtime-variables | grep PLLIB= | sed 's/PLLIB="(.*)";.*/\1/'` + case $host_os in + *mingw*) + if test "$cross_compiling" = yes + then + EXEINTERPRETER=wine + fi + ;; + *) + ;; + esac + swi_prolog_base=`$EXEINTERPRETER $swi_prolog --dump-runtime-variables | grep PLBASE= | sed 's/PLBASE="([[a-z]]:){0,1}(.*)";.*/\2/'` + swi_prolog_version=`$EXEINTERPRETER $swi_prolog --dump-runtime-variables | grep PLVERSION= | sed 's/PLVERSION="(.*)";.*/\1/'` + swi_prolog_arch=`$EXEINTERPRETER $swi_prolog --dump-runtime-variables | grep PLARCH= | sed 's/PLARCH="(.*)";.*/\1/'` + swi_prolog_libs=`$EXEINTERPRETER $swi_prolog --dump-runtime-variables | grep PLLIBS= | sed 's/PLLIBS="(.*)";.*/\1/'` + swi_prolog_lib=`$EXEINTERPRETER $swi_prolog --dump-runtime-variables | grep PLLIB= | sed 's/PLLIB="(.*)";.*/\1/'`
dnl Additional version checks could be inserted here, if necessary.
participants (1)
-
Roberto Bagnara