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

In conda CI install yarp, icub-main and osqp-eigen from binaries on Linux/macOS and Windows #832

Merged
merged 8 commits into from
Feb 18, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 4 additions & 2 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,8 @@ jobs:
mamba install -c conda-forge cmake compilers make ninja pkg-config
# Actual dependencies
mamba install -c conda-forge eigen libxml2 assimp ipopt qt irrlicht
# robotology dependencies
mamba install -c conda-forge -c robotology-staging yarp icub-main osqp-eigen

# Additional dependencies useful only on Linux
- name: Dependencies [Conda/Linux]
Expand All @@ -58,15 +60,15 @@ jobs:
run: |
mkdir build
cd build
cmake -GNinja -DCMAKE_BUILD_TYPE=${{ matrix.build_type }} -DIDYNTREE_COMPILE_TESTS:BOOL=ON -DIDYNTREE_USES_Qt5:BOOL=ON -DIDYNTREE_USES_ASSIMP:BOOL=ON -DIDYNTREE_USES_IPOPT:BOOL=ON -DIDYNTREE_USES_IRRLICHT:BOOL=ON ..
cmake -GNinja -DCMAKE_BUILD_TYPE=${{ matrix.build_type }} -DIDYNTREE_COMPILE_TESTS:BOOL=ON -DIDYNTREE_USES_QT5:BOOL=ON -DIDYNTREE_USES_ASSIMP:BOOL=ON -DIDYNTREE_USES_IPOPT:BOOL=ON -DIDYNTREE_USES_IRRLICHT:BOOL=ON -DIDYNTREE_USES_YARP:BOOL=ON -DIDYNTREE_USES_ICUB_MAIN:BOOL=ON -DIDYNTREE_USES_OSQPEIGEN:BOOL=ON ..

- name: Configure [Conda/Windows]
if: contains(matrix.os, 'windows')
shell: bash -l {0}
run: |
mkdir build
cd build
cmake -G"Visual Studio 16 2019" -DCMAKE_BUILD_TYPE=${{ matrix.build_type }} -DIDYNTREE_COMPILE_TESTS:BOOL=ON -DIDYNTREE_USES_Qt5:BOOL=ON -DIDYNTREE_USES_ASSIMP:BOOL=ON -DIDYNTREE_USES_IPOPT:BOOL=ON -DIDYNTREE_USES_IRRLICHT:BOOL=ON ..
cmake -G"Visual Studio 16 2019" -DCMAKE_BUILD_TYPE=${{ matrix.build_type }} -DIDYNTREE_COMPILE_TESTS:BOOL=ON -DIDYNTREE_USES_QT5:BOOL=ON -DIDYNTREE_USES_ASSIMP:BOOL=ON -DIDYNTREE_USES_IPOPT:BOOL=ON -DIDYNTREE_USES_IRRLICHT:BOOL=ON -DIDYNTREE_USES_YARP:BOOL=ON -DIDYNTREE_USES_ICUB_MAIN:BOOL=ON -DIDYNTREE_USES_OSQPEIGEN:BOOL=ON ..

- name: Build [Conda]
shell: bash -l {0}
Expand Down
5 changes: 5 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,11 @@ All notable changes to this project will be documented in this file.
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).

## Unreleased

### Fixed
- Fixed the `IDYNTREE_USES_ASSIMP` option on Windows if `IDYNTREE_USES_YARP` is also enabled (https://github.com/robotology/idyntree/pull/832).

## [3.0.0] - 2020-02-03

### Added
Expand Down
17 changes: 11 additions & 6 deletions cmake/iDynTreeDependencies.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
# iDynTree has been added to a bigger project via add_subdirectory,
# and the required dependency has already been defined via add_subdirectory
macro(idyntree_handle_dependency package)
set(options DO_NOT_SILENTLY_SEARCH)
set(options DO_NOT_SILENTLY_SEARCH NO_MODULE)
set(singleValueArgs MINIMUM_VERSION MAIN_TARGET)
set(multiValueArgs COMPONENTS)
cmake_parse_arguments(IHD "${options}" "${singleValueArgs}" "${multiValueArgs}" ${ARGN})
Expand All @@ -28,11 +28,15 @@ macro(idyntree_handle_dependency package)
set(IHD_DEP_TARGET_IS_ALREADY_DEFINED TRUE)
endif()
endif()
set(IHD_FIND_PACKAGE_ADDITIONAL_OPTIONS "")
if(IHD_NO_MODULE)
list(APPEND IHD_FIND_PACKAGE_ADDITIONAL_OPTIONS "NO_MODULE")
endif()
if (NOT IHD_DO_NOT_SILENTLY_SEARCH AND NOT IHD_DEP_TARGET_IS_ALREADY_DEFINED)
if (IHD_COMPONENTS)
find_package(${package} ${IHD_MINIMUM_VERSION} QUIET COMPONENTS ${IHD_COMPONENTS})
find_package(${package} ${IHD_MINIMUM_VERSION} QUIET COMPONENTS ${IHD_COMPONENTS} ${IHD_FIND_PACKAGE_ADDITIONAL_OPTIONS})
else ()
find_package(${package} ${IHD_MINIMUM_VERSION} QUIET)
find_package(${package} ${IHD_MINIMUM_VERSION} QUIET ${IHD_FIND_PACKAGE_ADDITIONAL_OPTIONS})
endif ()
set(IDYNTREE_USES_${PKG}_DEFAULT ${${package}_FOUND})
else ()
Expand All @@ -46,9 +50,9 @@ macro(idyntree_handle_dependency package)
option(IDYNTREE_USES_${PKG} "Build the part of iDynTree that depends on package ${package}" ${IDYNTREE_USES_${PKG}_DEFAULT})
if (IDYNTREE_USES_${PKG} AND NOT IHD_DEP_TARGET_IS_ALREADY_DEFINED)
if (IHD_COMPONENTS)
find_package(${package} ${IHD_MINIMUM_VERSION} COMPONENTS ${IHD_COMPONENTS} REQUIRED)
find_package(${package} ${IHD_MINIMUM_VERSION} COMPONENTS ${IHD_COMPONENTS} REQUIRED ${IHD_FIND_PACKAGE_ADDITIONAL_OPTIONS})
else ()
find_package(${package} ${IHD_MINIMUM_VERSION} REQUIRED)
find_package(${package} ${IHD_MINIMUM_VERSION} REQUIRED ${IHD_FIND_PACKAGE_ADDITIONAL_OPTIONS})
endif ()
endif ()
endmacro ()
Expand Down Expand Up @@ -89,7 +93,8 @@ if(IDYNTREE_USES_ALGLIB AND ALGLIB_FOUND)
endif()
idyntree_handle_dependency(WORHP DO_NOT_SILENTLY_SEARCH)
# Workaround for https://github.com/robotology/idyntree/issues/599
idyntree_handle_dependency(assimp DO_NOT_SILENTLY_SEARCH MAIN_TARGET assimp::assimp)
# NO_MODULE passed to avoid that the Findassimp of YCM is used instead, https://github.com/robotology/idyntree/pull/832
idyntree_handle_dependency(assimp DO_NOT_SILENTLY_SEARCH NO_MODULE MAIN_TARGET assimp::assimp)
# Workaround for https://github.com/robotology/idyntree/issues/693
if(TARGET assimp::assimp)
get_property(assimp_INTERFACE_INCLUDE_DIRECTORIES
Expand Down