Skip to content

Commit

Permalink
w
Browse files Browse the repository at this point in the history
  • Loading branch information
jslee02 committed Mar 12, 2024
1 parent bd0473b commit 761fa27
Show file tree
Hide file tree
Showing 3 changed files with 31 additions and 10 deletions.
8 changes: 4 additions & 4 deletions .github/workflows/cache_vcpkg.yml
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ jobs:
%VCPKG_ROOT%\bootstrap-vcpkg.bat
- name: Upload Artifacts
uses: actions/upload-artifact@v4
uses: actions/upload-artifact@v3
with:
name: base
path: ${{ env.VCPKG_ROOT }}
Expand All @@ -50,11 +50,11 @@ jobs:
zip-name: ["vcpkg-dartsim-deps-v7.0"]
deps:
[
"assimp ccd eigen3 entt fcl fmt spdlog bullet3 coin-or-ipopt freeglut glfw3 nlopt ode opencl opengl osg pagmo2 pybind11 tinyxml2 urdfdom yaml-cpp",
"assimp ccd eigen3 entt fcl fmt spdlog bullet3 coin-or-ipopt freeglut glfw3 nlopt ode opencl opengl osg pagmo2 tinyxml2 urdfdom yaml-cpp",
]
include:
- zip-name: "vcpkg-dartsim-deps-v6.14"
deps: "assimp ccd eigen3 fcl fmt spdlog bullet3 coin-or-ipopt flann freeglut glfw3 nlopt ode opengl osg pagmo2 pybind11 tinyxml2 urdfdom"
deps: "assimp ccd eigen3 fcl fmt spdlog bullet3 coin-or-ipopt flann freeglut glfw3 nlopt ode opengl osg pagmo2 tinyxml2 urdfdom"

# - zip-name: "vcpkg-dartsim-deps-min-v7.0"
# deps: "assimp ccd eigen3 entt fcl fmt spdlog"
Expand Down Expand Up @@ -116,7 +116,7 @@ jobs:
)
- name: Upload Vcpkg Artifacts
uses: actions/upload-artifact@v4
uses: actions/upload-artifact@v3
with:
name: ${{ matrix.zip-name }}
path: ./${{ matrix.zip-name }}.zip
7 changes: 2 additions & 5 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -1,11 +1,7 @@
#===============================================================================
# CMake settings
#===============================================================================
if(WIN32)
cmake_minimum_required(VERSION 3.11)
else()
cmake_minimum_required(VERSION 3.10.2)
endif()
cmake_minimum_required(VERSION 3.16.3)

project(dart)

Expand Down Expand Up @@ -106,6 +102,7 @@ option(DART_FAST_DEBUG "Add -O1 option for DEBUG mode build" OFF)
# See: https://medium.com/@alasher/colored-c-compiler-output-with-ninja-clang-gcc-10bfe7f2b949
option(DART_FORCE_COLORED_OUTPUT
"Always produce ANSI-colored output (GNU/Clang only)." OFF)
option(DART_DOWNLOAD_BUILD_DEPS "Download build dependencies" ON)

#===============================================================================
# Print intro
Expand Down
26 changes: 25 additions & 1 deletion python/dartpy/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,31 @@
#
# This file is provided under the "BSD-style" License

if(DART_DOWNLOAD_BUILD_DEPS)
include(FetchContent)
FetchContent_Declare(
pybind11
GIT_REPOSITORY https://github.com/pybind/pybind11.git
GIT_TAG v2.11.1
)

# Set options
set(PYBIND11_TEST OFF CACHE BOOL "" FORCE)
set(PYBIND11_FINDPYTHON ON CACHE BOOL "" FORCE)

# To suppress warning, Policy CMP0042 is not set
set(CMAKE_MACOSX_RPATH 1)

FetchContent_MakeAvailable(pybind11)
else()
# Find pybind11, including PythonInterp and PythonLibs
find_package(pybind11 2.9.1 CONFIG)
if(NOT pybind11_FOUND)
message(WARNING "Disabling [dartpy] due to missing pybind11 >= 2.9.1.")
return()
endif()
endif()

if(NOT DARTPY_PYTHON_VERSION)
set(DARTPY_PYTHON_VERSION 3.4 CACHE STRING "Choose the target Python version (e.g., 3.4, 2.7)" FORCE)
endif()
Expand All @@ -16,7 +41,6 @@ set(PYBIND11_PYTHON_VERSION ${DARTPY_PYTHON_VERSION})
if(WIN32)
set(PYBIND11_FINDPYTHON TRUE)
endif()
find_package(pybind11 2.2.0 QUIET)
if(NOT pybind11_FOUND)
message(WARNING "Disabling [dartpy] due to missing pybind11 >= 2.2.0.")
return()
Expand Down

0 comments on commit 761fa27

Please sign in to comment.