remove mentions to CMAKE_GENERATOR in test scripts

This commit is contained in:
Sébastien Loriot 2022-04-28 13:48:23 +02:00
parent 6bd510b943
commit 8e0ed828e7
14 changed files with 19 additions and 490 deletions

View File

@ -131,7 +131,7 @@ configure()
rm -rf CMakeCache.txt CMakeFiles/
if [ -f "$INIT_FILE" ]
then
if eval 'cmake --no-warn-unused-cli ${INIT_FILE:+"-C${INIT_FILE}"} "$CMAKE_GENERATOR" -DRUNNING_CGAL_AUTO_TEST=TRUE \
if eval 'cmake --no-warn-unused-cli ${INIT_FILE:+"-C${INIT_FILE}"} -DRUNNING_CGAL_AUTO_TEST=TRUE \
-DCGAL_DIR="$CGAL_DIR" \
-DCGAL_CXX_FLAGS:STRING="$CGAL_CXX_FLAGS $TESTSUITE_CXXFLAGS -I../../include" \
-DCGAL_EXE_LINKER_FLAGS="$CGAL_EXE_LINKER_FLAGS $TESTSUITE_LDFLAGS" \

View File

@ -26,7 +26,7 @@ configure()
{
echo "Configuring... "
if eval 'cmake --no-warn-unused-cli ${INIT_FILE:+"-C$INIT_FILE"} "$CMAKE_GENERATOR" -DRUNNING_CGAL_AUTO_TEST=TRUE \
if eval 'cmake --no-warn-unused-cli ${INIT_FILE:+"-C$INIT_FILE"} -DRUNNING_CGAL_AUTO_TEST=TRUE \
-DCGAL_DIR="$CGAL_DIR" \
.' ; then

View File

@ -92,17 +92,11 @@ if(LEDA_FOUND)
target_link_libraries(test_LEDA_IO ${LEDA_LIBRARIES})
endif()
if("$ENV{CMAKE_GENERATOR}" STREQUAL "")
set(GENERATOR )
else()
set(GENERATOR $ENV{CMAKE_GENERATOR})
endif()
if("$ENV{INIT_FILE}" STREQUAL "")
if("$ENV{INIT_FILE}" STREQUAL "")
set(INIT_FILE )
else()
else()
set(INIT_FILE -C$ENV{INIT_FILE})
endif()
endif()
function(CGAL_installation_test_find_package_version mode)
set(EXACT)
@ -131,7 +125,7 @@ function(CGAL_installation_test_find_package_version mode)
configure_file(test_find_package.cmake.in ${CMAKE_CURRENT_BINARY_DIR}/test_find_package_version_${mode}/CMakeLists.txt)
add_test(NAME test_find_package_version_${mode}
COMMAND ${CMAKE_COMMAND} ${GENERATOR} ${INIT_FILE} -DCMAKE_BUILD_TYPE=Release ${CMAKE_CURRENT_BINARY_DIR}/test_find_package_version_${mode}
COMMAND ${CMAKE_COMMAND} ${INIT_FILE} -DCMAKE_BUILD_TYPE=Release ${CMAKE_CURRENT_BINARY_DIR}/test_find_package_version_${mode}
)
cgal_setup_test_properties(test_find_package_version_${mode})
set_property(TEST test_find_package_version_${mode}
@ -215,7 +209,7 @@ add_test(NAME install_non_standard_cgal
#test CGAL_DIR=non standard place without cgal_qt5
get_filename_component(CGAL_DIR_CORRECT_PATH "${NON_STANDARD_INSTALL_PREFIX}/non_standard_install/lib/cmake/CGAL/CGALConfig.cmake" DIRECTORY)
add_test(NAME test_config_file_3
COMMAND ${CMAKE_COMMAND} ${GENERATOR} ${INIT_FILE} -DCMAKE_BUILD_TYPE=Release -DCGAL_DIR=${CGAL_DIR_CORRECT_PATH} -DCGAL_GIVEN_DIR=${CGAL_DIR_CORRECT_PATH}
COMMAND ${CMAKE_COMMAND} ${INIT_FILE} -DCMAKE_BUILD_TYPE=Release -DCGAL_DIR=${CGAL_DIR_CORRECT_PATH} -DCGAL_GIVEN_DIR=${CGAL_DIR_CORRECT_PATH}
"${CMAKE_BINARY_DIR}/test_config_file"
WORKING_DIRECTORY "${CMAKE_BINARY_DIR}/build-test_config_file_3")
list(APPEND test_config_lst "test_config_file_3")
@ -223,7 +217,7 @@ list(APPEND test_config_lst "test_config_file_3")
if(CGAL_Qt5_FOUND)
#configure cgal for a non standard install with qt5
add_test(NAME config_non_standard_cgal_qt5
COMMAND ${CMAKE_COMMAND} ${GENERATOR} ${INIT_FILE} -DCMAKE_BUILD_TYPE=Release -DCMAKE_INSTALL_PREFIX=${NON_STANDARD_INSTALL_PREFIX}/non_standard_install_qt5 -DCGAL_INSTALL_LIB_DIR=lib
COMMAND ${CMAKE_COMMAND} ${INIT_FILE} -DCMAKE_BUILD_TYPE=Release -DCMAKE_INSTALL_PREFIX=${NON_STANDARD_INSTALL_PREFIX}/non_standard_install_qt5 -DCGAL_INSTALL_LIB_DIR=lib
"${CGAL_SOURCE_DIR}"
WORKING_DIRECTORY "${NON_STANDARD_INSTALL_PREFIX}/non_standard_build_qt5")
#install cgal in the non standard place
@ -233,7 +227,7 @@ if(CGAL_Qt5_FOUND)
#test CGAL_DIR=non standard place with cgal_qt5
get_filename_component(CGAL_DIR_CORRECT_PATH "${NON_STANDARD_INSTALL_PREFIX}/non_standard_install_qt5/lib/cmake/CGAL/CGALConfig.cmake" DIRECTORY)
add_test(NAME test_config_file_4
COMMAND ${CMAKE_COMMAND} ${GENERATOR} ${INIT_FILE} -DCMAKE_BUILD_TYPE=Release -DCGAL_DIR=${CGAL_DIR_CORRECT_PATH} -DCGAL_GIVEN_DIR=${CGAL_DIR_CORRECT_PATH}
COMMAND ${CMAKE_COMMAND} ${INIT_FILE} -DCMAKE_BUILD_TYPE=Release -DCGAL_DIR=${CGAL_DIR_CORRECT_PATH} -DCGAL_GIVEN_DIR=${CGAL_DIR_CORRECT_PATH}
"${CMAKE_BINARY_DIR}/test_config_file_qt5"
WORKING_DIRECTORY "${CMAKE_BINARY_DIR}/build-test_config_file_4")
list(APPEND test_config_lst "test_config_file_4")
@ -242,7 +236,7 @@ endif()#CGAL_Qt5_FOUND
#test CGAL_DIR=non standard build
get_filename_component(CGAL_DIR_CORRECT_PATH "${NON_STANDARD_INSTALL_PREFIX}/non_standard_build/CGALConfig.cmake" DIRECTORY)
add_test(NAME test_config_file_5
COMMAND ${CMAKE_COMMAND} ${GENERATOR} ${INIT_FILE} -DCMAKE_BUILD_TYPE=Release -DCGAL_DIR=${CGAL_DIR_CORRECT_PATH} -DCGAL_GIVEN_DIR=${CGAL_DIR_CORRECT_PATH}
COMMAND ${CMAKE_COMMAND} ${INIT_FILE} -DCMAKE_BUILD_TYPE=Release -DCGAL_DIR=${CGAL_DIR_CORRECT_PATH} -DCGAL_GIVEN_DIR=${CGAL_DIR_CORRECT_PATH}
"${CMAKE_BINARY_DIR}/test_config_file"
WORKING_DIRECTORY "${CMAKE_BINARY_DIR}/build-test_config_file_5")
list(APPEND test_config_lst "test_config_file_5")

View File

@ -26,7 +26,7 @@ touch ../$ERRORFILE
echo "Configuring... "
mkdir build_dir
cd build_dir
if eval 'cmake --no-warn-unused-cli ${INIT_FILE:+"-C${INIT_FILE}"} "$CMAKE_GENERATOR" -DRUNNING_CGAL_AUTO_TEST=TRUE \
if eval 'cmake --no-warn-unused-cli ${INIT_FILE:+"-C${INIT_FILE}"} -DRUNNING_CGAL_AUTO_TEST=TRUE \
-DCGAL_DIR="$CGAL_RELEASE_DIR" -DBUILD_TESTING=ON -DWITH_tests=ON \
..' ; then

View File

@ -26,7 +26,7 @@ configure()
{
echo "Configuring... "
if eval 'cmake --no-warn-unused-cli ${INIT_FILE:+"-C${INIT_FILE}"} "$CMAKE_GENERATOR" -DRUNNING_CGAL_AUTO_TEST=TRUE \
if eval 'cmake --no-warn-unused-cli ${INIT_FILE:+"-C${INIT_FILE}"} -DRUNNING_CGAL_AUTO_TEST=TRUE \
-DCGAL_DIR="$CGAL_DIR" \
.' ; then

View File

@ -1,211 +0,0 @@
#! /bin/sh
#
# This script is a modified version of cgal_test_with_cmake which:
# - is cross-platform Unix/make and Cygwin/VisualC++
# - concats all log files to cgal_test_with_cmake.log
# - does not clean up object files and executables if $NEED_CLEAN==n
#
# This is a script for the CGAL test suite. Such a script must obey
# the following rules:
#
# - the name of the script is cgal_test_with_cmake
# - for every target two one line messages are written to the file 'error.txt'
# the first one indicates if the compilation was successful
# the second one indicates if the execution was successful
# if one of the two was not successful, the line should start with 'ERROR:'
# - running the script should not require any user interaction
# - the script should clean up object files and executables
ERRORFILE=error.txt
DO_RUN=y
case "$CMAKE_GENERATOR" in
-GVisual* ) # if Visual Studio
MAKE_CMD="devenv.com *.sln /Build Release /Project"
MAKE_CLEAN_CMD="devenv.com *.sln /Clean Release"
;;
-GNMake* ) # if nmake
if [ -z "$MAKE_CMD" ]; then
MAKE_CMD="nmake"
fi
MAKE_CMD="${MAKE_CMD} -fMakefile"
MAKE_CLEAN_CMD="${MAKE_CMD} clean"
;;
* ) # if make
if [ -z "${MAKE_CMD}" ]; then
MAKE_CMD=make
fi
MAKE_CMD="${MAKE_CMD} -fMakefile"
MAKE_CLEAN_CMD="${MAKE_CMD} clean"
;;
esac
#---------------------------------------------------------------------#
# configure
#---------------------------------------------------------------------#
configure()
{
echo "Configuring... "
if eval 'cmake --no-warn-unused-cli ${INIT_FILE:+"-C${INIT_FILE}"} "$CMAKE_GENERATOR" -DRUNNING_CGAL_AUTO_TEST=TRUE \
-DCGAL_DIR="$CGAL_DIR" \
.' ; then
echo " successful configuration" >> $ERRORFILE
else
echo " ERROR: configuration" >> $ERRORFILE
fi
}
#---------------------------------------------------------------------#
# find_executable <target>
#---------------------------------------------------------------------#
find_executable()
{
PARAM_APPLICATION=""
[ -f ./release/$1.exe ] && PARAM_APPLICATION="./release/$1.exe"
[ -x ./$1 ] && PARAM_APPLICATION="./$1"
echo "$PARAM_APPLICATION"
}
#---------------------------------------------------------------------#
# can_compile <target>
#---------------------------------------------------------------------#
can_compile()
{
case "$CMAKE_GENERATOR" in
-GVisual* ) # if Visual Studio
if [ -f "$1.vcproj" ]; then
echo y
else
echo n
fi
;;
* ) # if make or nmake
if ${MAKE_CMD} help | grep "$1\$" > /dev/null; then
echo y
else
echo n
fi
;;
esac
}
#---------------------------------------------------------------------#
# compile_and_run <target>
#---------------------------------------------------------------------#
compile_and_run()
{
echo "Compiling $1 ... "
SUCCESS="y"
if eval '${MAKE_CMD} $1' ; then
echo " successful compilation of $1" >> $ERRORFILE
else
echo " ERROR: compilation of $1" >> $ERRORFILE
SUCCESS=""
fi
if [ -n "$DO_RUN" ] ; then
if [ -n "${SUCCESS}" ] ; then
OUTPUTFILE=ProgramOutput.$1.$PLATFORM
rm -f $OUTPUTFILE
COMMAND="`find_executable $1`"
if [ -f $1.cmd ] ; then
COMMAND="$COMMAND `cat $1.cmd`"
fi
if [ -f $1.cin ] ; then
COMMAND="cat $1.cin | $COMMAND"
fi
echo "Executing $1 ... "
echo
ulimit -t 3600 2> /dev/null
if eval $COMMAND > $OUTPUTFILE 2>&1 ; then
echo " successful execution of $1" >> $ERRORFILE
else
echo " ERROR: execution of $1" >> $ERRORFILE
fi
else
echo " ERROR: not executed $1" >> $ERRORFILE
fi
fi
}
#---------------------------------------------------------------------#
# catenate all logs in cgal_test_with_cmake.log
#---------------------------------------------------------------------#
[ -f cgal_test_with_cmake.log ] && mv -f cgal_test_with_cmake.log cgal_test_with_cmake.log.bak
echo "------------------------------------------------------------------" >> cgal_test_with_cmake.log
echo "- Compiler output from platform $PLATFORM" >> cgal_test_with_cmake.log
echo "------------------------------------------------------------------" >> cgal_test_with_cmake.log
echo >> cgal_test_with_cmake.log
(
#---------------------------------------------------------------------#
# remove the previous error file
#---------------------------------------------------------------------#
rm -f $ERRORFILE
touch $ERRORFILE
#---------------------------------------------------------------------#
# configure, compile and run the tests
#---------------------------------------------------------------------#
configure
if [ $# -ne 0 ] ; then
for file in $* ; do
compile_and_run $file
done
else
echo "Run all tests."
if [ `can_compile poisson_reconstruction` = "y" ]; then
compile_and_run poisson_reconstruction
[ -z "${NEED_CLEAN}" ] && NEED_CLEAN=y
fi
if [ `can_compile poisson_reconstruction_example` = "y" ]; then
compile_and_run poisson_reconstruction_example
[ -z "${NEED_CLEAN}" ] && NEED_CLEAN=y
fi
fi
#
# The clean target generated by CMake under cygwin
# always fails for some reason
#
if [ "${NEED_CLEAN}" = "y" ]; then
if ! ( uname | grep -q "CYGWIN" ) ; then
${MAKE_CLEAN_CMD}
fi
fi
) 2>&1 | tee -a cgal_test_with_cmake.log
echo >> cgal_test_with_cmake.log
#---------------------------------------------------------------------#
# catenate all logs in cgal_test_with_cmake.log
#---------------------------------------------------------------------#
if [ -n "$DO_RUN" ] ; then
for f in ProgramOutput.*.$PLATFORM ; do
echo "------------------------------------------------------------------" >> cgal_test_with_cmake.log
echo "- $f" >> cgal_test_with_cmake.log
echo "------------------------------------------------------------------" >> cgal_test_with_cmake.log
cat $f >> cgal_test_with_cmake.log
echo >> cgal_test_with_cmake.log
done
fi
echo "------------------------------------------------------------------" >> cgal_test_with_cmake.log
echo "- Error output from platform $PLATFORM" >> cgal_test_with_cmake.log
echo "------------------------------------------------------------------" >> cgal_test_with_cmake.log
echo >> cgal_test_with_cmake.log
cat $ERRORFILE >> cgal_test_with_cmake.log

View File

@ -1,207 +0,0 @@
#! /bin/sh
#
# This script is a modified version of cgal_test_with_cmake which:
# - is cross-platform Unix/make and Cygwin/VisualC++
# - concats all log files to cgal_test_with_cmake.log
# - does not clean up object files and executables if $NEED_CLEAN==n
#
# This is a script for the CGAL test suite. Such a script must obey
# the following rules:
#
# - the name of the script is cgal_test_with_cmake
# - for every target two one line messages are written to the file 'error.txt'
# the first one indicates if the compilation was successful
# the second one indicates if the execution was successful
# if one of the two was not successful, the line should start with 'ERROR:'
# - running the script should not require any user interaction
# - the script should clean up object files and executables
ERRORFILE=error.txt
DO_RUN=y
case "$CMAKE_GENERATOR" in
-GVisual* ) # if Visual Studio
MAKE_CMD="devenv.com *.sln /Build Release /Project"
MAKE_CLEAN_CMD="devenv.com *.sln /Clean Release"
;;
-GNMake* ) # if nmake
if [ -z "$MAKE_CMD" ]; then
MAKE_CMD="nmake"
fi
MAKE_CMD="${MAKE_CMD} -fMakefile"
MAKE_CLEAN_CMD="${MAKE_CMD} clean"
;;
* ) # if make
if [ -z "${MAKE_CMD}" ]; then
MAKE_CMD=make
fi
MAKE_CMD="${MAKE_CMD} -fMakefile"
MAKE_CLEAN_CMD="${MAKE_CMD} clean"
;;
esac
#---------------------------------------------------------------------#
# configure
#---------------------------------------------------------------------#
configure()
{
echo "Configuring... "
if eval 'cmake --no-warn-unused-cli ${INIT_FILE:+"-C${INIT_FILE}"} "$CMAKE_GENERATOR" -DRUNNING_CGAL_AUTO_TEST=TRUE \
-DCGAL_DIR="$CGAL_DIR" \
.' ; then
echo " successful configuration" >> $ERRORFILE
else
echo " ERROR: configuration" >> $ERRORFILE
fi
}
#---------------------------------------------------------------------#
# find_executable <target>
#---------------------------------------------------------------------#
find_executable()
{
PARAM_APPLICATION=""
[ -f ./release/$1.exe ] && PARAM_APPLICATION="./release/$1.exe"
[ -x ./$1 ] && PARAM_APPLICATION="./$1"
echo "$PARAM_APPLICATION"
}
#---------------------------------------------------------------------#
# can_compile <target>
#---------------------------------------------------------------------#
can_compile()
{
case "$CMAKE_GENERATOR" in
-GVisual* ) # if Visual Studio
if [ -f "$1.vcproj" ]; then
echo y
else
echo n
fi
;;
* ) # if make or nmake
if ${MAKE_CMD} help | grep "$1\$" > /dev/null; then
echo y
else
echo n
fi
;;
esac
}
#---------------------------------------------------------------------#
# compile_and_run <target>
#---------------------------------------------------------------------#
compile_and_run()
{
echo "Compiling $1 ... "
SUCCESS="y"
if eval '${MAKE_CMD} $1' ; then
echo " successful compilation of $1" >> $ERRORFILE
else
echo " ERROR: compilation of $1" >> $ERRORFILE
SUCCESS=""
fi
if [ -n "$DO_RUN" ] ; then
if [ -n "${SUCCESS}" ] ; then
OUTPUTFILE=ProgramOutput.$1.$PLATFORM
rm -f $OUTPUTFILE
COMMAND="`find_executable $1`"
if [ -f $1.cmd ] ; then
COMMAND="$COMMAND `cat $1.cmd`"
fi
if [ -f $1.cin ] ; then
COMMAND="cat $1.cin | $COMMAND"
fi
echo "Executing $1 ... "
echo
ulimit -t 3600 2> /dev/null
if eval $COMMAND > $OUTPUTFILE 2>&1 ; then
echo " successful execution of $1" >> $ERRORFILE
else
echo " ERROR: execution of $1" >> $ERRORFILE
fi
else
echo " ERROR: not executed $1" >> $ERRORFILE
fi
fi
}
#---------------------------------------------------------------------#
# catenate all logs in cgal_test_with_cmake.log
#---------------------------------------------------------------------#
[ -f cgal_test_with_cmake.log ] && mv -f cgal_test_with_cmake.log cgal_test_with_cmake.log.bak
echo "------------------------------------------------------------------" >> cgal_test_with_cmake.log
echo "- Compiler output from platform $PLATFORM" >> cgal_test_with_cmake.log
echo "------------------------------------------------------------------" >> cgal_test_with_cmake.log
echo >> cgal_test_with_cmake.log
(
#---------------------------------------------------------------------#
# remove the previous error file
#---------------------------------------------------------------------#
rm -f $ERRORFILE
touch $ERRORFILE
#---------------------------------------------------------------------#
# configure, compile and run the tests
#---------------------------------------------------------------------#
configure
if [ $# -ne 0 ] ; then
for file in $* ; do
compile_and_run $file
done
else
echo "Run all tests."
if [ `can_compile poisson_reconstruction_test` = "y" ]; then
compile_and_run poisson_reconstruction_test
[ -z "${NEED_CLEAN}" ] && NEED_CLEAN=y
fi
fi
#
# The clean target generated by CMake under cygwin
# always fails for some reason
#
if [ "${NEED_CLEAN}" = "y" ]; then
if ! ( uname | grep -q "CYGWIN" ) ; then
${MAKE_CLEAN_CMD}
fi
fi
) 2>&1 | tee -a cgal_test_with_cmake.log
echo >> cgal_test_with_cmake.log
#---------------------------------------------------------------------#
# catenate all logs in cgal_test_with_cmake.log
#---------------------------------------------------------------------#
if [ -n "$DO_RUN" ] ; then
for f in ProgramOutput.*.$PLATFORM ; do
echo "------------------------------------------------------------------" >> cgal_test_with_cmake.log
echo "- $f" >> cgal_test_with_cmake.log
echo "------------------------------------------------------------------" >> cgal_test_with_cmake.log
cat $f >> cgal_test_with_cmake.log
echo >> cgal_test_with_cmake.log
done
fi
echo "------------------------------------------------------------------" >> cgal_test_with_cmake.log
echo "- Error output from platform $PLATFORM" >> cgal_test_with_cmake.log
echo "------------------------------------------------------------------" >> cgal_test_with_cmake.log
echo >> cgal_test_with_cmake.log
cat $ERRORFILE >> cgal_test_with_cmake.log

View File

@ -26,7 +26,7 @@ configure()
{
echo "Configuring... "
if eval 'cmake --no-warn-unused-cli ${INIT_FILE:+"-C${INIT_FILE}"} "$CMAKE_GENERATOR" -DRUNNING_CGAL_AUTO_TEST=TRUE \
if eval 'cmake --no-warn-unused-cli ${INIT_FILE:+"-C${INIT_FILE}"} -DRUNNING_CGAL_AUTO_TEST=TRUE \
-DCGAL_DIR="$CGAL_DIR" \
.' ; then

View File

@ -80,7 +80,6 @@ REFERENCE_PLATFORMS_DIR="must_be_set_in_.autocgalrc"
ACTUAL_DIR=`pwd`
RSH="rsh"
NICE_OPTIONS="-19"
CMAKE_GENERATOR=""
USE_TARGZ="n"
USE_TARBZ="n"
PLATFORMS=""
@ -506,16 +505,12 @@ build_cgal_on_host()
cat >> "${CGAL_BINARY_DIR}/localbuildscript" <<EOF
CGAL_BINARY_DIR='${CGAL_BINARY_DIR}';
if [ -z "\$CMAKE_GENERATOR" ]; then
CMAKE_GENERATOR='${CMAKE_GENERATOR}';
fi
MAKE_CMD='${MAKE_CMD}';
export CMAKE_GENERATOR;
export MAKE_CMD;
export CGAL_BINARY_DIR;
cd '${CGAL_BINARY_DIR}';
cmake \${INIT_FILE:+"-C\${INIT_FILE}"} '${CMAKE_GENERATOR}' -DRUNNING_CGAL_AUTO_TEST=TRUE \\
cmake \${INIT_FILE:+"-C\${INIT_FILE}"} -DRUNNING_CGAL_AUTO_TEST=TRUE \\
VERBOSE=1 \\
../../..;
${MAKE_CMD} VERBOSE=ON -k -fMakefile ;
@ -604,14 +599,10 @@ else
fi
CGAL_TEST_HOST='${HOST}';
CGAL_TEST_PLATFORM='${PLATFORM}';
if [ -z "\$CMAKE_GENERATOR" ]; then
CMAKE_GENERATOR='${CMAKE_GENERATOR}';
fi
MAKE_CMD='${MAKE_CMD}'
export CGAL_TESTER CGAL_TESTER_NAME CGAL_TESTER_ADDRESS;
export CGAL_DIR;
export CGAL_TEST_HOST CGAL_TEST_PLATFORM;
export CMAKE_GENERATOR;
export MAKE_CMD;
EOF
@ -884,43 +875,6 @@ else
done
fi
# Detects cygwin
if uname | grep -q "CYGWIN"; then
JOM="`which jom`"
if [ -e "$JOM" ]; then
CMAKE_GENERATOR='-GNMake Makefiles JOM'
MAKE_CMD='jom'
log "${ACTUAL_LOGFILE}" "Cygwin detected, jom detected, using jom"
else
CMAKE_GENERATOR='-GNMake Makefiles'
MAKE_CMD='nmake'
log "${ACTUAL_LOGFILE}" "Cygwin detected, using nmake"
fi
IS_CYGWIN='y'
else
log "${ACTUAL_LOGFILE}" "Non-cygwin linux detected, using system make."
MAKE_CMD='make'
fi
if [ -z "$IS_CYGWIN" ]; then
# Acquire lock
lockfile -r 1 "$LOCK_FILE";
if [ ${?} != 0 ]; then
PID=`cat "$LOCK_FILE"`
if kill -0 "$PID"; then
log "${ACTUAL_LOGFILE}" "COULD NOT ACQUIRE LOCK! LOCKING PROCESS PID=$PID";
exit 1;
else
# The locking process has died without erasing the lock file
rm -f "$LOCK_FILE"
lockfile -r 1 "$LOCK_FILE";
if [ ${?} != 0 ]; then
log "${ACTUAL_LOGFILE}" "COULD NOT ACQUIRE LOCK!";
exit 1
fi
fi
fi
# Make that file writable (lockfile create read-only files
chmod u+w "$LOCK_FILE"
# Put the PID of current process in the lock file

View File

@ -80,7 +80,7 @@ configure()
{
echo "Configuring... "
if eval 'cmake ${INIT_FILE:+"-C${INIT_FILE}"} "$CMAKE_GENERATOR" -DRUNNING_CGAL_AUTO_TEST=TRUE \
if eval 'cmake ${INIT_FILE:+"-C${INIT_FILE}"} -DRUNNING_CGAL_AUTO_TEST=TRUE \
-DCGAL_DIR="$CGAL_DIR" \
--no-warn-unused-cli \
.' ; then

View File

@ -295,7 +295,6 @@ EOF
add_test( "$BASE" \${CMAKE_CTEST_COMMAND}
--build-and-test "\${CMAKE_CURRENT_SOURCE_DIR}"
"\${CMAKE_CURRENT_BINARY_DIR}"
--build-generator "\${CMAKE_GENERATOR}"
--build-makeprogram "\${CMAKE_MAKE_PROGRAM}"
--build-target $BASE
--build-no-clean

View File

@ -26,7 +26,7 @@ configure()
{
echo "Configuring... "
if eval 'cmake ${INIT_FILE:+"-C${INIT_FILE}"} "$CMAKE_GENERATOR" -DRUNNING_CGAL_AUTO_TEST=TRUE \
if eval 'cmake ${INIT_FILE:+"-C${INIT_FILE}"} -DRUNNING_CGAL_AUTO_TEST=TRUE \
-DCGAL_DIR="$CGAL_DIR" \
.' ; then

View File

@ -25,7 +25,7 @@ configure()
{
echo "Configuring... "
if eval 'cmake --no-warn-unused-cli ${INIT_FILE:+"-C${INIT_FILE}"} "$CMAKE_GENERATOR" -DRUNNING_CGAL_AUTO_TEST=TRUE \
if eval 'cmake --no-warn-unused-cli ${INIT_FILE:+"-C${INIT_FILE}"} -DRUNNING_CGAL_AUTO_TEST=TRUE \
-DCGAL_DIR="$CGAL_DIR" \
.' ; then

View File

@ -33,7 +33,7 @@ configure()
rm CMakeCache.txt
if [ -f "$INIT_FILE" ]
then
if eval 'cmake --no-warn-unused-cli ${INIT_FILE:+"-C${INIT_FILE}"} "$CMAKE_GENERATOR" -DRUNNING_CGAL_AUTO_TEST=TRUE \
if eval 'cmake --no-warn-unused-cli ${INIT_FILE:+"-C${INIT_FILE}"} -DRUNNING_CGAL_AUTO_TEST=TRUE \
-DCGAL_DIR="$CGAL_DIR" \
-DCGAL_CXX_FLAGS:STRING="$CGAL_CXX_FLAGS $TESTSUITE_CXXFLAGS" \
-DCGAL_EXE_LINKER_FLAGS="$CGAL_EXE_LINKER_FLAGS $TESTSUITE_LDFLAGS" \
@ -43,7 +43,7 @@ configure()
echo " ERROR: configuration" >> $ERRORFILE
fi
else
if eval 'cmake --no-warn-unused-cli ${INIT_FILE:+"-C${INIT_FILE}"} "$CMAKE_GENERATOR" -DRUNNING_CGAL_AUTO_TEST=TRUE \
if eval 'cmake --no-warn-unused-cli ${INIT_FILE:+"-C${INIT_FILE}"} -DRUNNING_CGAL_AUTO_TEST=TRUE \
-DCGAL_DIR="$CGAL_DIR" \
-DCGAL_CXX_FLAGS:STRING="$TESTSUITE_CXXFLAGS" \
-DCGAL_EXE_LINKER_FLAGS="$TESTSUITE_LDFLAGS" \