Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Conan bump deps #4015

Merged
merged 10 commits into from
Aug 14, 2020
10 changes: 5 additions & 5 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -727,9 +727,9 @@ endif()
# set(SWIG_EXECUTABLE swig)
# But will have the probblem with the swiglib anyways.
# Plus, it doesn't appear to work on windows either, the PATH doesn't include it.
#find_program(SWIG_EXECUTABLE swig PATHS CURRENT_CONAN_SWIG_INSTALLER_ROOT NO_DEFAULT_PATH)
#find_program(SWIG_EXECUTABLE swig PATHS CURRENT_CONAN_SWIG_ROOT NO_DEFAULT_PATH)
#if(NOT SWIG_EXECUTABLE)
# message(FATAL_ERROR "Couldn't find swig, which shouldn't happen. CONAN_BIN_DIRS_SWIG_INSTALLER=${CONAN_BIN_DIRS_SWIG_INSTALLER}, CONAN_SWIG_INSTALLER_ROOT_RELEASE=${CONAN_SWIG_INSTALLER_ROOT_RELEASE}, CURRENT_CONAN_SWIG_INSTALLER_ROOT=${CURRENT_CONAN_SWIG_INSTALLER_ROOT}, ${ENV{SWIG_LIB}}, ${ENV{SWIG_INSTALLER_ROOT}}")
# message(FATAL_ERROR "Couldn't find swig, which shouldn't happen. CONAN_BIN_DIRS_SWIG_INSTALLER=${CONAN_BIN_DIRS_SWIG_INSTALLER}, CONAN_SWIG_ROOT_RELEASE=${CONAN_SWIG_ROOT_RELEASE}, CURRENT_CONAN_SWIG_ROOT=${CURRENT_CONAN_SWIG_ROOT}, ${ENV{SWIG_LIB}}, ${ENV{SWIG_INSTALLER_ROOT}}")
#endif()

# Another thing I tried is to use the `virtualenv` generator (`conan_cmake_run( ... GENERATORS virtualenv)`),
Expand All @@ -738,12 +738,12 @@ endif()
# I also tried using CMake to extract the value from the activate.sh script on all plaftorms but it seems even more of a hack

# So instead, we use a generator expression to find the right value. At least it makes sense, and should be robust.
FindValue(CONAN_SWIG_INSTALLER_ROOT)
FindValue(CONAN_SWIG_ROOT)

set(SWIG_EXECUTABLE "${CURRENT_CONAN_SWIG_INSTALLER_ROOT}/bin/swig")
set(SWIG_EXECUTABLE "${CURRENT_CONAN_SWIG_ROOT}/bin/swig")

# The conan-provided binary has a built-in swiglib (`swig -swiglib`) that points to the build box on which it was built, which is problematic for us.
set(SWIG_LIB "${CURRENT_CONAN_SWIG_INSTALLER_ROOT}/share/swig/4.0.1")
set(SWIG_LIB "${CURRENT_CONAN_SWIG_ROOT}/bin/swiglib")

# Export SWIG to parent scope
if(hasParent)
Expand Down
42 changes: 15 additions & 27 deletions ConanInstall.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -23,20 +23,20 @@ if(NOT CONAN_OPENSTUDIO_ALREADY_RUN)

include(${CMAKE_BINARY_DIR}/conan.cmake)

conan_check(VERSION 1.21.0 REQUIRED)
conan_check(VERSION 1.28.0 REQUIRED)

message(STATUS "openstudio: RUNNING CONAN")

# Add NREL remote and place it first in line, since we vendored dependencies to NREL's repo, they will be picked first
conan_add_remote(NAME nrel INDEX 0
URL https://api.bintray.com/conan/commercialbuilding/nrel)

conan_add_remote(NAME bincrafters
URL https://api.bintray.com/conan/bincrafters/public-conan)
conan_add_remote(NAME nrel
URL https://api.bintray.com/conan/commercialbuilding/nrel)

#conan_add_remote(NAME jmarrec
# URL https://api.bintray.com/conan/jmarrec/testing)

# Convenience variable to set a consistent version for individual boost packages
# set(BOOST_VERSION "1.71.0")

list(APPEND CONAN_OPTIONS "zlib:minizip=True")
# TODO: list(APPEND CONAN_OPTIONS "fmt:header_only=True")

Expand All @@ -60,27 +60,16 @@ if(NOT CONAN_OPENSTUDIO_ALREADY_RUN)
openssl/1.1.0l # ruby 2.5.5 won't work with 1.1.1x, so use 1.1.0l here to try to force every package to align on the same as ruby
# Track NREL/stable in general, on a feature branch this could be temporarily switched to NREL/testing
openstudio_ruby/2.5.5@nrel/stable # TODO: Temp #@nrel/stable
boost/1.71.0
#boost_asio/${BOOST_VERSION}@bincrafters/stable
#boost_program_options/${BOOST_VERSION}@bincrafters/stable
#boost_regex/${BOOST_VERSION}@bincrafters/stable
#boost_filesystem/${BOOST_VERSION}@bincrafters/stable
#boost_crc/${BOOST_VERSION}@bincrafters/stable
#boost_algorithm/${BOOST_VERSION}@bincrafters/stable
#boost_uuid/${BOOST_VERSION}@bincrafters/stable
#boost_log/${BOOST_VERSION}@bincrafters/stable
#boost_numeric_ublas/${BOOST_VERSION}@bincrafters/stable
#boost_functional/${BOOST_VERSION}@bincrafters/stable
#boost_geometry/${BOOST_VERSION}@bincrafters/stable
pugixml/1.10@bincrafters/stable
jsoncpp/1.9.2
boost/1.73.0
pugixml/1.10
jsoncpp/1.9.3
zlib/1.2.11
fmt/6.2.0
sqlite3/3.30.1
cpprestsdk/2.10.14@bincrafters/stable
websocketpp/0.8.1@bincrafters/stable
geographiclib/1.49@bincrafters/stable
swig_installer/4.0.1@bincrafters/stable
fmt/7.0.1
sqlite3/3.32.3
cpprestsdk/2.10.16
websocketpp/0.8.2
geographiclib/1.50.1
swig/4.0.2
${CONAN_GTEST}

# Override to avoid dependency mismatches
Expand All @@ -103,4 +92,3 @@ else()
message(STATUS "openstudio: CONAN RUN BY CALLING SCRIPT")

endif()