-
Notifications
You must be signed in to change notification settings - Fork 6.7k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[wxwidgets] update to 3.1.6 (#24483)
* [wxwidgets] update to 3.1.6 * Revise nanosvg * Add feature control and dependencies for sound * Add descripton for feature sound * Update versions * Update ports/wxwidgets/vcpkg.json Co-authored-by: LilyWangLL <[email protected]> * Fix spacing and version * Remove cmake push/pop * Bump version * Undo change in wrapper * bump version * restore newline * bump version Co-authored-by: Kai Pastor <[email protected]> Co-authored-by: Billy Robert O'Neal <[email protected]> Co-authored-by: LilyWangLL <[email protected]>
- Loading branch information
1 parent
d331773
commit aec505b
Showing
13 changed files
with
173 additions
and
101 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
cmake_minimum_required(VERSION 3.11) | ||
project(nanosvg NONE) | ||
|
||
set(NANOSVG_HEADERS src/nanosvg.h src/nanosvgrast.h) | ||
add_library(nanosvg INTERFACE) | ||
|
||
set_target_properties(nanosvg PROPERTIES PUBLIC_HEADER "${NANOSVG_HEADERS}") | ||
|
||
install(TARGETS nanosvg | ||
EXPORT nanosvgTargets | ||
PUBLIC_HEADER DESTINATION include) | ||
|
||
install(EXPORT nanosvgTargets | ||
FILE unofficial-nanosvg-config.cmake | ||
NAMESPACE unofficial::nanosvg:: | ||
DESTINATION share/unofficial-nanosvg) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
vcpkg_from_github( | ||
OUT_SOURCE_PATH SOURCE_PATH | ||
REPO memononen/nanosvg | ||
REF 03042a6297399379198f98eb625ff8902bd84784 | ||
SHA512 163f205e81e830e8b2512ec1faa15ebaf82138fc8bd881ccfc5f19896df75e8cf77ccd20892fccd0fd3e5d6358438e6f3075fd4e6a4c4b064107451265c9f874 | ||
HEAD_REF master | ||
) | ||
|
||
file(COPY "${CMAKE_CURRENT_LIST_DIR}/CMakeLists.txt" DESTINATION "${SOURCE_PATH}") | ||
|
||
set(VCPKG_BUILD_TYPE "release") # header-only | ||
vcpkg_cmake_configure(SOURCE_PATH "${SOURCE_PATH}") | ||
vcpkg_cmake_install() | ||
|
||
file(INSTALL "${SOURCE_PATH}/LICENSE.txt" DESTINATION "${CURRENT_PACKAGES_DIR}/share/${PORT}" RENAME copyright) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
{ | ||
"name": "nanosvg", | ||
"version-date": "2022-04-29", | ||
"description": "NanoSVG is a simple stupid single-header-file SVG parse. The output of the parser is a list of cubic bezier shapes..", | ||
"homepage": "https://github.com/memononen/nanosvg", | ||
"license": "Zlib", | ||
"dependencies": [ | ||
{ | ||
"name": "vcpkg-cmake", | ||
"host": true | ||
} | ||
] | ||
} |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,36 +1,21 @@ | ||
diff --git a/build/cmake/config.cmake b/build/cmake/config.cmake | ||
index 91d11ac..2791466 100644 | ||
--- a/build/cmake/config.cmake | ||
+++ b/build/cmake/config.cmake | ||
@@ -41,7 +41,30 @@ macro(wx_get_dependencies var lib) | ||
endif() | ||
set(dep_name "-l${dep_name}") | ||
else() | ||
- get_filename_component(dep_name ${dep} NAME) | ||
+ # For the value like $<$<CONFIG:DEBUG>:LIB_PATH> | ||
+ # Or $<$<NOT:$<CONFIG:DEBUG>>:LIB_PATH> | ||
+ if(dep MATCHES "^(.+>):(.+)>$") | ||
+ if(CMAKE_BUILD_TYPE STREQUAL "Debug" AND CMAKE_MATCH_1 STREQUAL [[$<$<NOT:$<CONFIG:DEBUG>>]]) | ||
+ continue() | ||
+ elseif(CMAKE_BUILD_TYPE STREQUAL "Release" AND CMAKE_MATCH_1 STREQUAL [[$<$<CONFIG:DEBUG>]]) | ||
+ continue() | ||
+ endif() | ||
+ set(dep_name "${CMAKE_MATCH_2}") | ||
+ else() | ||
+ set(dep_name ${dep}) | ||
+ endif() | ||
+ endif() | ||
+ if(dep_name STREQUAL "libc.so") | ||
+ continue() # don't include this library | ||
+ elseif(dep_name MATCHES "^-") # -l, -framework, -weak_framework | ||
+ # ok | ||
+ elseif(dep_name MATCHES "^lib(.*)(.so|.dylib|.tbd|.a)$") | ||
+ set(dep_name "-l${CMAKE_MATCH_1} ") | ||
+ elseif(dep_name) | ||
+ get_filename_component(abs_path ${dep_name} PATH) | ||
+ if (NOT abs_path) | ||
+ set(dep_name "-l${dep_name} ") | ||
+ endif() | ||
endif() | ||
wx_string_append(${var} "${dep_name} ") | ||
endforeach() | ||
diff --git a/build/cmake/config.cmake b/build/cmake/config.cmake | ||
index 52ae69d3f6..f261d5d262 100644 | ||
--- a/build/cmake/config.cmake | ||
+++ b/build/cmake/config.cmake | ||
@@ -39,8 +39,14 @@ macro(wx_get_dependencies var lib) | ||
else() | ||
# For the value like $<$<CONFIG:DEBUG>:LIB_PATH> | ||
# Or $<$<NOT:$<CONFIG:DEBUG>>:LIB_PATH> | ||
- string(REGEX REPLACE "^.+>:(.+)>$" "\\1" dep_name ${dep}) | ||
- if (NOT dep_name) | ||
+ if(dep MATCHES "^(.+>):(.+)>$") | ||
+ if(CMAKE_BUILD_TYPE STREQUAL "Debug" AND CMAKE_MATCH_1 STREQUAL [[$<$<NOT:$<CONFIG:DEBUG>>]]) | ||
+ continue() | ||
+ elseif(CMAKE_BUILD_TYPE STREQUAL "Release" AND CMAKE_MATCH_1 STREQUAL [[$<$<CONFIG:DEBUG>]]) | ||
+ continue() | ||
+ endif() | ||
+ set(dep_name "${CMAKE_MATCH_2}") | ||
+ else() | ||
set(dep_name ${dep}) | ||
endif() | ||
endif() |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,35 @@ | ||
diff --git a/build/cmake/init.cmake b/build/cmake/init.cmake | ||
index 8c9275974f..3758261299 100644 | ||
--- a/build/cmake/init.cmake | ||
+++ b/build/cmake/init.cmake | ||
@@ -615,3 +615,6 @@ if(wxBUILD_PRECOMP) | ||
wx_option_force_value(wxBUILD_PRECOMP OFF) | ||
endif() | ||
endif(wxBUILD_PRECOMP) | ||
+ | ||
+find_package(unofficial-nanosvg CONFIG REQUIRED) | ||
+list(APPEND wxTOOLKIT_LIBRARIES unofficial::nanosvg::nanosvg) | ||
diff --git a/src/generic/bmpsvg.cpp b/src/generic/bmpsvg.cpp | ||
index 76f20dce4c..7a7c24b4dd 100644 | ||
--- a/src/generic/bmpsvg.cpp | ||
+++ b/src/generic/bmpsvg.cpp | ||
@@ -26,7 +26,7 @@ | ||
// your source tree doesn't contain 3rdparty/nanosvg and you should initialize | ||
// and update the corresponding submodule. | ||
#ifdef __has_include | ||
- #if ! __has_include("../../3rdparty/nanosvg/src/nanosvg.h") | ||
+ #if 0 | ||
#error You need to run "git submodule update --init 3rdparty/nanosvg". | ||
#undef wxHAS_SVG | ||
#endif | ||
@@ -60,8 +60,8 @@ | ||
#define NANOSVG_IMPLEMENTATION | ||
#define NANOSVGRAST_IMPLEMENTATION | ||
#define NANOSVG_ALL_COLOR_KEYWORDS | ||
-#include "../../3rdparty/nanosvg/src/nanosvg.h" | ||
-#include "../../3rdparty/nanosvg/src/nanosvgrast.h" | ||
+#include <nanosvg.h> | ||
+#include <nanosvgrast.h> | ||
|
||
#ifdef __VISUALC__ | ||
#pragma warning(pop) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
{ | ||
"versions": [ | ||
{ | ||
"git-tree": "827223ed18553b608489e328101549261d0c9d5a", | ||
"version-date": "2022-04-29", | ||
"port-version": 0 | ||
} | ||
] | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters