early-access version 2853

This commit is contained in:
pineappleEA
2022-07-23 03:01:36 +02:00
parent 1f2b5081b5
commit 1f111bb69c
8955 changed files with 418777 additions and 999 deletions

View File

@@ -0,0 +1,45 @@
# Distributed under the OSI-approved BSD 3-Clause License.
#.rst:
# FindCLIPPER
# --------
#
# Result Variables
# ^^^^^^^^^^^^^^^^
#
# This module will set the following variables in your project::
#
# ``CLIPPER_FOUND``
# True if CLIPPER found on the local system
#
# ``CLIPPER_INCLUDE_DIRS``
# Location of CLIPPER header files.
#
# ``CLIPPER_LIBRARIES``
# The clipper libraries.
#
include(FindPackageHandleStandardArgs)
include(SelectLibraryConfigurations)
if(NOT CLIPPER_INCLUDE_DIR)
find_path(CLIPPER_INCLUDE_DIR clipper.hpp
PATH_SUFFIXES polyclipping)
endif()
if(NOT CLIPPER_LIBRARY)
find_library(CLIPPER_LIBRARY_RELEASE NAMES polyclipping PATHS "${CMAKE_CURRENT_LIST_DIR}/../../lib" NO_DEFAULT_PATH)
find_library(CLIPPER_LIBRARY_DEBUG NAMES polyclipping PATHS "${CMAKE_CURRENT_LIST_DIR}/../../debug/lib" NO_DEFAULT_PATH)
select_library_configurations(CLIPPER)
endif()
mark_as_advanced(CLIPPER_LIBRARY CLIPPER_INCLUDE_DIR)
find_package_handle_standard_args(CLIPPER
REQUIRED_VARS CLIPPER_LIBRARY CLIPPER_INCLUDE_DIR
)
if(CLIPPER_FOUND)
set(CLIPPER_LIBRARIES ${CLIPPER_LIBRARY})
set(CLIPPER_INCLUDE_DIRS ${CLIPPER_INCLUDE_DIR})
endif()

View File

@@ -0,0 +1,17 @@
diff --git a/cpp/CMakeLists.txt b/cpp/CMakeLists.txt
index f0ed7e8..a5ed444 100644
--- a/cpp/CMakeLists.txt
+++ b/cpp/CMakeLists.txt
@@ -19,3 +19,12 @@ INSTALL (TARGETS polyclipping LIBRARY DESTINATION "${CMAKE_INSTALL_LIBDIR}")
INSTALL (FILES "${PCFILE}" DESTINATION "${CMAKE_INSTALL_PKGCONFIGDIR}")
SET_TARGET_PROPERTIES(polyclipping PROPERTIES VERSION 22.0.0 SOVERSION 22 )
+
+install(TARGETS polyclipping EXPORT polyclippingConfig)
+
+install(
+ EXPORT polyclippingConfig
+ NAMESPACE polyclipping::
+ DESTINATION share/polyclipping
+)
+target_include_directories(polyclipping PUBLIC $<INSTALL_INTERFACE:include>)

View File

@@ -0,0 +1,37 @@
vcpkg_check_linkage(ONLY_STATIC_LIBRARY)
vcpkg_from_sourceforge(
OUT_SOURCE_PATH SOURCE_PATH
REPO polyclipping
FILENAME "clipper_ver6.4.2.zip"
NO_REMOVE_ONE_LEVEL
SHA512 ffc88818c44a38aa278d5010db6cfd505796f39664919f1e48c7fa9267563f62135868993e88f7246dcd688241d1172878e4a008a390648acb99738452e3e5dd
PATCHES
fix_targets.patch
)
vcpkg_configure_cmake(
SOURCE_PATH ${SOURCE_PATH}/cpp
PREFER_NINJA
)
vcpkg_install_cmake()
vcpkg_fixup_cmake_targets()
if(NOT DEFINED VCPKG_BUILD_TYPE OR VCPKG_BUILD_TYPE STREQUAL "debug")
file(RENAME "${CURRENT_PACKAGES_DIR}/debug/share/pkgconfig" "${CURRENT_PACKAGES_DIR}/debug/lib/pkgconfig")
endif()
if(NOT DEFINED VCPKG_BUILD_TYPE OR VCPKG_BUILD_TYPE STREQUAL "release")
file(RENAME "${CURRENT_PACKAGES_DIR}/share/pkgconfig" "${CURRENT_PACKAGES_DIR}/lib/pkgconfig")
endif()
vcpkg_fixup_pkgconfig()
file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/debug/include)
file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/debug/share)
file(INSTALL ${CMAKE_CURRENT_LIST_DIR}/FindCLIPPER.cmake DESTINATION ${CURRENT_PACKAGES_DIR}/share/clipper)
file(INSTALL ${CMAKE_CURRENT_LIST_DIR}/vcpkg-cmake-wrapper.cmake DESTINATION ${CURRENT_PACKAGES_DIR}/share/clipper)
file(INSTALL ${SOURCE_PATH}/License.txt DESTINATION ${CURRENT_PACKAGES_DIR}/share/${PORT} RENAME copyright)
vcpkg_fixup_pkgconfig()

View File

@@ -0,0 +1,10 @@
list(REMOVE_ITEM ARGS "NO_MODULE")
list(REMOVE_ITEM ARGS "CONFIG")
list(REMOVE_ITEM ARGS "MODULE")
set(clipper_PREV_MODULE_PATH ${CMAKE_MODULE_PATH})
list(APPEND CMAKE_MODULE_PATH ${CMAKE_CURRENT_LIST_DIR})
_find_package(${ARGS})
set(CMAKE_MODULE_PATH ${clipper_PREV_MODULE_PATH})

View File

@@ -0,0 +1,7 @@
{
"name": "polyclipping",
"version-string": "6.4.2",
"port-version": 10,
"description": "The Clipper library performs clipping and offsetting for both lines and polygons. All four boolean clipping operations are supported - intersection, union, difference and exclusive-or. Polygons can be of any shape including self-intersecting polygons.",
"homepage": "https://sourceforge.net/projects/polyclipping/"
}