early-access version 2853
This commit is contained in:
13
externals/vcpkg/ports/ccd/fix-static.patch
vendored
Executable file
13
externals/vcpkg/ports/ccd/fix-static.patch
vendored
Executable file
@@ -0,0 +1,13 @@
|
||||
diff --git a/src/ccd/ccd_export.h b/src/ccd/ccd_export.h
|
||||
index e898d41..c6aa5fb 100644
|
||||
--- a/src/ccd/ccd_export.h
|
||||
+++ b/src/ccd/ccd_export.h
|
||||
@@ -1,7 +1,7 @@
|
||||
#ifndef CCD_EXPORT_H
|
||||
#define CCD_EXPORT_H
|
||||
|
||||
-#ifdef CCD_STATIC_DEFINE
|
||||
+#if 1
|
||||
# define CCD_EXPORT
|
||||
#else
|
||||
# ifdef _MSC_VER
|
||||
35
externals/vcpkg/ports/ccd/portfile.cmake
vendored
Executable file
35
externals/vcpkg/ports/ccd/portfile.cmake
vendored
Executable file
@@ -0,0 +1,35 @@
|
||||
if(VCPKG_LIBRARY_LINKAGE STREQUAL static)
|
||||
set(STATIC_PATCH fix-static.patch)
|
||||
endif()
|
||||
|
||||
vcpkg_from_github(
|
||||
OUT_SOURCE_PATH SOURCE_PATH
|
||||
REPO danfis/libccd
|
||||
REF v2.1
|
||||
SHA512 ff037d9c4df50f09600cf9b3514b259b2850ff43f74817853f5665d22812891168f70bd3cc3969b2c9e3c706f6254991a65421476349607fbd04d894b217456d
|
||||
HEAD_REF master
|
||||
# Backport https://github.com/danfis/libccd/pull/70 to support Emscripten
|
||||
PATCHES
|
||||
"support-emscripten.patch"
|
||||
${STATIC_PATCH}
|
||||
)
|
||||
|
||||
vcpkg_configure_cmake(
|
||||
SOURCE_PATH ${SOURCE_PATH}
|
||||
PREFER_NINJA
|
||||
OPTIONS
|
||||
-DBUILD_TESTING=OFF
|
||||
)
|
||||
|
||||
vcpkg_install_cmake()
|
||||
vcpkg_copy_pdbs()
|
||||
|
||||
vcpkg_fixup_cmake_targets(CONFIG_PATH lib/ccd)
|
||||
|
||||
file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/debug/include)
|
||||
file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/debug/share)
|
||||
file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/share/doc)
|
||||
|
||||
file(INSTALL ${SOURCE_PATH}/BSD-LICENSE DESTINATION ${CURRENT_PACKAGES_DIR}/share/${PORT} RENAME copyright)
|
||||
|
||||
vcpkg_fixup_pkgconfig()
|
||||
25
externals/vcpkg/ports/ccd/support-emscripten.patch
vendored
Executable file
25
externals/vcpkg/ports/ccd/support-emscripten.patch
vendored
Executable file
@@ -0,0 +1,25 @@
|
||||
From c3616f28d33019047e8e71df8abeb0493159539e Mon Sep 17 00:00:00 2001
|
||||
From: Silvio Traversaro <silvio@traversaro.it>
|
||||
Date: Sun, 17 May 2020 11:42:24 +0200
|
||||
Subject: [PATCH] Fix configuration with Emscripten
|
||||
|
||||
In Emscripten there is no separate libm library, so there is no need to explicitly link it,
|
||||
and in particular the find_library call would fail as there is not libm to find.
|
||||
See https://stackoverflow.com/questions/24663915/how-can-i-link-libm-to-my-emscripten-port
|
||||
---
|
||||
src/CMakeLists.txt | 2 +-
|
||||
1 file changed, 1 insertion(+), 1 deletion(-)
|
||||
|
||||
diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt
|
||||
index 1407080..357ed76 100644
|
||||
--- a/src/CMakeLists.txt
|
||||
+++ b/src/CMakeLists.txt
|
||||
@@ -48,7 +48,7 @@ target_include_directories(ccd PUBLIC
|
||||
$<BUILD_INTERFACE:${CMAKE_CURRENT_SOURCE_DIR}>
|
||||
$<BUILD_INTERFACE:${CMAKE_CURRENT_BINARY_DIR}>)
|
||||
|
||||
-if(NOT WIN32)
|
||||
+if(NOT WIN32 AND NOT (CMAKE_SYSTEM_NAME STREQUAL "Emscripten"))
|
||||
find_library(LIBM_LIBRARY NAMES m)
|
||||
if(NOT LIBM_LIBRARY)
|
||||
message(FATAL_ERROR "Could NOT find required library LibM")
|
||||
7
externals/vcpkg/ports/ccd/vcpkg.json
vendored
Executable file
7
externals/vcpkg/ports/ccd/vcpkg.json
vendored
Executable file
@@ -0,0 +1,7 @@
|
||||
{
|
||||
"name": "ccd",
|
||||
"version-string": "2.1-4",
|
||||
"port-version": 3,
|
||||
"description": "Library for collision detection between two convex shapes",
|
||||
"homepage": "https://github.com/danfis/libccd"
|
||||
}
|
||||
Reference in New Issue
Block a user