From 79bd539efa30d68f8913c8a177c55e34d797aa3f Mon Sep 17 00:00:00 2001 From: Tolis Chalkis Date: Wed, 5 May 2021 17:23:09 +0300 Subject: [PATCH] Update boost integration (#158) * fix boost in tests and examples folders * drop g++4.8 test --- .github/workflows/cmake-gcc.yml | 2 +- examples/Boost.cmake | 4 ++-- examples/CMakeLists.txt | 2 +- examples/hpolytope-volume/hpolytopeVolume.cpp | 2 +- examples/logconcave/CMakeLists.txt | 4 ++-- examples/vpolytope-volume/vpolytopevolume.cpp | 2 +- test/Boost.cmake | 4 ++-- 7 files changed, 10 insertions(+), 10 deletions(-) diff --git a/.github/workflows/cmake-gcc.yml b/.github/workflows/cmake-gcc.yml index bff7e2f4d..73cca0916 100644 --- a/.github/workflows/cmake-gcc.yml +++ b/.github/workflows/cmake-gcc.yml @@ -15,7 +15,7 @@ jobs: strategy: fail-fast: false matrix: - compilers: [g++-4.8, g++-5, g++-6, g++-7, g++-8, g++-9, g++-10] + compilers: [g++-5, g++-6, g++-7, g++-8, g++-9, g++-10] runs-on: ubuntu-18.04 steps: - uses: actions/checkout@v1 diff --git a/examples/Boost.cmake b/examples/Boost.cmake index 85b78e29d..1a4dfc952 100644 --- a/examples/Boost.cmake +++ b/examples/Boost.cmake @@ -4,8 +4,8 @@ function(GetBoost) if (NOT BOOST_DIR) - set(BOOST_URL "https://dl.bintray.com/boostorg/release/1.75.0/source/boost_1_75_0.tar.bz2" CACHE STRING "Boost download URL") - set(BOOST_URL_SHA256 "953db31e016db7bb207f11432bef7df100516eeb746843fa0486a222e3fd49cb" CACHE STRING "Boost download URL SHA256 checksum") + set(BOOST_URL "https://boostorg.jfrog.io/artifactory/main/release/1.76.0/source/boost_1_76_0.tar.bz2" CACHE STRING "Boost download URL") + set(BOOST_URL_SHA256 "f0397ba6e982c4450f27bf32a2a83292aba035b827a5623a14636ea583318c41" CACHE STRING "Boost download URL SHA256 checksum") include(FetchContent) FetchContent_Declare( diff --git a/examples/CMakeLists.txt b/examples/CMakeLists.txt index dffa88b77..791e3fdb2 100644 --- a/examples/CMakeLists.txt +++ b/examples/CMakeLists.txt @@ -110,7 +110,7 @@ else () #add_definitions( "-O3 -lgsl -lm -ldl -lgslcblas" ) add_subdirectory(logconcave) - add_subdirectory(spectrahedra) + #add_subdirectory(spectrahedra) add_subdirectory(hpolytope-volume) add_executable (vpolytopevolume vpolytope-volume/vpolytopevolume.cpp) diff --git a/examples/hpolytope-volume/hpolytopeVolume.cpp b/examples/hpolytope-volume/hpolytopeVolume.cpp index 377fd2c4e..487ce98f4 100644 --- a/examples/hpolytope-volume/hpolytopeVolume.cpp +++ b/examples/hpolytope-volume/hpolytopeVolume.cpp @@ -35,7 +35,7 @@ void calculateVolumes(const HPOLYTOPE &HP) { NT e=0.1; // Calculating volume of the passed polytope - NT volume1 = volume_cooling_balls(HP, e, walk_len); + NT volume1 = volume_cooling_balls(HP, e, walk_len).second; NT volume2 = volume_cooling_gaussians(HP, e, walk_len); NT volume3 = volume_sequence_of_balls(HP, e, walk_len); diff --git a/examples/logconcave/CMakeLists.txt b/examples/logconcave/CMakeLists.txt index c30545916..e9cb0934c 100644 --- a/examples/logconcave/CMakeLists.txt +++ b/examples/logconcave/CMakeLists.txt @@ -129,11 +129,11 @@ else () add_executable (simple_sde simple_sde.cpp) add_executable (high_dimensional_hmc high_dimensional_hmc.cpp) add_executable (high_dimensional_hmc_rand_poly high_dimensional_hmc_rand_poly.cpp) - add_executable (adaptive_step_size adaptive_step_size.cpp) + #add_executable (adaptive_step_size adaptive_step_size.cpp) TARGET_LINK_LIBRARIES(high_dimensional_hmc_rand_poly ${LP_SOLVE} ${BLAS} "-L${MKLROOT}/lib/intel64 -Wl,--no-as-needed -lmkl_intel_ilp64 -lmkl_gnu_thread -lmkl_core -lgomp -lpthread -lm -ldl") TARGET_LINK_LIBRARIES(high_dimensional_hmc ${LP_SOLVE} ${BLAS} "-L${MKLROOT}/lib/intel64 -Wl,--no-as-needed -lmkl_intel_ilp64 -lmkl_gnu_thread -lmkl_core -lgomp -lpthread -lm -ldl") - TARGET_LINK_LIBRARIES(adaptive_step_size ${LP_SOLVE} ${BLAS} "-L${MKLROOT}/lib/intel64 -Wl,--no-as-needed -lmkl_intel_ilp64 -lmkl_gnu_thread -lmkl_core -lgomp -lpthread -lm -ldl") + #TARGET_LINK_LIBRARIES(adaptive_step_size ${LP_SOLVE} ${BLAS} "-L${MKLROOT}/lib/intel64 -Wl,--no-as-needed -lmkl_intel_ilp64 -lmkl_gnu_thread -lmkl_core -lgomp -lpthread -lm -ldl") TARGET_LINK_LIBRARIES(simple_ode ${LP_SOLVE} ${BLAS} "-L${MKLROOT}/lib/intel64 -Wl,--no-as-needed -lmkl_intel_ilp64 -lmkl_gnu_thread -lmkl_core -lgomp -lpthread -lm -ldl") TARGET_LINK_LIBRARIES(simple_sde ${LP_SOLVE} ${BLAS} "-L${MKLROOT}/lib/intel64 -Wl,--no-as-needed -lmkl_intel_ilp64 -lmkl_gnu_thread -lmkl_core -lgomp -lpthread -lm -ldl") TARGET_LINK_LIBRARIES(simple_uld ${LP_SOLVE} ${BLAS} "-L${MKLROOT}/lib/intel64 -Wl,--no-as-needed -lmkl_intel_ilp64 -lmkl_gnu_thread -lmkl_core -lgomp -lpthread -lm -ldl") diff --git a/examples/vpolytope-volume/vpolytopevolume.cpp b/examples/vpolytope-volume/vpolytopevolume.cpp index 14fdb5a2e..e814b5875 100644 --- a/examples/vpolytope-volume/vpolytopevolume.cpp +++ b/examples/vpolytope-volume/vpolytopevolume.cpp @@ -34,7 +34,7 @@ void calculateVolumes(const VPOLYTOPE &VP) { NT e=0.1; // Calculating volume of the passed polytope - NT volume1 = volume_cooling_balls(VP, e, walk_len); + NT volume1 = volume_cooling_balls(VP, e, walk_len).second; NT volume2 = volume_cooling_gaussians(VP, e, walk_len); std::cout<<"\t Using Cooling Balls method: "<