Skip to content
Permalink
Browse files

travis, cmake: remove CASADIPATH (was unused) remove SWIG_{MATLAB,PYT…

…HON} (is broken)
  • Loading branch information...
FreyJo committed Sep 10, 2019
2 parents 05f810e + e513468 commit 543e2bfcdfc8d22200681052c58f7bcea3bfaf4e
@@ -7,8 +7,6 @@ env:
- ACADOS_EXAMPLES="ON"
- ACADOS_WITH_QPOASES="ON"
- ACADOS_LINT="OFF"
- SWIG_MATLAB="OFF"
- SWIG_PYTHON="OFF"
- TEMPLATE_PYTHON="OFF"
- TEMPLATE_MATLAB="OFF"
- ACADOS_MATLAB="OFF"
@@ -41,14 +39,14 @@ matrix:

- name: Linux Gcc6 - Octave interface
env:
- DEPLOY_NAME="linux-python-gcc6"
- DEPLOY_NAME="linux octave gcc6"
- MATRIX_EVAL="CC=gcc-6 && CXX=g++-6"
- ACADOS_OCTAVE="ON"
- ACADOS_EXAMPLES="OFF"

- name: Linux Gcc4.9 - Octave interface + coverage
env:
- DEPLOY_NAME="linux-python-matlab-gcc49"
- DEPLOY_NAME="linux-octave-coverage-gcc49"
- MATRIX_EVAL="CC=gcc-4.9 && CXX=g++-4.9"
- COVERAGE="lcov"
- ACADOS_OCTAVE="ON"
@@ -68,7 +66,6 @@ matrix:
cache:
ccache: true
directories:
- "${CASADIPATH}"

before_install:
- eval "${MATRIX_EVAL}"
@@ -66,8 +66,6 @@ option(ACADOS_WITH_OOQP "OOQP solver" OFF)
option(ACADOS_WITH_QPDUNES "qpDUNES solver" OFF)
option(ACADOS_WITH_OSQP "OSQP solver" OFF)
# Interfaces
option(SWIG_MATLAB "Swig Matlab Interface" OFF)
option(SWIG_PYTHON "Swig Python Interface" OFF)
option(TEMPLATE_MATLAB "Template Matlab Interface" OFF)
option(TEMPLATE_PYTHON "Template Python Interface" OFF)
option(DEV_MATLAB "Developer Matlab Interface" OFF)
@@ -154,19 +152,6 @@ if(ACADOS_WITH_QORE MATCHES ON)
endif()
endif()

if(SWIG_MATLAB OR SWIG_PYTHON)
if(CMAKE_SYSTEM_NAME MATCHES "dSpace")
set(SWIG_MATLAB OFF CACHE BOOL "Swig Matlab Interface" FORCE)
set(SWIG_PYTHON OFF CACHE BOOL "Swig Python Interface" FORCE)
message(WARNING "Swig has been disabled, not compatible with dSpace system")
endif()
if(CMAKE_BUILD_TYPE MATCHES NoExternalLibs)
set(SWIG_MATLAB OFF CACHE BOOL "Swig Matlab Interface" FORCE)
set(SWIG_PYTHON OFF CACHE BOOL "Swig Python Interface" FORCE)
message(WARNING "Swig has been disabled, not compatible with NoExternalLibs target")
endif()
endif()

if(ACADOS_LINT)
if(CMAKE_SYSTEM_NAME MATCHES "Windows" OR CMAKE_SYSTEM_NAME MATCHES "dSpace")
set(ACADOS_LINT OFF CACHE BOOL "Lint" FORCE)
@@ -186,11 +171,6 @@ add_subdirectory(acados)
# Configure interfaces
add_subdirectory(${PROJECT_SOURCE_DIR}/interfaces/acados_c)

if((SWIG_PYTHON OR SWIG_MATLAB))
add_subdirectory(${PROJECT_SOURCE_DIR}/interfaces/acados_cpp)
add_subdirectory(${PROJECT_SOURCE_DIR}/swig)
endif()

# Configure external libraries
add_subdirectory(${EXTERNAL_SRC_DIR})

@@ -223,7 +203,6 @@ add_custom_target(uninstall
# Current config messages
message(STATUS "Target: BLASFEO is ${BLASFEO_TARGET}, HPIPM is ${HPIPM_TARGET}")
message(STATUS "Linear algebra: ${LA}")
message(STATUS "Swig: Python (${SWIG_PYTHON}) Matlab (${SWIG_MATLAB})")
message(STATUS "Matlab MEX (${ACADOS_MATLAB})")
message(STATUS "Octave MEX (${ACADOS_OCTAVE})")
message(STATUS "System name:version ${CMAKE_SYSTEM_NAME}:${CMAKE_SYSTEM_VERSION}")
@@ -137,11 +137,6 @@ if(NOT CMAKE_BUILD_TYPE MATCHES "Debug")
target_compile_definitions(acados PUBLIC MEASURE_TIMINGS)
endif()

if(SWIG_PYTHON OR SWIG_MATLAB)
find_package(Casadi REQUIRED)
target_link_libraries(acados PUBLIC casadi)
endif()

# Only test acados library for coverage
if(COVERAGE MATCHES "lcov")
include(CodeCoverage)
@@ -44,8 +44,7 @@ elif [ "${SECTION}" = 'install' ]; then
source "${SHARED_SCRIPT_DIR}/install_eigen.sh";
source "${SCRIPT_DIR}/install_python.sh";

if [[ "${SWIG_MATLAB}" = 'ON' || "${SWIG_PYTHON}" = 'ON' ]] ||
[[ "${TEMPLATE_PYTHON}" = 'ON' || "${TEMPLATE_MATLAB}" = 'ON' ]] ||
if [[ "${TEMPLATE_PYTHON}" = 'ON' || "${TEMPLATE_MATLAB}" = 'ON' ]] ||
[[ "${ACADOS_MATLAB}" = 'ON' || "${ACADOS_OCTAVE}" = 'ON' ]] ||
"${DEV_MATLAB}" = 'ON';
then
@@ -78,22 +77,17 @@ elif [ "${SECTION}" = 'install' ]; then
echo "LD_LIBRARY_PATH=$LD_LIBRARY_PATH"
fi

if [[ "${SWIG_PYTHON}" = 'ON' || "${TEMPLATE_PYTHON}" = 'ON' ]] ;
if [[ "${TEMPLATE_PYTHON}" = 'ON' ]] ;
then
source "${SCRIPT_DIR}/install_python_dependencies.sh";
fi

if [[ "${SWIG_MATLAB}" = 'ON' || "${TEMPLATE_MATLAB}" = 'ON' ]] ||
if [[ "${TEMPLATE_MATLAB}" = 'ON' ]] ||
[[ "${DEV_MATLAB}" = 'ON' || "${ACADOS_MATLAB}" = 'ON' ]];
then
source "${SHARED_SCRIPT_DIR}/install_matlab.sh";
fi

if [[ "${SWIG_MATLAB}" = 'ON' || "${SWIG_PYTHON}" = 'ON' ]];
then
source "${SHARED_SCRIPT_DIR}/install_swig.sh";
fi

elif [ "${SECTION}" = 'script' ]; then
source "${SHARED_SCRIPT_DIR}/script_acados_release.sh";

@@ -41,16 +41,15 @@ CASADI_OCTAVE_URL="${_CASADI_GITHUB_RELEASES}/casadi-linux-octave-v${CASADI_VERS
echo "installing CasADi"

pushd external;
if [[ "${SWIG_PYTHON}" = 'ON' || "${TEMPLATE_PYTHON}" = 'ON' ]] ;
if [[ "${TEMPLATE_PYTHON}" = 'ON' ]] ;
then
wget -O casadi-linux-py35.tar.gz "${CASADI_PYTHON_URL}";
mkdir -p casadi-linux-py35;
tar -xf casadi-linux-py35.tar.gz -C casadi-linux-py35;
export PYTHONPATH=$(pwd)/casadi-linux-py35:$PYTHONPATH;
export CASADIPATH=$(pwd)/casadi-linux-py35;
fi

if [[ "${SWIG_MATLAB}" = 'ON' || "${TEMPLATE_MATLAB}" = 'ON' ]] ||
if [[ "${TEMPLATE_MATLAB}" = 'ON' ]] ||
[[ "${DEV_MATLAB}" = 'ON' || "${ACADOS_MATLAB}" = 'ON' ]];
then
wget -O casadi-linux-matlabR2014b.tar.gz "${CASADI_MATLAB_URL}";
@@ -45,30 +45,24 @@ elif [ "${SECTION}" = 'install' ]; then
source "${SCRIPT_DIR}/install_ccache.sh";
source "${SHARED_SCRIPT_DIR}/install_eigen.sh";

if [[ "${SWIG_MATLAB}" = 'ON' || "${SWIG_PYTHON}" = 'ON' ]] ||
[[ "${TEMPLATE_PYTHON}" = 'ON' || "${TEMPLATE_MATLAB}" = 'ON' ]] ||
if [[ "${TEMPLATE_PYTHON}" = 'ON' || "${TEMPLATE_MATLAB}" = 'ON' ]] ||
[[ "${ACADOS_MATLAB}" = 'ON' || "${ACADOS_OCTAVE}" = 'ON' ]] ||
"${DEV_MATLAB}" = 'ON';
then
source "${SCRIPT_DIR}/install_casadi.sh";
fi

if [[ "${SWIG_PYTHON}" = 'ON' || "${TEMPLATE_PYTHON}" = 'ON' ]] ;
if [[ "${TEMPLATE_PYTHON}" = 'ON' ]] ;
then
source "${SCRIPT_DIR}/install_python_dependencies.sh";
fi

if [[ "${SWIG_MATLAB}" = 'ON' || "${TEMPLATE_MATLAB}" = 'ON' ]] ||
if [[ "${TEMPLATE_MATLAB}" = 'ON' ]] ||
[[ "${DEV_MATLAB}" = 'ON' || "${ACADOS_MATLAB}" = 'ON' ]];
then
source "${SHARED_SCRIPT_DIR}/install_matlab.sh";
fi

if [[ "${SWIG_MATLAB}" = 'ON' || "${SWIG_PYTHON}" = 'ON' ]];
then
source "${SHARED_SCRIPT_DIR}/install_swig.sh";
fi

elif [ "${SECTION}" = 'script' ]; then
source "${SHARED_SCRIPT_DIR}/script_acados_release.sh";

@@ -32,23 +32,24 @@
# POSSIBILITY OF SUCH DAMAGE.;
#

CASADIPATH="${CASADIPATH:-${HOME}/casadi}";
CASADI_VERSION='3.4.0';
CASADI_DOWNLOAD_URL="https://github.com/casadi/casadi/archive/${CASADI_VERSION}.zip";
# TODO: adapt this from the linux file!, DONT use CASADIPATH

# run only if casadi build was not cached
if [ ! -d "${CASADIPATH}" -o -z "$(ls -A "${CASADIPATH}")" ]; then
pushd "${TRAVIS_BUILD_DIR}/external";
curl -o casadi.zip -Ls "${CASADI_DOWNLOAD_URL}";
unzip -qq casadi.zip;
rm -f casadi.zip;
pushd "./casadi-${CASADI_VERSION}";
mkdir build;
pushd ./build;
cmake -DWITH_SELFCONTAINED=ON -DWITH_PYTHON=ON -DWITH_PYTHON3=ON -DCMAKE_INSTALL_PREFIX="${CASADIPATH}" ..;
make -j 4 && make install;
popd;
popd;
popd;
fi
export PYTHONPATH="${CASADIPATH}:$PYTHONPATH";
# CASADI_VERSION='3.4.0';
# CASADI_DOWNLOAD_URL="https://github.com/casadi/casadi/archive/${CASADI_VERSION}.zip";

# # run only if casadi build was not cached
# if [ ! -d "${CASADIPATH}" -o -z "$(ls -A "${CASADIPATH}")" ]; then
# pushd "${TRAVIS_BUILD_DIR}/external";
# curl -o casadi.zip -Ls "${CASADI_DOWNLOAD_URL}";
# unzip -qq casadi.zip;
# rm -f casadi.zip;
# pushd "./casadi-${CASADI_VERSION}";
# mkdir build;
# pushd ./build;
# cmake -DWITH_SELFCONTAINED=ON -DWITH_PYTHON=ON -DWITH_PYTHON3=ON -DCMAKE_INSTALL_PREFIX="${CASADIPATH}" ..;
# make -j 4 && make install;
# popd;
# popd;
# popd;
# fi
# export PYTHONPATH="${CASADIPATH}:$PYTHONPATH";

This file was deleted.

@@ -59,9 +59,7 @@ function build_acados {
-D ACADOS_LINT="${ACADOS_LINT}" \
-D ACADOS_INSTALL_DIR="${ACADOS_INSTALL_DIR}" \
-D Matlab_ROOT_DIR="${MATLAB_ROOT}" \
-D SWIG_MATLAB="${SWIG_MATLAB}" \
-D COVERAGE="${COVERAGE}" \
-D SWIG_PYTHON="${SWIG_PYTHON}" \
-D BUILD_SHARED_LIBS=ON \
-D ACADOS_EXAMPLES="${ACADOS_EXAMPLES}" \
-D MATLAB_EXECUTABLE="${MATLAB_EXECUTABLE}" \

This file was deleted.

@@ -41,7 +41,7 @@ if(NOT PYTHONINTERP_FOUND)
endif()

set(FIND_FILES_TO_LINT
find acados examples interfaces swig test
find acados examples interfaces test
-type f -name "*.c" -o -name "*.cpp" -o -name "*.h" -o -name "*.hpp" -o -name "*.i")
set(FIND_FILES_TO_LINT ${CMAKE_COMMAND} -E chdir ${PROJECT_SOURCE_DIR} ${FIND_FILES_TO_LINT})

0 comments on commit 543e2bf

Please sign in to comment.
You can’t perform that action at this time.