[ freetype2/harfbuzz/sdl2] Update to the latest version (#22586)

* [freetype2] Update to 2.11.1

* [harfbuzz] Update to 3.2.0

* [sdl2] Update to 2.0.20

* [ffmpeg] Update to 5.0

* Update versions.

* [ffmpeg] Remove all avresample

* Update ffmpeg.json

* Update ffmpeg.json

* Update ffmpeg.json

* Revert "[ffmpeg] Update to 5.0"

This reverts commit d4f718e882fe022f641b68e154e8cf64776c4143.

* Revert "[ffmpeg] Remove all avresample"

This reverts commit f1fecaa8cfa5b7f42fbef0897312028dc88b0ec8.

* update

* fix revert.

* [sdl2] Fix uwp build.

* Update sdl2.json
This commit is contained in:
Matthew Oliver 2022-01-27 10:32:31 +11:00 committed by GitHub
parent c4afc3f492
commit 9eb76edabf
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
19 changed files with 118 additions and 243 deletions

View File

@ -1,152 +0,0 @@
diff --git a/src/autofit/afglobal.c b/src/autofit/afglobal.c
index aedb74ddd..5d53dfb71 100644
--- a/src/autofit/afglobal.c
+++ b/src/autofit/afglobal.c
@@ -19,6 +19,7 @@
#include "afglobal.h"
#include "afranges.h"
#include "afshaper.h"
+#include "afws_dec.h"
#include <freetype/internal/ftdebug.h>
@@ -32,11 +33,6 @@
#define FT_COMPONENT afglobal
- /* get writing system specific header files */
-#undef WRITING_SYSTEM
-#define WRITING_SYSTEM( ws, WS ) /* empty */
-#include "afwrtsys.h"
-
#include "aferrors.h"
@@ -74,7 +70,7 @@
af_writing_system_classes[] =
{
-#include "afwrtsys.h"
+#include "afws_itr.h"
NULL /* do not remove */
};
diff --git a/src/autofit/aftypes.h b/src/autofit/aftypes.h
index e76b103ed..a036a0f56 100644
--- a/src/autofit/aftypes.h
+++ b/src/autofit/aftypes.h
@@ -198,7 +198,6 @@ extern void* _af_debug_hints;
* outline according to the results of the glyph analyzer.
*/
-#define AFWRTSYS_H_ /* don't load header files */
#undef WRITING_SYSTEM
#define WRITING_SYSTEM( ws, WS ) \
AF_WRITING_SYSTEM_ ## WS,
@@ -207,14 +206,12 @@ extern void* _af_debug_hints;
typedef enum AF_WritingSystem_
{
-#include "afwrtsys.h"
+#include "afws_itr.h"
AF_WRITING_SYSTEM_MAX /* do not remove */
} AF_WritingSystem;
-#undef AFWRTSYS_H_
-
typedef struct AF_WritingSystemClassRec_
{
diff --git a/src/autofit/afws_dec.h b/src/autofit/afws_dec.h
new file mode 100644
index 000000000..39e707c5a
--- /dev/null
+++ b/src/autofit/afws_dec.h
@@ -0,0 +1,30 @@
+/****************************************************************************
+ *
+ * afws_dec.h
+ *
+ * Auto-fitter writing systems (specification only).
+ *
+ * Copyright (C) 2013-2021 by
+ * David Turner, Robert Wilhelm, and Werner Lemberg.
+ *
+ * This file is part of the FreeType project, and may only be used,
+ * modified, and distributed under the terms of the FreeType project
+ * license, LICENSE.TXT. By continuing to use, modify, or distribute
+ * this file you indicate that you have read the license and
+ * understand and accept it fully.
+ *
+ */
+
+
+#ifndef AFWS_DEC_H_
+#define AFWS_DEC_H_
+
+ /* Since preprocessor directives can't create other preprocessor */
+ /* directives, we have to include the header files manually. */
+
+#include "afdummy.h"
+#include "aflatin.h"
+#include "afcjk.h"
+#include "afindic.h"
+
+#endif /* AFWS_DEC_H_ */
diff --git a/src/autofit/afwrtsys.h b/src/autofit/afws_itr.h
similarity index 66%
rename from src/autofit/afwrtsys.h
rename to src/autofit/afws_itr.h
index 39aa12112..2da77d459 100644
--- a/src/autofit/afwrtsys.h
+++ b/src/autofit/afws_itr.h
@@ -1,6 +1,6 @@
/****************************************************************************
*
- * afwrtsys.h
+ * afws_itr.h
*
* Auto-fitter writing systems (specification only).
*
@@ -15,23 +15,8 @@
*
*/
-
-#ifndef AFWRTSYS_H_
-#define AFWRTSYS_H_
-
- /* Since preprocessor directives can't create other preprocessor */
- /* directives, we have to include the header files manually. */
-
-#include "afdummy.h"
-#include "aflatin.h"
-#include "afcjk.h"
-#include "afindic.h"
-
-#endif /* AFWRTSYS_H_ */
-
-
- /* The following part can be included multiple times. */
- /* Define `WRITING_SYSTEM' as needed. */
+ /* This header may be included multiple times. */
+ /* Define `WRITING_SYSTEM' as needed. */
/* Add new writing systems here. The arguments are the writing system */
diff --git a/src/autofit/rules.mk b/src/autofit/rules.mk
index 19b3bcadb..a5438ecba 100644
--- a/src/autofit/rules.mk
+++ b/src/autofit/rules.mk
@@ -48,7 +48,8 @@ AUTOF_DRV_H := $(AUTOF_DRV_SRC:%c=%h) \
$(AUTOF_DIR)/afscript.h \
$(AUTOF_DIR)/afstyles.h \
$(AUTOF_DIR)/aftypes.h \
- $(AUTOF_DIR)/afwrtsys.h
+ $(AUTOF_DIR)/afws_dec.h \
+ $(AUTOF_DIR)/afws_itr.h
# AUTOF driver object(s)

View File

@ -1,36 +1,35 @@
set(FT_VERSION 2.11.0)
set(FT_VERSION 2.11.1)
vcpkg_from_sourceforge(
OUT_SOURCE_PATH SOURCE_PATH
REPO freetype/freetype2
REF ${FT_VERSION}
FILENAME freetype-${FT_VERSION}.tar.xz
SHA512 bf1991f3c382832586be1d21ae73c20840ee8546807ba60d0eb0215134545656c0c8de488f27357d4a4f6497d7cb540998cda98ec59061a3e640036fb209147d
SHA512 0848678482fbe20603a866f02da82c91122014d6f815ba4f1d9c03601c32e3ceb781f721c2b4427b6117d7c9742018af8dbb26566faf018595c70b50f8db3f08
PATCHES
0003-Fix-UWP.patch
fix-bzip2-pc.patch # we have a bzip2 file that we can use - https://gitlab.freedesktop.org/freetype/freetype/-/commit/b2aeca5fda870751f3c9d645e0dca4c80fa1ae5a
brotli-static.patch
fix-exports.patch
fix-2.11-msvc-build.patch
)
vcpkg_check_features(OUT_FEATURE_OPTIONS FEATURE_OPTIONS
FEATURES
zlib FT_WITH_ZLIB
bzip2 FT_WITH_BZIP2
png FT_WITH_PNG
brotli FT_WITH_BROTLI
zlib FT_REQUIRE_ZLIB
bzip2 FT_REQUIRE_BZIP2
png FT_REQUIRE_PNG
brotli FT_REQUIRE_BROTLI
INVERTED_FEATURES
zlib CMAKE_DISABLE_FIND_PACKAGE_ZLIB
bzip2 CMAKE_DISABLE_FIND_PACKAGE_BZip2
png CMAKE_DISABLE_FIND_PACKAGE_PNG
brotli CMAKE_DISABLE_FIND_PACKAGE_BrotliDec
zlib FT_DISABLE_ZLIB
bzip2 FT_DISABLE_BZIP2
png FT_DISABLE_PNG
brotli FT_DISABLE_BROTLI
)
vcpkg_cmake_configure(
SOURCE_PATH "${SOURCE_PATH}"
OPTIONS
-DCMAKE_DISABLE_FIND_PACKAGE_HarfBuzz=ON
-DFT_DISABLE_HARFBUZZ=ON
${FEATURE_OPTIONS}
)

View File

@ -1,7 +1,6 @@
{
"name": "freetype",
"version-semver": "2.11.0",
"port-version": 2,
"version-semver": "2.11.1",
"description": "A library to render fonts.",
"homepage": "https://www.freetype.org/",
"dependencies": [

View File

@ -1,8 +1,8 @@
vcpkg_from_github(
OUT_SOURCE_PATH SOURCE_PATH
REPO harfbuzz/harfbuzz
REF 3.0.0
SHA512 69999ad86bde56ef689392a521143b6ad14b6719860772c3d4c343358997049a48c79e8f302fe0a7f3b0d930b476ddf440def874a1269b50ae79d020bcd073b5
REF 3.2.0
SHA512 5d8c629416c0bc557b83e8d9d731d41b9e8ee3abc74590e65ed6ca67d74d3a440d038134313f17a7b1b14ef0fc1ecf8bb87113fdcf5f0c8d3dc3d2eeb9b08c18
HEAD_REF master
PATCHES
# This patch is a workaround that is needed until the following issues are resolved upstream:

View File

@ -1,7 +1,6 @@
{
"name": "harfbuzz",
"version-semver": "3.0.0",
"port-version": 1,
"version-semver": "3.2.0",
"description": "HarfBuzz OpenType text shaping engine",
"homepage": "https://github.com/harfbuzz/harfbuzz",
"dependencies": [

View File

@ -1,14 +1,14 @@
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -2348,7 +2348,6 @@
execute_process(COMMAND sh ${SDL2_SOURCE_DIR}/build-scripts/updaterev.sh
WORKING_DIRECTORY ${SDL2_BINARY_DIR})
endif()
@@ -2555,7 +2555,6 @@ endif()
configure_file("${SDL2_SOURCE_DIR}/include/SDL_revision.h.cmake"
"${SDL2_BINARY_DIR}/include/SDL_revision.h")
-if(NOT WINDOWS OR CYGWIN OR MINGW)
set(prefix ${CMAKE_INSTALL_PREFIX})
@@ -2375,7 +2375,7 @@
@@ -2590,7 +2590,7 @@ Libs.private:")
set(SDL_STATIC_LIBS ${_SDL_STATIC_LIBS})
listtostrrev(SDL_LIBS _SDL_LIBS)
set(SDL_LIBS ${_SDL_LIBS})
@ -17,7 +17,7 @@
listtostr(EXTRA_LIBS _EXTRA_LIBS "-l")
set(SDL_STATIC_LIBS ${SDL_LIBS} ${EXTRA_LDFLAGS} ${_EXTRA_LIBS})
list(REMOVE_DUPLICATES SDL_STATIC_LIBS)
@@ -2403,7 +2403,6 @@
@@ -2611,7 +2611,6 @@ Libs.private:")
"${SDL2_BINARY_DIR}/sdl2-config" @ONLY)
configure_file("${SDL2_SOURCE_DIR}/SDL2.spec.in"
"${SDL2_BINARY_DIR}/SDL2.spec" @ONLY)
@ -25,11 +25,12 @@
macro(check_add_debug_flag FLAG SUFFIX)
check_c_compiler_flag(${FLAG} HAS_C_FLAG_${SUFFIX})
@@ -2728,6 +2728,7 @@
@@ -2956,6 +2956,7 @@ if(NOT (WINDOWS OR CYGWIN) OR MINGW)
# TODO: what about the .spec file? Is it only needed for RPM creation?
install(FILES "${SDL2_SOURCE_DIR}/sdl2.m4" DESTINATION "${CMAKE_INSTALL_FULL_DATAROOTDIR}/aclocal")
install(FILES "${SDL2_SOURCE_DIR}/sdl2.m4" DESTINATION "${CMAKE_INSTALL_DATAROOTDIR}/aclocal")
endif()
+install(FILES ${SDL2_BINARY_DIR}/sdl2.pc DESTINATION "lib${LIB_SUFFIX}/pkgconfig")
##### Uninstall target #####

View File

@ -1,15 +1,15 @@
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -1295,12 +1295,6 @@
@@ -1342,12 +1342,6 @@ elseif(UNIX AND NOT APPLE AND NOT ANDROID AND NOT RISCOS AND NOT HAIKU)
set(HAVE_FCITX TRUE)
endif()
- pkg_search_module(IBUS ibus-1.0 ibus)
- if(IBUS_FOUND)
- set(HAVE_IBUS_IBUS_H TRUE)
- include_directories(${IBUS_INCLUDE_DIRS})
- target_include_directories(sdl-build-options INTERFACE "${IBUS_INCLUDE_DIRS}")
- list(APPEND EXTRA_LIBS ${IBUS_LIBRARIES})
- endif()
if (HAVE_IBUS_IBUS_H OR HAVE_FCITX)
set(SDL_USE_IME TRUE)
set(SDL_USE_IME 1)

View File

@ -1,6 +1,6 @@
--- a/SDL2Config.cmake
+++ b/SDL2Config.cmake
@@ -32,6 +2,7 @@
@@ -46,6 +46,7 @@ foreach(prop ${relprops})
endif()
endforeach()
@ -8,7 +8,7 @@
foreach(prop ${relprops})
get_target_property(sdl2mainimplib SDL2::SDL2main ${prop})
if(sdl2mainimplib)
@@ -37,6 +37,7 @@
@@ -53,6 +54,7 @@ foreach(prop ${relprops})
break()
endif()
endforeach()
@ -16,7 +16,7 @@
foreach(prop ${dbgprops})
get_target_property(sdl2implibdbg SDL2::SDL2 ${prop})
@@ -47,6 +47,7 @@
@@ -62,6 +64,7 @@ foreach(prop ${dbgprops})
endif()
endforeach()
@ -24,7 +24,7 @@
foreach(prop ${dbgprops})
get_target_property(sdl2mainimplibdbg SDL2::SDL2main ${prop})
if(sdl2mainimplibdbg)
@@ -55,6 +55,7 @@
@@ -69,6 +72,7 @@ foreach(prop ${dbgprops})
break()
endif()
endforeach()

View File

@ -0,0 +1,15 @@
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -602,6 +602,11 @@ if(USE_GCC OR USE_CLANG)
list(APPEND EXTRA_CFLAGS -fcolor-diagnostics)
endif()
endif()
endif()
+if(MSVC)
+ target_compile_definitions(sdl-build-options INTERFACE "-D_CRT_SECURE_NO_DEPRECATE")
+ target_compile_definitions(sdl-build-options INTERFACE "-D_CRT_NONSTDC_NO_DEPRECATE")
+ target_compile_definitions(sdl-build-options INTERFACE "-D_CRT_SECURE_NO_WARNINGS")
+endif()
if(SDL_ASSEMBLY)

View File

@ -1,20 +0,0 @@
--- a/SDL2Config.cmake
+++ b/SDL2Config.cmake
@@ -1,5 +1,17 @@
include("${CMAKE_CURRENT_LIST_DIR}/SDL2Targets.cmake")
+# on static-only builds create an alias
+if(NOT TARGET SDL2::SDL2 AND TARGET SDL2::SDL2-static)
+ if(CMAKE_VERSION VERSION_LESS "3.11")
+ message(FATAL_ERROR "At least CMake 3.11 is required for this configuration.")
+ elseif(CMAKE_VERSION VERSION_LESS "3.18")
+ # Aliasing local targets is not supported on CMake < 3.18, so make all targets global.
+ set_target_properties(SDL2::SDL2-static PROPERTIES IMPORTED_GLOBAL TRUE)
+ set_target_properties(SDL2::SDL2main PROPERTIES IMPORTED_GLOBAL TRUE)
+ endif()
+ add_library(SDL2::SDL2 ALIAS SDL2::SDL2-static)
+endif()
+
# provide ${SDL2_LIBRARIES}, ${SDL2_INCLUDE_DIRS} etc, like sdl2-config.cmake does,
# for compatibility between SDL2 built with autotools and SDL2 built with CMake

View File

@ -0,0 +1,25 @@
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -1755,8 +1755,10 @@ elseif(WINDOWS)
list(APPEND EXTRA_LIBS dinput8)
endif()
if(HAVE_XINPUT_H)
- set(SDL_JOYSTICK_XINPUT 1)
- set(HAVE_XINPUT TRUE)
+ if(NOT WINDOWS_STORE)
+ set(SDL_JOYSTICK_XINPUT 1)
+ set(HAVE_XINPUT TRUE)
+ endif()
if(HAVE_WINDOWS_GAMING_INPUT_H)
set(SDL_JOYSTICK_WGI 1)
endif()
@@ -1764,7 +1766,7 @@ elseif(WINDOWS)
set(HAVE_SDL_JOYSTICK TRUE)
if(SDL_HAPTIC)
- if(HAVE_DINPUT_H OR HAVE_XINPUT_H)
+ if((HAVE_DINPUT_H OR HAVE_XINPUT_H) AND NOT WINDOWS_STORE)
file(GLOB HAPTIC_SOURCES ${SDL2_SOURCE_DIR}/src/haptic/windows/*.c)
if(HAVE_DINPUT_H)
set(SDL_HAPTIC_DINPUT 1)

View File

@ -1,21 +0,0 @@
diff --git a/CMakeLists.txt b/CMakeLists.txt
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -1475,7 +1475,7 @@ elseif(WINDOWS)
if(DEFINED MSVC_VERSION AND NOT ${MSVC_VERSION} LESS 1700)
set(USE_WINSDK_DIRECTX TRUE)
endif()
- if(NOT CMAKE_COMPILER_IS_MINGW AND NOT USE_WINSDK_DIRECTX)
+ if(NOT MINGW AND NOT USE_WINSDK_DIRECTX)
if("$ENV{DXSDK_DIR}" STREQUAL "")
message_error("DIRECTX requires the \$DXSDK_DIR environment variable to be set")
endif()
@@ -1493,7 +1493,7 @@ elseif(WINDOWS)
check_include_file(dxgi.h HAVE_DXGI_H)
if(HAVE_D3D_H OR HAVE_D3D11_H OR HAVE_DDRAW_H OR HAVE_DSOUND_H OR HAVE_DINPUT_H)
set(HAVE_DIRECTX TRUE)
- if(NOT CMAKE_COMPILER_IS_MINGW AND NOT USE_WINSDK_DIRECTX)
+ if(NOT MINGW AND NOT USE_WINSDK_DIRECTX)
# TODO: change $ENV{DXSDL_DIR} to get the path from the include checks
link_directories($ENV{DXSDK_DIR}\\lib\\${PROCESSOR_ARCH})
include_directories($ENV{DXSDK_DIR}\\Include)

View File

@ -0,0 +1,15 @@
--- a/src/misc/winrt/SDL_sysurl.cpp
+++ b/src/misc/winrt/SDL_sysurl.cpp
@@ -18,10 +18,9 @@
misrepresented as being the original software.
3. This notice may not be removed or altered from any source distribution.
*/
-#include <windows.h>
-#include "../../core/windows/SDL_windows.h"
#include "../SDL_sysurl.h"
+#include "../../core/windows/SDL_windows.h"
int
SDL_SYS_OpenURL(const char *url)

View File

@ -1,16 +1,17 @@
set(SDL2_VERSION 2.0.16)
set(SDL2_VERSION 2.0.20)
vcpkg_from_github(
OUT_SOURCE_PATH SOURCE_PATH
REPO libsdl-org/SDL
REF release-2.0.16
SHA512 45ce71f77b01f5fd886f92e5b3d96f1f72c7e0f70c09e615384a900533b941cad65bf6b54a125a9eeb8499e2056e9a8e54d4e654bccfca9730584792a2b18fbc
REF release-2.0.20
SHA512 f8558057a06d4507190b369b2067aee55c22ab796b90bb663fbc36218e66ec14e2feb0ecd55f9b798bfd24fc94e2b4cb93eddc52a59f0709d6cb0ebdb6d9309b
HEAD_REF master
PATCHES
0001-sdl2-Enable-creation-of-pkg-cfg-file-on-windows.patch
0002-sdl2-skip-ibus-on-linux.patch
0003-sdl2-disable-sdlmain-target-search-on-uwp.patch
0004-sdl2-alias-on-static-build.patch
0005-sdl2-fix-mingw-checks.patch # Can be removed once >= SDL 2.0.18
0004-Define-crt-macros.patch
0005-Fix-uwp-joystick.patch
0006-Update-SDL_sysurl.cpp.patch
)
string(COMPARE EQUAL "${VCPKG_LIBRARY_LINKAGE}" "static" SDL_STATIC)
@ -19,8 +20,8 @@ string(COMPARE EQUAL "${VCPKG_CRT_LINKAGE}" "static" FORCE_STATIC_VCRT)
vcpkg_check_features(OUT_FEATURE_OPTIONS FEATURE_OPTIONS
FEATURES
vulkan VIDEO_VULKAN
x11 X11_SHARED
vulkan SDL_VULKAN
x11 SDL_X11_SHARED
)
if ("x11" IN_LIST FEATURES)
@ -35,8 +36,8 @@ vcpkg_cmake_configure(
OPTIONS ${FEATURE_OPTIONS}
-DSDL_STATIC=${SDL_STATIC}
-DSDL_SHARED=${SDL_SHARED}
-DFORCE_STATIC_VCRT=${FORCE_STATIC_VCRT}
-DLIBC=ON
-DSDL_FORCE_STATIC_VCRT=${FORCE_STATIC_VCRT}
-DSDL_LIBC=ON
)
vcpkg_cmake_install()

View File

@ -1,7 +1,6 @@
{
"name": "sdl2",
"version": "2.0.16",
"port-version": 3,
"version": "2.0.20",
"description": "Simple DirectMedia Layer is a cross-platform development library designed to provide low level access to audio, keyboard, mouse, joystick, and graphics hardware via OpenGL and Direct3D.",
"homepage": "https://www.libsdl.org/download-2.0.php",
"dependencies": [

View File

@ -2289,8 +2289,8 @@
"port-version": 2
},
"freetype": {
"baseline": "2.11.0",
"port-version": 2
"baseline": "2.11.1",
"port-version": 0
},
"freetype-gl": {
"baseline": "2020-09-14",
@ -2669,8 +2669,8 @@
"port-version": 0
},
"harfbuzz": {
"baseline": "3.0.0",
"port-version": 1
"baseline": "3.2.0",
"port-version": 0
},
"hayai": {
"baseline": "2019-08-10",
@ -6261,8 +6261,8 @@
"port-version": 4
},
"sdl2": {
"baseline": "2.0.16",
"port-version": 3
"baseline": "2.0.20",
"port-version": 0
},
"sdl2-gfx": {
"baseline": "1.0.4",

View File

@ -1,5 +1,10 @@
{
"versions": [
{
"git-tree": "dadbf4b6e5f5670bf49489e26de326be6a72f962",
"version-semver": "2.11.1",
"port-version": 0
},
{
"git-tree": "9d21ff9f7071d83c1e04eca8cae21b99438400d8",
"version-semver": "2.11.0",

View File

@ -1,5 +1,10 @@
{
"versions": [
{
"git-tree": "a504ad46b9acfebdf6cc5e32bd0057d045f39115",
"version-semver": "3.2.0",
"port-version": 0
},
{
"git-tree": "151b8dba4351ec70354a0cc1485e5eb720df5f75",
"version-semver": "3.0.0",

View File

@ -1,5 +1,10 @@
{
"versions": [
{
"git-tree": "d5865b5fb9c52f255629f4c015f37df9ca788a33",
"version": "2.0.20",
"port-version": 0
},
{
"git-tree": "4d0926c154515596d8f178d7350c37433b05957b",
"version": "2.0.16",