Skip to content

Commit

Permalink
[sol2] Update, fix, don't build anything (microsoft#35545)
Browse files Browse the repository at this point in the history
  • Loading branch information
dg0yt authored Dec 8, 2023
1 parent 0b5d4f2 commit a20e828
Show file tree
Hide file tree
Showing 6 changed files with 29 additions and 41 deletions.
17 changes: 0 additions & 17 deletions ports/sol2/fix-namespace.patch

This file was deleted.

13 changes: 13 additions & 0 deletions ports/sol2/header-only.patch
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 120dd38..0b069dc 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -174,7 +174,7 @@ else()
endif()

# # # Tests, Examples and other CI suites that come with sol2
-if (sol2-is-top-level-project)
+if (0)
# # # General project output locations
if (CMAKE_SIZEOF_VOID_P EQUAL 4)
set(CMAKE_ARCHIVE_OUTPUT_DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}/x86/lib")
27 changes: 9 additions & 18 deletions ports/sol2/portfile.cmake
Original file line number Diff line number Diff line change
@@ -1,28 +1,19 @@
vcpkg_from_github(
OUT_SOURCE_PATH SOURCE_PATH
REPO ThePhD/sol2
REF eba86625b707e3c8c99bbfc4624e51f42dc9e561 #v3.3.0
SHA512 a1fbcb4efd9a8b8b97c351e90499644aea72a3db62c258e219a2912853936b76870b51e69d835c14cbf1a20733673ba474e259a0243fec419c411b995cd1511d
REF "v${VERSION}"
SHA512 4404b124a4f331d77459c01a92cd73895301e7d3ef829a0285980f0138b9cc66782de3713d54f017d5aad7d8a11d23eeffbc5f3b39ccb4d4306a955711d385dd
HEAD_REF develop
PATCHES fix-namespace.patch
)

vcpkg_cmake_configure(
SOURCE_PATH "${SOURCE_PATH}"
PATCHES
header-only.patch
)

set(VCPKG_BUILD_TYPE release) # header-only
vcpkg_cmake_configure(SOURCE_PATH "${SOURCE_PATH}")
vcpkg_cmake_install()
vcpkg_cmake_config_fixup(CONFIG_PATH lib/cmake/sol2)
vcpkg_fixup_pkgconfig()

file(
REMOVE_RECURSE
"${CURRENT_PACKAGES_DIR}/debug"
"${CURRENT_PACKAGES_DIR}/lib"
"${CURRENT_PACKAGES_DIR}/include"
)

file(INSTALL "${SOURCE_PATH}/include/sol" DESTINATION "${CURRENT_PACKAGES_DIR}/include/")

file(INSTALL "${SOURCE_PATH}/LICENSE.txt" DESTINATION "${CURRENT_PACKAGES_DIR}/share/${PORT}" RENAME copyright)
file(REMOVE_RECURSE "${CURRENT_PACKAGES_DIR}/lib")

vcpkg_fixup_pkgconfig()
vcpkg_install_copyright(FILE_LIST "${SOURCE_PATH}/LICENSE.txt")
6 changes: 1 addition & 5 deletions ports/sol2/vcpkg.json
Original file line number Diff line number Diff line change
@@ -1,14 +1,10 @@
{
"name": "sol2",
"version": "3.3.0",
"version": "3.3.1",
"description": "Sol v2.0 - a C++ <-> Lua API wrapper with advanced features and top notch performance - is here, and it's great",
"homepage": "https://github.com/ThePhD/sol2",
"license": "MIT",
"dependencies": [
{
"name": "lua",
"platform": "windows"
},
{
"name": "vcpkg-cmake",
"host": true
Expand Down
2 changes: 1 addition & 1 deletion versions/baseline.json
Original file line number Diff line number Diff line change
Expand Up @@ -8013,7 +8013,7 @@
"port-version": 0
},
"sol2": {
"baseline": "3.3.0",
"baseline": "3.3.1",
"port-version": 0
},
"solid3": {
Expand Down
5 changes: 5 additions & 0 deletions versions/s-/sol2.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,10 @@
{
"versions": [
{
"git-tree": "803f41c884606248b07d343e13716c1135da7957",
"version": "3.3.1",
"port-version": 0
},
{
"git-tree": "115cb8217bb876cfb71fadec889faa25954db8b1",
"version": "3.3.0",
Expand Down

0 comments on commit a20e828

Please sign in to comment.