From c69762c935663716676d0321c23c7789175be999 Mon Sep 17 00:00:00 2001 From: Osyotr Date: Sun, 24 Sep 2023 02:58:25 +0300 Subject: [PATCH 1/6] [assimp] Update to 5.3.0 --- ports/assimp/build_fixes.patch | 174 +++++++++++++++++++-------------- ports/assimp/portfile.cmake | 6 +- ports/assimp/vcpkg.json | 3 +- versions/a-/assimp.json | 5 + versions/baseline.json | 2 +- 5 files changed, 109 insertions(+), 81 deletions(-) diff --git a/ports/assimp/build_fixes.patch b/ports/assimp/build_fixes.patch index 93d007cd8730c5..8a4612b6e9f345 100644 --- a/ports/assimp/build_fixes.patch +++ b/ports/assimp/build_fixes.patch @@ -2,39 +2,19 @@ diff --git a/CMakeLists.txt b/CMakeLists.txt index 458a328..b8c2fc6 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt -@@ -56,7 +56,7 @@ IF(ASSIMP_HUNTER_ENABLED) - add_definitions(-DASSIMP_USE_HUNTER) - ENDIF() - --PROJECT(Assimp VERSION 5.2.4) -+PROJECT(Assimp VERSION 5.2.5) - - # All supported options ############################################### - -@@ -273,18 +273,18 @@ IF ((CMAKE_C_COMPILER_ID MATCHES "GNU") AND NOT MINGW) - ELSEIF(MSVC) - # enable multi-core compilation with MSVC - IF(CMAKE_CXX_COMPILER_ID MATCHES "Clang" ) # clang-cl -- ADD_COMPILE_OPTIONS(/bigobj /W4 /WX ) -+ ADD_COMPILE_OPTIONS(/bigobj ) - ELSE() # msvc -- ADD_COMPILE_OPTIONS(/MP /bigobj /W4 /WX) -+ ADD_COMPILE_OPTIONS(/MP /bigobj ) - ENDIF() - # disable "elements of array '' will be default initialized" warning on MSVC2013 - IF(MSVC12) - ADD_COMPILE_OPTIONS(/wd4351) +@@ -291,9 +291,9 @@ IF ((CMAKE_C_COMPILER_ID MATCHES "GNU") AND NOT MINGW) ENDIF() - ADD_COMPILE_OPTIONS(/wd4244) #supress warning for double to float conversion if Double precission is activated + # supress warning for double to float conversion if Double precission is activated + ADD_COMPILE_OPTIONS(/wd4244) - SET(CMAKE_CXX_FLAGS_DEBUG "${CMAKE_CXX_FLAGS_DEBUG} /D_DEBUG /Zi /Od") -- SET(CMAKE_CXX_FLAGS_RELEASE "${CMAKE_CXX_FLAGS_RELEASE} /Zi") +- SET(CMAKE_CXX_FLAGS_RELEASE "${CMAKE_CXX_FLAGS_RELEASE}") - SET(CMAKE_SHARED_LINKER_FLAGS_RELEASE "${CMAKE_SHARED_LINKER_FLAGS_RELEASE} /DEBUG:FULL /PDBALTPATH:%_PDB% /OPT:REF /OPT:ICF") + # SET(CMAKE_CXX_FLAGS_DEBUG "${CMAKE_CXX_FLAGS_DEBUG} /D_DEBUG /Zi /Od") -+ # SET(CMAKE_CXX_FLAGS_RELEASE "${CMAKE_CXX_FLAGS_RELEASE} /Zi") ++ # SET(CMAKE_CXX_FLAGS_RELEASE "${CMAKE_CXX_FLAGS_RELEASE}") + # SET(CMAKE_SHARED_LINKER_FLAGS_RELEASE "${CMAKE_SHARED_LINKER_FLAGS_RELEASE} /DEBUG:FULL /PDBALTPATH:%_PDB% /OPT:REF /OPT:ICF") ELSEIF (CMAKE_CXX_COMPILER_ID MATCHES "Clang" ) IF(NOT ASSIMP_HUNTER_ENABLED) - SET(CMAKE_CXX_STANDARD 17) + SET(CMAKE_POSITION_INDEPENDENT_CODE ON) @@ -418,7 +418,7 @@ ENDIF() set(GENERATED_DIR "${CMAKE_CURRENT_BINARY_DIR}/generated") @@ -98,15 +78,15 @@ index 6551dcb..0796448 100644 +include(CMakeFindDependencyMacro) + +find_dependency(pugixml CONFIG) ++find_dependency(utf8cpp CONFIG) # https://github.com/assimp/assimp/issues/5247 +if(NOT @BUILD_SHARED_LIBS@) + find_dependency(kubazip CONFIG) + find_dependency(minizip CONFIG) + #find_dependency(openddlparser CONFIG) + find_dependency(poly2tri CONFIG) -+ #find_dependency(polyclipping CONFIG) ++ find_dependency(polyclipping CONFIG) + find_dependency(RapidJSON CONFIG) + find_dependency(Stb MODULE) -+ find_dependency(utf8cpp CONFIG) + find_dependency(ZLIB) +endif() + @@ -130,28 +110,30 @@ diff --git a/code/AssetLib/Blender/BlenderTessellator.h b/code/AssetLib/Blender/ index 0d0ba32..c3703c4 100644 --- a/code/AssetLib/Blender/BlenderTessellator.h +++ b/code/AssetLib/Blender/BlenderTessellator.h -@@ -147,7 +147,7 @@ namespace Assimp - #ifdef ASSIMP_USE_HUNTER - # include - #else --# include "../contrib/poly2tri/poly2tri/poly2tri.h" -+# include - #endif +@@ -143,7 +143,7 @@ namespace Assimp + + #if ASSIMP_BLEND_WITH_POLY_2_TRI + +-#include "contrib/poly2tri/poly2tri/poly2tri.h" ++#include namespace Assimp + { diff --git a/code/AssetLib/IFC/IFCGeometry.cpp b/code/AssetLib/IFC/IFCGeometry.cpp index ef59542..17e00cd 100644 --- a/code/AssetLib/IFC/IFCGeometry.cpp +++ b/code/AssetLib/IFC/IFCGeometry.cpp -@@ -53,7 +53,7 @@ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - # include - # include - #else --# include "../contrib/poly2tri/poly2tri/poly2tri.h" -+# include - # include "../contrib/clipper/clipper.hpp" - #endif - +@@ -45,8 +45,8 @@ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + #include "IFCUtil.h" + #include "Common/PolyTools.h" + #include "PostProcessing/ProcessHelper.h" +-#include "contrib/poly2tri/poly2tri/poly2tri.h" +-#include "contrib/clipper/clipper.hpp" ++#include ++#include + + #include + #include diff --git a/code/AssetLib/IFC/IFCLoader.cpp b/code/AssetLib/IFC/IFCLoader.cpp index 0c20686..e6b20a3 100644 --- a/code/AssetLib/IFC/IFCLoader.cpp @@ -169,15 +151,17 @@ diff --git a/code/AssetLib/IFC/IFCOpenings.cpp b/code/AssetLib/IFC/IFCOpenings.c index 3c4a0b3..3fab616 100644 --- a/code/AssetLib/IFC/IFCOpenings.cpp +++ b/code/AssetLib/IFC/IFCOpenings.cpp -@@ -53,7 +53,7 @@ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - # include - # include - #else --# include "../contrib/poly2tri/poly2tri/poly2tri.h" -+# include - # include "../contrib/clipper/clipper.hpp" - #endif - +@@ -47,7 +47,7 @@ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + #include "IFCUtil.h" + #include "Common/PolyTools.h" + #include "PostProcessing/ProcessHelper.h" +-#include "contrib/poly2tri/poly2tri/poly2tri.h" +-#include "contrib/clipper/clipper.hpp" ++#include ++#include + + #include + #include diff --git a/code/AssetLib/MMD/MMDPmxParser.cpp b/code/AssetLib/MMD/MMDPmxParser.cpp index ca37ba1..2ce7bdd 100644 --- a/code/AssetLib/MMD/MMDPmxParser.cpp @@ -232,7 +216,7 @@ index 5339454..45e07c0 100644 find_package(pugixml CONFIG REQUIRED) ELSE() SET( Pugixml_SRCS -@@ -910,15 +910,15 @@ ELSE() +@@ -919,30 +919,30 @@ ELSE() ENDIF() # utf8 @@ -246,24 +230,38 @@ index 5339454..45e07c0 100644 ENDIF() # polyclipping --IF(ASSIMP_HUNTER_ENABLED) -+IF(0) - hunter_add_package(polyclipping) - find_package(polyclipping CONFIG REQUIRED) - ELSE() -@@ -930,8 +930,8 @@ ELSE() - ENDIF() +-#IF(ASSIMP_HUNTER_ENABLED) ++IF(1) + # hunter_add_package(polyclipping) +-# find_package(polyclipping CONFIG REQUIRED) +-#ELSE() ++ find_package(polyclipping CONFIG REQUIRED) ++ELSE() + SET( Clipper_SRCS + ../contrib/clipper/clipper.hpp + ../contrib/clipper/clipper.cpp + ) + SOURCE_GROUP( Contrib\\Clipper FILES ${Clipper_SRCS}) +-#ENDIF() ++ENDIF() # poly2tri --IF(ASSIMP_HUNTER_ENABLED) -- hunter_add_package(poly2tri) +-#IF(ASSIMP_HUNTER_ENABLED) +IF(1) -+ #hunter_add_package(poly2tri) - find_package(poly2tri CONFIG REQUIRED) - ELSE() + # hunter_add_package(poly2tri) +-# find_package(poly2tri CONFIG REQUIRED) +-#ELSE() ++ find_package(poly2tri CONFIG REQUIRED) ++ELSE() SET( Poly2Tri_SRCS -@@ -951,8 +951,8 @@ ELSE() - ENDIF() + ../contrib/poly2tri/poly2tri/common/shapes.cc + ../contrib/poly2tri/poly2tri/common/shapes.h +@@ -957,11 +957,11 @@ ELSE() + ../contrib/poly2tri/poly2tri/sweep/sweep_context.h + ) + SOURCE_GROUP( Contrib\\Poly2Tri FILES ${Poly2Tri_SRCS}) +-#ENDIF() ++ENDIF() # minizip/unzip -IF(ASSIMP_HUNTER_ENABLED) @@ -377,20 +375,22 @@ index 5339454..45e07c0 100644 +IF(1) TARGET_LINK_LIBRARIES(assimp - PUBLIC -- polyclipping::polyclipping +- #polyclipping::polyclipping - openddlparser::openddl_parser + PRIVATE -+ #polyclipping::polyclipping ++ polyclipping::polyclipping + #openddlparser::openddl_parser + ${OPENDDL_PARSER_LIBRARIES} - poly2tri::poly2tri +- #poly2tri::poly2tri ++ poly2tri::poly2tri minizip::minizip - ZLIB::zlib - RapidJSON::rapidjson +- utf8cpp + ZLIB::ZLIB + rapidjson - utf8cpp + PUBLIC ++ utf8cpp # https://github.com/assimp/assimp/issues/5247 pugixml - stb::stb ) @@ -463,8 +463,8 @@ index 5339454..45e07c0 100644 # Add RT-extension library for glTF importer with Open3DGC-compression. IF (RT_FOUND AND ASSIMP_IMPORTER_GLTF_USE_OPEN3DGC) -- TARGET_LINK_LIBRARIES(assimp ${RT_LIBRARY}) -+ TARGET_LINK_LIBRARIES(assimp PRIVATE ${RT_LIBRARY}) +- TARGET_LINK_LIBRARIES(assimp rt) ++ TARGET_LINK_LIBRARIES(assimp PRIVATE rt) ENDIF () @@ -472,8 +472,17 @@ diff --git a/code/Common/StbCommon.h b/code/Common/StbCommon.h index 1265d25..18f4564 100644 --- a/code/Common/StbCommon.h +++ b/code/Common/StbCommon.h -@@ -48,7 +48,7 @@ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - #pragma GCC diagnostic ignored "-Wunused-function" +@@ -53,7 +53,7 @@ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + #pragma clang diagnostic ignored "-Wunused-function" + #endif + +-#ifndef STB_USE_HUNTER ++#if 0 + /* Use prefixed names for the symbols from stb_image as it is a very commonly embedded library. + Including vanilla stb_image symbols causes duplicate symbol problems if assimp is linked + statically together with another library or executable that also embeds stb_image. +@@ -111,7 +111,7 @@ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + #define stbi_zlib_decode_noheader_malloc assimp_stbi_zlib_decode_noheader_malloc #endif -#include "stb/stb_image.h" @@ -507,3 +516,16 @@ index 3d5c72e..770cb9d 100644 #endif namespace Assimp { +diff --git a/include/assimp/types.h b/include/assimp/types.h +index 72e3d5c..b9d770c 100644 +--- a/include/assimp/types.h ++++ b/include/assimp/types.h +@@ -73,7 +73,7 @@ + + #ifdef __cplusplus + +-#ifdef ASSIMP_USE_HUNTER ++#if 1 + # include + #else + # include "../contrib/utf8cpp/source/utf8.h" diff --git a/ports/assimp/portfile.cmake b/ports/assimp/portfile.cmake index babb0153ece867..e1f2750fc9c186 100644 --- a/ports/assimp/portfile.cmake +++ b/ports/assimp/portfile.cmake @@ -1,8 +1,8 @@ vcpkg_from_github( OUT_SOURCE_PATH SOURCE_PATH REPO assimp/assimp - REF v5.2.5 - SHA512 ac0dc4243f9d1ff077966f0037187b4374075ac97e75e1a3cd6bdc1caf5f8e4d40953d9a8a316480969c09524d87daa9d3ed75e6ac6f037dd5b1c5f25fce3afb + REF v${VERSION} + SHA512 805842736a4129c5afec5327b04e9795e99a0252ef2bbafbd018cf4d3351fffd95a10f93348adb48f2765bd4264741b8a3888cfda27dda72ded21cc2c2c7bce5 HEAD_REF master PATCHES build_fixes.patch @@ -10,7 +10,7 @@ vcpkg_from_github( file(REMOVE "${SOURCE_PATH}/cmake-modules/FindZLIB.cmake") -#file(REMOVE_RECURSE "${SOURCE_PATH}/contrib/clipper") # https://github.com/assimp/assimp/issues/788 +file(REMOVE_RECURSE "${SOURCE_PATH}/contrib/clipper") file(REMOVE_RECURSE "${SOURCE_PATH}/contrib/draco") file(REMOVE_RECURSE "${SOURCE_PATH}/contrib/gtest") #file(REMOVE_RECURSE "${SOURCE_PATH}/contrib/Open3DGC") #TODO diff --git a/ports/assimp/vcpkg.json b/ports/assimp/vcpkg.json index 95a8179be3db88..717f855e5f53ce 100644 --- a/ports/assimp/vcpkg.json +++ b/ports/assimp/vcpkg.json @@ -1,6 +1,6 @@ { "name": "assimp", - "version": "5.2.5", + "version": "5.3.0", "description": "The Open Asset import library", "homepage": "https://github.com/assimp/assimp", "license": "BSD-3-Clause", @@ -9,6 +9,7 @@ "kubazip", "minizip", "poly2tri", + "polyclipping", "pugixml", "rapidjson", "stb", diff --git a/versions/a-/assimp.json b/versions/a-/assimp.json index a150b0743acfd1..82339cb86fe254 100644 --- a/versions/a-/assimp.json +++ b/versions/a-/assimp.json @@ -1,5 +1,10 @@ { "versions": [ + { + "git-tree": "a3e5f554ac5c8d2b41da33b27f2bfd223e0b6040", + "version": "5.3.0", + "port-version": 0 + }, { "git-tree": "bdd963b2ef327bf5e8533689aff4707226e22851", "version": "5.2.5", diff --git a/versions/baseline.json b/versions/baseline.json index 8d0eba2358db1d..528e8db214e32f 100644 --- a/versions/baseline.json +++ b/versions/baseline.json @@ -265,7 +265,7 @@ "port-version": 1 }, "assimp": { - "baseline": "5.2.5", + "baseline": "5.3.0", "port-version": 0 }, "async-mqtt": { From d7aaa4400fa351f35bd1085a187bdff53f9d623a Mon Sep 17 00:00:00 2001 From: Osyotr Date: Sun, 24 Sep 2023 14:28:52 +0300 Subject: [PATCH 2/6] Remove from public include --- ports/assimp/build_fixes.patch | 11 ++++++----- versions/a-/assimp.json | 2 +- 2 files changed, 7 insertions(+), 6 deletions(-) diff --git a/ports/assimp/build_fixes.patch b/ports/assimp/build_fixes.patch index 8a4612b6e9f345..f4a48c0077f081 100644 --- a/ports/assimp/build_fixes.patch +++ b/ports/assimp/build_fixes.patch @@ -78,7 +78,6 @@ index 6551dcb..0796448 100644 +include(CMakeFindDependencyMacro) + +find_dependency(pugixml CONFIG) -+find_dependency(utf8cpp CONFIG) # https://github.com/assimp/assimp/issues/5247 +if(NOT @BUILD_SHARED_LIBS@) + find_dependency(kubazip CONFIG) + find_dependency(minizip CONFIG) @@ -87,6 +86,7 @@ index 6551dcb..0796448 100644 + find_dependency(polyclipping CONFIG) + find_dependency(RapidJSON CONFIG) + find_dependency(Stb MODULE) ++ find_dependency(utf8cpp CONFIG) + find_dependency(ZLIB) +endif() + @@ -386,11 +386,10 @@ index 5339454..45e07c0 100644 minizip::minizip - ZLIB::zlib - RapidJSON::rapidjson -- utf8cpp + ZLIB::ZLIB + rapidjson + utf8cpp + PUBLIC -+ utf8cpp # https://github.com/assimp/assimp/issues/5247 pugixml - stb::stb ) @@ -520,12 +519,14 @@ diff --git a/include/assimp/types.h b/include/assimp/types.h index 72e3d5c..b9d770c 100644 --- a/include/assimp/types.h +++ b/include/assimp/types.h -@@ -73,7 +73,7 @@ +@@ -73,8 +73,8 @@ #ifdef __cplusplus -#ifdef ASSIMP_USE_HUNTER +-# include +#if 1 - # include ++//# include #else # include "../contrib/utf8cpp/source/utf8.h" + #endif diff --git a/versions/a-/assimp.json b/versions/a-/assimp.json index 82339cb86fe254..82909bf8bd7c13 100644 --- a/versions/a-/assimp.json +++ b/versions/a-/assimp.json @@ -1,7 +1,7 @@ { "versions": [ { - "git-tree": "a3e5f554ac5c8d2b41da33b27f2bfd223e0b6040", + "git-tree": "0ce631b222d3b7dca98e6ac9649a16b9fd5edf41", "version": "5.3.0", "port-version": 0 }, From 2009c8c609bdd9e8cfc8d0dd38da49751769bd04 Mon Sep 17 00:00:00 2001 From: Osyotr Date: Tue, 26 Sep 2023 00:31:39 +0300 Subject: [PATCH 3/6] [assimp] fix pkg-config for static builds --- ports/assimp/portfile.cmake | 17 +++++++++++++++-- versions/a-/assimp.json | 2 +- 2 files changed, 16 insertions(+), 3 deletions(-) diff --git a/ports/assimp/portfile.cmake b/ports/assimp/portfile.cmake index e1f2750fc9c186..3d56daa66403cf 100644 --- a/ports/assimp/portfile.cmake +++ b/ports/assimp/portfile.cmake @@ -66,9 +66,22 @@ if(ASSIMP_DBG) get_filename_component(ASSIMP_NAME_DBG "${ASSIMP_DBG}" NAME_WLE) vcpkg_replace_string("${CURRENT_PACKAGES_DIR}/debug/lib/pkgconfig/assimp.pc" "-lassimp" "-l${ASSIMP_NAME_DBG}") endif() -vcpkg_fixup_pkgconfig() # Probably requires more fixing for static builds. See qt5-3d and the config changes below + +if("${VCPKG_LIBRARY_LINKAGE}" STREQUAL "static") + set(assimp_PC_REQUIRES "draco polyclipping pugixml minizip") + set(assimp_LIBS_REQUIRES "-lpoly2tri") + + vcpkg_replace_string("${CURRENT_PACKAGES_DIR}/lib/pkgconfig/assimp.pc" "Libs:" "Requires.private: ${assimp_PC_REQUIRES}\nLibs:") + vcpkg_replace_string("${CURRENT_PACKAGES_DIR}/lib/pkgconfig/assimp.pc" "Libs.private:" "Libs.private: ${assimp_LIBS_REQUIRES}") + if(NOT VCPKG_BUILD_TYPE) + vcpkg_replace_string("${CURRENT_PACKAGES_DIR}/debug/lib/pkgconfig/assimp.pc" "Libs:" "Requires.private: ${assimp_PC_REQUIRES}\nLibs:") + vcpkg_replace_string("${CURRENT_PACKAGES_DIR}/debug/lib/pkgconfig/assimp.pc" "Libs.private:" "Libs.private: ${assimp_LIBS_REQUIRES}") + endif() +endif() + +vcpkg_fixup_pkgconfig() file(REMOVE_RECURSE "${CURRENT_PACKAGES_DIR}/debug/include") file(REMOVE_RECURSE "${CURRENT_PACKAGES_DIR}/debug/share") -file(INSTALL "${SOURCE_PATH}/LICENSE" DESTINATION "${CURRENT_PACKAGES_DIR}/share/${PORT}" RENAME copyright) +vcpkg_install_copyright(FILE_LIST "${SOURCE_PATH}/LICENSE") diff --git a/versions/a-/assimp.json b/versions/a-/assimp.json index 82909bf8bd7c13..679402cbfea5db 100644 --- a/versions/a-/assimp.json +++ b/versions/a-/assimp.json @@ -1,7 +1,7 @@ { "versions": [ { - "git-tree": "0ce631b222d3b7dca98e6ac9649a16b9fd5edf41", + "git-tree": "1a66a4e6d18a3af6b6ec0e2dc82d9a0d299b28a7", "version": "5.3.0", "port-version": 0 }, From 4fb1328ea40c086b1a2160075a03cbfd22d8317e Mon Sep 17 00:00:00 2001 From: Osyotr Date: Tue, 26 Sep 2023 00:33:26 +0300 Subject: [PATCH 4/6] [qt5-3d] Use pkgconfig to find assimp --- ports/qt5-3d/portfile.cmake | 51 +++---------------------------------- ports/qt5-3d/vcpkg.json | 7 ++++- versions/baseline.json | 2 +- versions/q-/qt5-3d.json | 5 ++++ 4 files changed, 16 insertions(+), 49 deletions(-) diff --git a/ports/qt5-3d/portfile.cmake b/ports/qt5-3d/portfile.cmake index 95815d67196785..842418a20191a7 100644 --- a/ports/qt5-3d/portfile.cmake +++ b/ports/qt5-3d/portfile.cmake @@ -1,53 +1,10 @@ -include(${CURRENT_INSTALLED_DIR}/share/qt5/qt_port_functions.cmake) +include("${CURRENT_INSTALLED_DIR}/share/qt5/qt_port_functions.cmake") set(OPTIONS -system-assimp) -if(VCPKG_TARGET_IS_WINDOWS) - set(VCVER vc140 vc141 vc142 vc143 ) - set(CRT mt md) - set(DBG_NAMES) - set(REL_NAMES) - foreach(_ver IN LISTS VCVER) - foreach(_crt IN LISTS CRT) - list(APPEND DBG_NAMES assimp-${_ver}-${_crt}d) - list(APPEND REL_NAMES assimp-${_ver}-${_crt}) - endforeach() - endforeach() -endif() +x_vcpkg_pkgconfig_get_modules(PREFIX assimp MODULES assimp LIBS) -find_library(ASSIMP_REL NAMES assimp ${REL_NAMES} PATHS "${CURRENT_INSTALLED_DIR}/lib" NO_DEFAULT_PATH) -find_library(ASSIMP_DBG NAMES assimp assimpd ${DBG_NAMES} PATHS "${CURRENT_INSTALLED_DIR}/debug/lib" NO_DEFAULT_PATH) - -find_library(MINIZIP_REL NAMES minizip PATHS "${CURRENT_INSTALLED_DIR}/lib" NO_DEFAULT_PATH) -find_library(MINIZIP_DBG NAMES minizip minizipd PATHS "${CURRENT_INSTALLED_DIR}/debug/lib" NO_DEFAULT_PATH) -find_library(KUBAZIP_REL NAMES kubazip PATHS "${CURRENT_INSTALLED_DIR}/lib" NO_DEFAULT_PATH) -find_library(KUBAZIP_DBG NAMES kubazip kubazipd PATHS "${CURRENT_INSTALLED_DIR}/debug/lib" NO_DEFAULT_PATH) -find_library(JPEG_REL NAMES jpeg jpeg-static PATHS "${CURRENT_INSTALLED_DIR}/lib" NO_DEFAULT_PATH) -find_library(JPEG_DBG NAMES jpeg jpeg-static jpegd jpeg-staticd PATHS "${CURRENT_INSTALLED_DIR}/debug/lib" NO_DEFAULT_PATH) -find_library(LIBPNG_REL NAMES png16 libpng16 PATHS "${CURRENT_INSTALLED_DIR}/lib" NO_DEFAULT_PATH) #Depends on zlib -find_library(LIBPNG_DBG NAMES png16 png16d libpng16 libpng16d PATHS "${CURRENT_INSTALLED_DIR}/debug/lib" NO_DEFAULT_PATH) -find_library(ZLIB_REL NAMES z zlib PATHS "${CURRENT_INSTALLED_DIR}/lib" NO_DEFAULT_PATH) -find_library(ZLIB_DBG NAMES z zlib zd zlibd PATHS "${CURRENT_INSTALLED_DIR}/debug/lib" NO_DEFAULT_PATH) -find_library(PUGIXML_REL NAMES pugixml PATHS "${CURRENT_INSTALLED_DIR}/lib" NO_DEFAULT_PATH) -find_library(PUGIXML_DBG NAMES pugixml pugixmld PATHS "${CURRENT_INSTALLED_DIR}/debug/lib" NO_DEFAULT_PATH) -find_library(POLY2TRI_REL NAMES poly2tri PATHS "${CURRENT_INSTALLED_DIR}/lib" NO_DEFAULT_PATH) -find_library(POLY2TRI_DBG NAMES poly2tri poly2trid PATHS "${CURRENT_INSTALLED_DIR}/debug/lib" NO_DEFAULT_PATH) -find_library(BZ2_REL bz2 PATHS "${CURRENT_INSTALLED_DIR}/lib" NO_DEFAULT_PATH) -find_library(BZ2_DBG bz2 bz2d PATHS "${CURRENT_INSTALLED_DIR}/debug/lib" NO_DEFAULT_PATH) -if(BZ2_REL) - string(APPEND MINIZIP_REL " ${BZ2_REL}") -endif() -if(BZ2_DBG) - string(APPEND MINIZIP_DBG " ${BZ2_DBG}") -endif() -if(VCPKG_TARGET_IS_WINDOWS) - set(SYSTEM_LIBS "Advapi32.lib user32.lib gdi32.lib") -elseif(VCPKG_TARGET_IS_OSX) - set(SYSTEM_LIBS "-framework OpenGL -framework Cocoa -framework Carbon -framework IOKit -framework AppKit") -else() - set(SYSTEM_LIBS "-lGL -lXxf86vm -lX11") -endif() -set(OPT_REL "ASSIMP_LIBS=${ASSIMP_REL} ${PUGIXML_REL} ${POLY2TRI_REL} ${JPEG_REL} ${LIBPNG_REL} ${KUBAZIP_REL} ${MINIZIP_REL} ${ZLIB_REL} ${SYSTEM_LIBS}") -set(OPT_DBG "ASSIMP_LIBS=${ASSIMP_DBG} ${PUGIXML_DBG} ${POLY2TRI_DBG} ${JPEG_DBG} ${LIBPNG_DBG} ${KUBAZIP_DBG} ${MINIZIP_DBG} ${ZLIB_DBG} ${SYSTEM_LIBS}") +set(OPT_REL "ASSIMP_LIBS=${assimp_LIBS_RELEASE}") +set(OPT_DBG "ASSIMP_LIBS=${assimp_LIBS_DEBUG}") qt_submodule_installation(BUILD_OPTIONS ${OPTIONS} BUILD_OPTIONS_RELEASE ${OPT_REL} BUILD_OPTIONS_DEBUG ${OPT_DBG}) diff --git a/ports/qt5-3d/vcpkg.json b/ports/qt5-3d/vcpkg.json index 782d5d1c914761..e43904ccdcff2f 100644 --- a/ports/qt5-3d/vcpkg.json +++ b/ports/qt5-3d/vcpkg.json @@ -1,6 +1,7 @@ { "name": "qt5-3d", "version": "5.15.10", + "port-version": 1, "description": "Qt5 3d Module - Functionality for near-realtime simulation systems with support for 2D and 3D rendering", "license": null, "dependencies": [ @@ -11,6 +12,10 @@ }, "qt5-declarative", "qt5-gamepad", - "qt5-imageformats" + "qt5-imageformats", + { + "name": "vcpkg-pkgconfig-get-modules", + "host": true + } ] } diff --git a/versions/baseline.json b/versions/baseline.json index 528e8db214e32f..1b15a7a2d71471 100644 --- a/versions/baseline.json +++ b/versions/baseline.json @@ -6734,7 +6734,7 @@ }, "qt5-3d": { "baseline": "5.15.10", - "port-version": 0 + "port-version": 1 }, "qt5-activeqt": { "baseline": "5.15.10", diff --git a/versions/q-/qt5-3d.json b/versions/q-/qt5-3d.json index 6b3eddc47d02fc..ec5e76fdb9072c 100644 --- a/versions/q-/qt5-3d.json +++ b/versions/q-/qt5-3d.json @@ -1,5 +1,10 @@ { "versions": [ + { + "git-tree": "be8daf4a45d4f87e7867bd9110ba974c3db3aa00", + "version": "5.15.10", + "port-version": 1 + }, { "git-tree": "3476fd00f9a99f7993cb70835c78fc9d998f1974", "version": "5.15.10", From c56a534c1469e9314dc39733c7d94d623da30116 Mon Sep 17 00:00:00 2001 From: Osyotr Date: Tue, 26 Sep 2023 02:59:03 +0300 Subject: [PATCH 5/6] [assimp] -llibassimp -> -lassimp --- ports/assimp/portfile.cmake | 4 +++- versions/a-/assimp.json | 2 +- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/ports/assimp/portfile.cmake b/ports/assimp/portfile.cmake index 3d56daa66403cf..e45debaba4dc49 100644 --- a/ports/assimp/portfile.cmake +++ b/ports/assimp/portfile.cmake @@ -56,14 +56,16 @@ if(VCPKG_TARGET_IS_WINDOWS) endforeach() endif() -find_library(ASSIMP_REL NAMES assimp ${REL_NAMES} PATHS "${CURRENT_PACKAGES_DIR}/lib" NO_DEFAULT_PATH) +find_library(ASSIMP_REL NAMES assimp ${REL_NAMES} PATHS "${CURRENT_PACKAGES_DIR}/lib" NO_DEFAULT_PATH) find_library(ASSIMP_DBG NAMES assimp assimpd ${DBG_NAMES} PATHS "${CURRENT_PACKAGES_DIR}/debug/lib" NO_DEFAULT_PATH) if(ASSIMP_REL) get_filename_component(ASSIMP_NAME_REL "${ASSIMP_REL}" NAME_WLE) + string(REGEX REPLACE "^lib(.*)" "\\1" ASSIMP_NAME_REL "${ASSIMP_NAME_REL}") vcpkg_replace_string("${CURRENT_PACKAGES_DIR}/lib/pkgconfig/assimp.pc" "-lassimp" "-l${ASSIMP_NAME_REL}") endif() if(ASSIMP_DBG) get_filename_component(ASSIMP_NAME_DBG "${ASSIMP_DBG}" NAME_WLE) + string(REGEX REPLACE "^lib(.*)" "\\1" ASSIMP_NAME_DBG "${ASSIMP_NAME_DBG}") vcpkg_replace_string("${CURRENT_PACKAGES_DIR}/debug/lib/pkgconfig/assimp.pc" "-lassimp" "-l${ASSIMP_NAME_DBG}") endif() diff --git a/versions/a-/assimp.json b/versions/a-/assimp.json index 679402cbfea5db..493854d60baae6 100644 --- a/versions/a-/assimp.json +++ b/versions/a-/assimp.json @@ -1,7 +1,7 @@ { "versions": [ { - "git-tree": "1a66a4e6d18a3af6b6ec0e2dc82d9a0d299b28a7", + "git-tree": "23a9005a3a158c7442a00fe84ff3a643970b3ea7", "version": "5.3.0", "port-version": 0 }, From 3cb23df0cfc1a43d59654502b495515aa69b7c58 Mon Sep 17 00:00:00 2001 From: Osyotr Date: Thu, 28 Sep 2023 10:41:29 +0300 Subject: [PATCH 6/6] [assimp] Update to 5.3.1 --- ports/assimp/build_fixes.patch | 15 --------------- ports/assimp/portfile.cmake | 2 +- ports/assimp/vcpkg.json | 2 +- versions/a-/assimp.json | 4 ++-- versions/baseline.json | 2 +- 5 files changed, 5 insertions(+), 20 deletions(-) diff --git a/ports/assimp/build_fixes.patch b/ports/assimp/build_fixes.patch index f4a48c0077f081..6d4a878722f5b9 100644 --- a/ports/assimp/build_fixes.patch +++ b/ports/assimp/build_fixes.patch @@ -515,18 +515,3 @@ index 3d5c72e..770cb9d 100644 #endif namespace Assimp { -diff --git a/include/assimp/types.h b/include/assimp/types.h -index 72e3d5c..b9d770c 100644 ---- a/include/assimp/types.h -+++ b/include/assimp/types.h -@@ -73,8 +73,8 @@ - - #ifdef __cplusplus - --#ifdef ASSIMP_USE_HUNTER --# include -+#if 1 -+//# include - #else - # include "../contrib/utf8cpp/source/utf8.h" - #endif diff --git a/ports/assimp/portfile.cmake b/ports/assimp/portfile.cmake index e45debaba4dc49..6b0867ecd48788 100644 --- a/ports/assimp/portfile.cmake +++ b/ports/assimp/portfile.cmake @@ -2,7 +2,7 @@ vcpkg_from_github( OUT_SOURCE_PATH SOURCE_PATH REPO assimp/assimp REF v${VERSION} - SHA512 805842736a4129c5afec5327b04e9795e99a0252ef2bbafbd018cf4d3351fffd95a10f93348adb48f2765bd4264741b8a3888cfda27dda72ded21cc2c2c7bce5 + SHA512 49963f84ed0a8145f3af249890a533f0b12f5553ae09581289cb1f20cb49cb1a3ed3f3c4c966ceb43aa897b90deca268aa6554066b2bd34f2ac9c15041420ddb HEAD_REF master PATCHES build_fixes.patch diff --git a/ports/assimp/vcpkg.json b/ports/assimp/vcpkg.json index 717f855e5f53ce..72899aa58a2b48 100644 --- a/ports/assimp/vcpkg.json +++ b/ports/assimp/vcpkg.json @@ -1,6 +1,6 @@ { "name": "assimp", - "version": "5.3.0", + "version": "5.3.1", "description": "The Open Asset import library", "homepage": "https://github.com/assimp/assimp", "license": "BSD-3-Clause", diff --git a/versions/a-/assimp.json b/versions/a-/assimp.json index 493854d60baae6..f6bd7699ab3355 100644 --- a/versions/a-/assimp.json +++ b/versions/a-/assimp.json @@ -1,8 +1,8 @@ { "versions": [ { - "git-tree": "23a9005a3a158c7442a00fe84ff3a643970b3ea7", - "version": "5.3.0", + "git-tree": "f9934603cb6f42343b122951f22b5af3c1967cde", + "version": "5.3.1", "port-version": 0 }, { diff --git a/versions/baseline.json b/versions/baseline.json index 0457c37aa01144..a1edecf3dd4919 100644 --- a/versions/baseline.json +++ b/versions/baseline.json @@ -265,7 +265,7 @@ "port-version": 1 }, "assimp": { - "baseline": "5.3.0", + "baseline": "5.3.1", "port-version": 0 }, "async-mqtt": {