early-access version 2853
This commit is contained in:
34
externals/vcpkg/ports/sdformat6/disable-test.patch
vendored
Executable file
34
externals/vcpkg/ports/sdformat6/disable-test.patch
vendored
Executable file
@@ -0,0 +1,34 @@
|
||||
diff --git a/CMakeLists.txt b/CMakeLists.txt
|
||||
index 78e72e6..8f97304 100644
|
||||
--- a/CMakeLists.txt
|
||||
+++ b/CMakeLists.txt
|
||||
@@ -252,7 +252,9 @@ else (buid_errors)
|
||||
|
||||
link_directories(${PROJECT_BINARY_DIR}/src)
|
||||
|
||||
+ if (BUILD_TESTING)
|
||||
add_subdirectory(test)
|
||||
+ endif()
|
||||
add_subdirectory(src)
|
||||
add_subdirectory(include/sdf)
|
||||
add_subdirectory(sdf)
|
||||
diff --git a/cmake/SDFUtils.cmake b/cmake/SDFUtils.cmake
|
||||
index acd57f8..3626e68 100644
|
||||
--- a/cmake/SDFUtils.cmake
|
||||
+++ b/cmake/SDFUtils.cmake
|
||||
@@ -119,6 +119,7 @@ endmacro()
|
||||
include_directories(${PROJECT_SOURCE_DIR}/test/gtest/include)
|
||||
macro (sdf_build_tests)
|
||||
# Build all the tests
|
||||
+ if (BUILD_TESTING)
|
||||
foreach(GTEST_SOURCE_file ${ARGN})
|
||||
string(REGEX REPLACE ".cc" "" BINARY_NAME ${GTEST_SOURCE_file})
|
||||
set(BINARY_NAME ${TEST_TYPE}_${BINARY_NAME})
|
||||
@@ -205,6 +206,7 @@ macro (sdf_build_tests)
|
||||
--error-exitcode=1 --show-leak-kinds=all ${CMAKE_CURRENT_BINARY_DIR}/${BINARY_NAME})
|
||||
endif()
|
||||
endforeach()
|
||||
+ endif()
|
||||
endmacro()
|
||||
|
||||
#################################################
|
||||
12
externals/vcpkg/ports/sdformat6/disable-unneeded-include-findboost.patch
vendored
Executable file
12
externals/vcpkg/ports/sdformat6/disable-unneeded-include-findboost.patch
vendored
Executable file
@@ -0,0 +1,12 @@
|
||||
diff --git a/cmake/SearchForStuff.cmake b/cmake/SearchForStuff.cmake
|
||||
index c2a0ee4..2735a07 100644
|
||||
--- a/cmake/SearchForStuff.cmake
|
||||
+++ b/cmake/SearchForStuff.cmake
|
||||
@@ -13,7 +13,6 @@ if (WIN32)
|
||||
set(Boost_USE_STATIC_RUNTIME OFF)
|
||||
endif()
|
||||
|
||||
-include(FindBoost)
|
||||
find_package(Boost ${MIN_BOOST_VERSION})
|
||||
|
||||
if (NOT Boost_FOUND)
|
||||
34
externals/vcpkg/ports/sdformat6/fix-dependency-urdfdom.patch
vendored
Executable file
34
externals/vcpkg/ports/sdformat6/fix-dependency-urdfdom.patch
vendored
Executable file
@@ -0,0 +1,34 @@
|
||||
diff --git a/cmake/SearchForStuff.cmake b/cmake/SearchForStuff.cmake
|
||||
index 2735a07..6721de4 100644
|
||||
--- a/cmake/SearchForStuff.cmake
|
||||
+++ b/cmake/SearchForStuff.cmake
|
||||
@@ -62,16 +62,16 @@ if (NOT PKG_CONFIG_FOUND)
|
||||
if (NOT DEFINED USE_INTERNAL_URDF)
|
||||
BUILD_WARNING("Couldn't find pkg-config for urdfdom, using internal copy")
|
||||
set(USE_INTERNAL_URDF true)
|
||||
- elseif(NOT USE_INTERNAL_URDF)
|
||||
+ elseif(0)
|
||||
BUILD_ERROR("Couldn't find pkg-config for urdfdom")
|
||||
endif()
|
||||
endif()
|
||||
|
||||
if (NOT DEFINED USE_INTERNAL_URDF OR NOT USE_INTERNAL_URDF)
|
||||
# check for urdfdom with pkg-config
|
||||
- pkg_check_modules(URDF urdfdom>=1.0)
|
||||
+ find_package(urdfdom CONFIG REQUIRED)
|
||||
|
||||
- if (NOT URDF_FOUND)
|
||||
+ if (NOT urdfdom_FOUND)
|
||||
if (NOT DEFINED USE_INTERNAL_URDF)
|
||||
message(STATUS "Couldn't find urdfdom >= 1.0, using internal copy")
|
||||
set(USE_INTERNAL_URDF true)
|
||||
@@ -80,8 +80,7 @@ if (NOT DEFINED USE_INTERNAL_URDF OR NOT USE_INTERNAL_URDF)
|
||||
endif()
|
||||
else()
|
||||
# what am I doing here? pkg-config and cmake
|
||||
- set(URDF_INCLUDE_DIRS ${URDF_INCLUDEDIR})
|
||||
- set(URDF_LIBRARY_DIRS ${URDF_LIBDIR})
|
||||
+ set(URDF_LIBRARIES urdfdom::urdfdom_model urdfdom::urdfdom_world urdfdom::urdfdom_sensor urdfdom::urdfdom_model_state)
|
||||
endif()
|
||||
endif()
|
||||
|
||||
59
externals/vcpkg/ports/sdformat6/portfile.cmake
vendored
Executable file
59
externals/vcpkg/ports/sdformat6/portfile.cmake
vendored
Executable file
@@ -0,0 +1,59 @@
|
||||
vcpkg_from_github(
|
||||
OUT_SOURCE_PATH SOURCE_PATH
|
||||
REPO osrf/sdformat
|
||||
REF sdformat6_6.2.0
|
||||
SHA512 3d139ec4b4c9fbfd547ed8bfca0adb5cdca92c1b7cc4d4b554a7c51ccf755b9079c26a006ebfedc5bc5b1ba5e16ad950bb38c47ea97bf97e59a2fd7d12d60620
|
||||
HEAD_REF sdf6
|
||||
PATCHES
|
||||
disable-unneeded-include-findboost.patch
|
||||
fix-dependency-urdfdom.patch
|
||||
disable-test.patch
|
||||
)
|
||||
|
||||
# Ruby is required by the sdformat build process
|
||||
vcpkg_find_acquire_program(RUBY)
|
||||
get_filename_component(RUBY_PATH ${RUBY} DIRECTORY)
|
||||
set(_path $ENV{PATH})
|
||||
vcpkg_add_to_path(${RUBY_PATH})
|
||||
|
||||
vcpkg_cmake_configure(
|
||||
SOURCE_PATH "${SOURCE_PATH}"
|
||||
OPTIONS
|
||||
-DBUILD_TESTING=OFF
|
||||
-DUSE_INTERNAL_URDF=OFF
|
||||
-DUSE_EXTERNAL_TINYXML=ON
|
||||
)
|
||||
|
||||
vcpkg_cmake_install()
|
||||
|
||||
# Restore original path
|
||||
set(ENV{PATH} ${_path})
|
||||
|
||||
# Move location of sdformat.dll from lib to bin
|
||||
if(EXISTS "${CURRENT_PACKAGES_DIR}/lib/sdformat.dll")
|
||||
file(MAKE_DIRECTORY "${CURRENT_PACKAGES_DIR}/bin")
|
||||
file(RENAME "${CURRENT_PACKAGES_DIR}/lib/sdformat.dll"
|
||||
"${CURRENT_PACKAGES_DIR}/bin/sdformat.dll")
|
||||
endif()
|
||||
|
||||
if(EXISTS "${CURRENT_PACKAGES_DIR}/debug/lib/sdformat.dll")
|
||||
file(MAKE_DIRECTORY "${CURRENT_PACKAGES_DIR}/debug/bin")
|
||||
file(RENAME "${CURRENT_PACKAGES_DIR}/debug/lib/sdformat.dll"
|
||||
"${CURRENT_PACKAGES_DIR}/debug/bin/sdformat.dll")
|
||||
endif()
|
||||
|
||||
# Fix cmake targets location
|
||||
vcpkg_cmake_config_fixup(CONFIG_PATH "lib/cmake/sdformat")
|
||||
|
||||
# Remove debug files
|
||||
file(REMOVE_RECURSE "${CURRENT_PACKAGES_DIR}/debug/include"
|
||||
"${CURRENT_PACKAGES_DIR}/debug/lib/cmake"
|
||||
"${CURRENT_PACKAGES_DIR}/debug/share")
|
||||
|
||||
vcpkg_replace_string("${CURRENT_PACKAGES_DIR}/share/ignition/sdformat6.yaml" "${CURRENT_PACKAGES_DIR}" "../..")
|
||||
vcpkg_replace_string("${CURRENT_PACKAGES_DIR}/include/sdformat-6.2/sdf/sdf_config.h" "#define SDF_SHARE_PATH \"${CURRENT_PACKAGES_DIR}/share/\"" "")
|
||||
vcpkg_replace_string("${CURRENT_PACKAGES_DIR}/include/sdformat-6.2/sdf/sdf_config.h" "#define SDF_VERSION_PATH \"${CURRENT_PACKAGES_DIR}/share/sdformat/\"" "")
|
||||
# Handle copyright
|
||||
file(INSTALL "${SOURCE_PATH}/LICENSE" DESTINATION "${CURRENT_PACKAGES_DIR}/share/${PORT}" RENAME copyright)
|
||||
|
||||
vcpkg_fixup_pkgconfig()
|
||||
24
externals/vcpkg/ports/sdformat6/vcpkg.json
vendored
Executable file
24
externals/vcpkg/ports/sdformat6/vcpkg.json
vendored
Executable file
@@ -0,0 +1,24 @@
|
||||
{
|
||||
"name": "sdformat6",
|
||||
"version": "6.2.0",
|
||||
"port-version": 6,
|
||||
"description": "Simulation Description Format (SDF) parser and description files.",
|
||||
"homepage": "http://sdformat.org/",
|
||||
"license": "Apache-2.0",
|
||||
"supports": "!(arm | uwp)",
|
||||
"dependencies": [
|
||||
"boost-any",
|
||||
"boost-variant",
|
||||
"ignition-math4",
|
||||
"tinyxml",
|
||||
"urdfdom",
|
||||
{
|
||||
"name": "vcpkg-cmake",
|
||||
"host": true
|
||||
},
|
||||
{
|
||||
"name": "vcpkg-cmake-config",
|
||||
"host": true
|
||||
}
|
||||
]
|
||||
}
|
||||
Reference in New Issue
Block a user