Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
20 changes: 16 additions & 4 deletions ports/libiconv/vcpkg-cmake-wrapper.cmake
Original file line number Diff line number Diff line change
@@ -1,7 +1,19 @@
include(SelectLibraryConfigurations)

_find_package(${ARGS})
if(Iconv_FOUND AND NOT Iconv_IS_BUILT_IN)
include(SelectLibraryConfigurations)

set(Z_VCPKG_ICONV_USES_DARWIN_SDK FALSE)
if(APPLE AND CMAKE_OSX_SYSROOT AND EXISTS "${CMAKE_OSX_SYSROOT}/usr/include/iconv.h")
set(Z_VCPKG_ICONV_USES_DARWIN_SDK TRUE)
set(Iconv_IS_BUILT_IN FALSE CACHE BOOL "iconv requires a separate library")
if(NOT Iconv_INCLUDE_DIR)
set(Iconv_INCLUDE_DIR "${CMAKE_OSX_SYSROOT}/usr/include" CACHE PATH "iconv include directory")
endif()
if(NOT Iconv_LIBRARY)
set(Iconv_LIBRARY iconv CACHE STRING "iconv library")
endif()
endif()

_find_package(${ARGS})
if(Iconv_FOUND AND NOT Iconv_IS_BUILT_IN AND NOT Z_VCPKG_ICONV_USES_DARWIN_SDK)
find_path(CHARSET_INCLUDE_DIR NAMES "libcharset.h" HINTS "${_VCPKG_INSTALLED_DIR}/${VCPKG_TARGET_TRIPLET}/include")
find_library(CHARSET_LIBRARY_DEBUG NAMES charsetd libcharsetd charset libcharset NAMES_PER_DIR PATH_SUFFIXES lib HINTS "${_VCPKG_INSTALLED_DIR}/${VCPKG_TARGET_TRIPLET}/debug")
find_library(CHARSET_LIBRARY_RELEASE NAMES charset libcharset NAMES_PER_DIR PATH_SUFFIXES lib HINTS "${_VCPKG_INSTALLED_DIR}/${VCPKG_TARGET_TRIPLET}")
Expand Down
2 changes: 1 addition & 1 deletion ports/libiconv/vcpkg.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "libiconv",
"version": "1.18",
"port-version": 3,
"port-version": 4,
"description": [
"iconv() text conversion.",
"This port installs GNU libiconv if the system C runtime doesn't provide a suitable iconv() implementation."
Expand Down
33 changes: 28 additions & 5 deletions ports/openmpi/mpi-wrapper.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -11,14 +11,38 @@ if(NOT DEFINED MPI_HOME)
unset(z_vcpkg_mpiexec_directories)
endif()

# pkg-config in FindMPI.cmake works also in cross builds (when providing
# the pc files without the 'o' prefix, which is handled in port mpi.)
# Skip everything else.
# Seed FindMPI from vcpkg's OpenMPI layout. The pkg-config path remains
# available for metadata probing, including cross builds.
set(MPI_ASSUME_NO_BUILTIN_MPI TRUE)
set(MPI_SKIP_COMPILER_WRAPPER TRUE)
set(MPI_SKIP_GUESSING TRUE)

if(NOT MPI_C_INCLUDE_PATH)
set(MPI_C_INCLUDE_PATH "${MPI_HOME}/include" CACHE PATH "vcpkg" FORCE)
endif()
if(NOT MPI_CXX_INCLUDE_PATH)
set(MPI_CXX_INCLUDE_PATH "${MPI_HOME}/include" CACHE PATH "vcpkg" FORCE)
endif()
if(NOT MPI_C_LIB_NAMES)
set(MPI_C_LIB_NAMES mpi CACHE STRING "vcpkg" FORCE)
endif()
if(NOT MPI_CXX_LIB_NAMES)
set(MPI_CXX_LIB_NAMES mpi CACHE STRING "vcpkg" FORCE)
endif()
set(MPI_CXX_SKIP_MPICXX ON CACHE BOOL "vcpkg")

if(NOT DEFINED CMAKE_BUILD_TYPE OR CMAKE_BUILD_TYPE MATCHES "^[Dd][Ee][Bb][Uu][Gg]$")
set(z_vcpkg_mpi_library_dir "${MPI_HOME}/debug/lib")
else()
set(z_vcpkg_mpi_library_dir "${MPI_HOME}/lib")
endif()
if(NOT MPI_mpi_LIBRARY)
find_library(MPI_mpi_LIBRARY NAMES mpi PATHS "${z_vcpkg_mpi_library_dir}" NO_DEFAULT_PATH)
endif()
unset(z_vcpkg_mpi_library_dir)

find_program(PKG_CONFIG_EXECUTABLE NAMES pkg-config pkgconf PATHS "${VCPKG_INSTALLED_DIR}/@HOST_TRIPLET@/tools/bin" NO_DEFAULT_PATH)
find_package(PkgConfig)
find_program(PKG_CONFIG_EXECUTABLE PATHS "${VCPKG_INSTALLED_DIR}/@HOST_TRIPLET@/tools/bin")
set(z_vcpkg_mpiexec_pkg_config_path "$ENV{PKG_CONFIG_PATH}")
if(NOT DEFINED CMAKE_BUILD_TYPE OR CMAKE_BUILD_TYPE MATCHES "^[Dd][Ee][Bb][Uu][Gg]$")
set(ENV{PKG_CONFIG_PATH} "${VCPKG_INSTALLED_DIR}/@TARGET_TRIPLET@/debug/lib/pkgconfig")
Expand All @@ -33,4 +57,3 @@ _find_package(${ARGS})

set(ENV{PKG_CONFIG_PATH} "${z_vcpkg_mpiexec_pkg_config_path}")
unset(z_vcpkg_mpiexec_pkg_config_path)

1 change: 1 addition & 0 deletions ports/openmpi/vcpkg.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
{
"name": "openmpi",
"version": "4.1.8",
"port-version": 1,
"description": "The Open MPI Project is an open source Message Passing Interface implementation that is developed and maintained by a consortium of academic, research, and industry partners. Open MPI is therefore able to combine the expertise, technologies, and resources from all across the High Performance Computing community in order to build the best MPI library available. Open MPI offers advantages for system and software vendors, application developers and computer science researchers.",
"homepage": "https://www.open-mpi.org/",
"supports": "!windows",
Expand Down
10 changes: 9 additions & 1 deletion ports/qtbase/fix-libresolv-test.patch
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,15 @@ diff --git a/cmake/FindWrapResolv.cmake b/cmake/FindWrapResolv.cmake
index 159df9b..412a2ae 100644
--- a/cmake/FindWrapResolv.cmake
+++ b/cmake/FindWrapResolv.cmake
@@ -40,7 +40,7 @@ check_cxx_source_compiles("
@@ -18,4 +18,7 @@ if(QNX)
find_library(LIBRESOLV socket)
else()
find_library(LIBRESOLV resolv)
+ if(APPLE AND NOT LIBRESOLV)
+ set(LIBRESOLV resolv)
+ endif()
endif()
@@ -40,7 +43,7 @@ check_cxx_source_compiles("

int main(int, char **argv)
{
Expand Down
1 change: 1 addition & 0 deletions ports/qtbase/vcpkg.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
{
"name": "qtbase",
"version": "6.10.2",
"port-version": 1,
"description": "Qt Base (Core, Gui, Widgets, Network, ...)",
"homepage": "https://www.qt.io/",
"license": null,
Expand Down
1 change: 0 additions & 1 deletion scripts/ci.feature.baseline.txt
Original file line number Diff line number Diff line change
Expand Up @@ -1185,7 +1185,6 @@ qt5compat:arm64-linux=cascade
qt5compat[iconv](!(linux&arm64))=feature-fails # requires qtbase without icu
qtapplicationmanager:arm64-linux=cascade
qtbase[cups](linux)=feature-fails # requires CUPS system libs
qtbase[dbus]:arm64-linux=cascade
qtbase[dbus](android)=cascade
qtbase[egl]:arm64-linux=feature-fails
qtbase[gles2]:arm64-linux=feature-fails
Expand Down
25 changes: 19 additions & 6 deletions scripts/test_ports/vcpkg-ci-blender/fix_apple.patch
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ index 763d32e9..6b957da8 100644
+++ b/build_files/cmake/platform/platform_apple.cmake
@@ -26,7 +26,6 @@ endfunction()
# Find system provided libraries.

# Find system ZLIB, not the pre-compiled one supplied with OpenCollada.
-set(ZLIB_ROOT /usr)
find_package(ZLIB REQUIRED)
Expand All @@ -16,13 +16,26 @@ index 763d32e9..6b957da8 100644
if(NOT EXISTS "${LIBDIR}/.git")
message(FATAL_ERROR "Mac OSX requires pre-compiled libs at: '${LIBDIR}'")
endif()
@@ -62,5 +63,6 @@ if(FIRST_RUN)
@@ -61,9 +61,10 @@ if(FIRST_RUN)
message(STATUS "Using pre-compiled LIBDIR: ${LIBDIR}")
endif()

+endif()
# Avoid searching for headers since this would otherwise override our lib
# directory as well as PYTHON_ROOT_DIR.
set(CMAKE_FIND_FRAMEWORK NEVER)
-set(CMAKE_FIND_FRAMEWORK NEVER)
+set(CMAKE_FIND_FRAMEWORK LAST)

# Optionally use system Python if PYTHON_ROOT_DIR is specified.
if(WITH_PYTHON)
@@ -79,6 +81,5 @@ endif()
# Prefer lib directory paths
file(GLOB LIB_SUBDIRS ${LIBDIR}/*)
-set(CMAKE_PREFIX_PATH ${LIB_SUBDIRS})
-
+list(APPEND CMAKE_PREFIX_PATH ${LIB_SUBDIRS})
# -------------------------------------------------------------------------
# Find precompiled libraries, and avoid system or user-installed ones.
@@ -146,10 +148,13 @@ endif()

# FreeType compiled with Brotli compression for woff2.
Expand All @@ -42,7 +55,7 @@ index 763d32e9..6b957da8 100644
endif()

-set(EPOXY_ROOT_DIR ${LIBDIR}/epoxy)
+set(EPOXY_ROOT_DIR ${CURRENT_INSTALLED_DIR})
+# set(EPOXY_ROOT_DIR ${LIBDIR}/epoxy)
find_package(Epoxy REQUIRED)

-set(PNG_ROOT ${LIBDIR}/png)
Expand All @@ -62,7 +75,7 @@ index 763d32e9..6b957da8 100644
find_package(PugiXML REQUIRED)
endif()

+set(OPENCOLORIO_ROOT_DIR ${CURRENT_INSTALLED_DIR})
+set(OPENCOLORIO_ROOT_DIR ${VCPKG_CURRENT_INSTALLED_DIR})
find_package(OpenImageIO REQUIRED)
add_bundled_libraries(openimageio/lib)

Expand All @@ -71,7 +84,7 @@ index 763d32e9..6b957da8 100644
endif()

-set(ZSTD_ROOT_DIR ${LIBDIR}/zstd)
+set(ZSTD_ROOT_DIR ${CURRENT_INSTALLED_DIR})
+set(ZSTD_ROOT_DIR ${VCPKG_CURRENT_INSTALLED_DIR})
find_package(Zstd REQUIRED)

if(EXISTS ${LIBDIR})
31 changes: 31 additions & 0 deletions scripts/test_ports/vcpkg-ci-blender/fix_epoxy.patch
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
diff --git a/build_files/cmake/Modules/FindEpoxy.cmake b/build_files/cmake/Modules/FindEpoxy.cmake
--- a/build_files/cmake/Modules/FindEpoxy.cmake
+++ b/build_files/cmake/Modules/FindEpoxy.cmake
@@ -9,6 +9,27 @@
# This can also be an environment variable.
# Epoxy_FOUND, If false, do not try to use epoxy.

+if(APPLE AND DEFINED VCPKG_CURRENT_INSTALLED_DIR)
+ set(PKG_CONFIG_EXECUTABLE "$ENV{PKG_CONFIG}")
+ if(CMAKE_BUILD_TYPE STREQUAL "Debug")
+ set(ENV{PKG_CONFIG_PATH}
+ "${VCPKG_CURRENT_INSTALLED_DIR}/debug/lib/pkgconfig:${VCPKG_CURRENT_INSTALLED_DIR}/lib/pkgconfig:${VCPKG_CURRENT_INSTALLED_DIR}/share/pkgconfig:$ENV{PKG_CONFIG_PATH}")
+ else()
+ set(ENV{PKG_CONFIG_PATH}
+ "${VCPKG_CURRENT_INSTALLED_DIR}/lib/pkgconfig:${VCPKG_CURRENT_INSTALLED_DIR}/share/pkgconfig:$ENV{PKG_CONFIG_PATH}")
+ endif()
+ find_package(PkgConfig QUIET)
+ if(PkgConfig_FOUND)
+ pkg_check_modules(epoxy QUIET IMPORTED_TARGET epoxy)
+ if(epoxy_FOUND)
+ set(Epoxy_LIBRARY PkgConfig::epoxy)
+ set(Epoxy_LIBRARIES PkgConfig::epoxy)
+ set(Epoxy_INCLUDE_DIRS ${epoxy_INCLUDE_DIRS})
+ list(GET epoxy_INCLUDE_DIRS 0 Epoxy_INCLUDE_DIR)
+ endif()
+ endif()
+endif()
+
# If `EPOXY_ROOT_DIR` was defined in the environment, use it.
if(DEFINED EPOXY_ROOT_DIR)
# Pass.
67 changes: 67 additions & 0 deletions scripts/test_ports/vcpkg-ci-blender/fix_openexr.patch
Original file line number Diff line number Diff line change
@@ -0,0 +1,67 @@
diff --git a/build_files/cmake/Modules/FindOpenEXR.cmake b/build_files/cmake/Modules/FindOpenEXR.cmake
--- a/build_files/cmake/Modules/FindOpenEXR.cmake
+++ b/build_files/cmake/Modules/FindOpenEXR.cmake
@@ -22,6 +22,54 @@
# also defined, but not for general use are
# OPENEXR_LIBRARY, where to find the OpenEXR library.

+block(SCOPE_FOR VARIABLES)
+ find_package(OpenEXR CONFIG REQUIRED)
+
+ set(_openexr_libraries OpenEXR::OpenEXR)
+ if(TARGET OpenEXR::OpenEXRUtil)
+ list(APPEND _openexr_libraries OpenEXR::OpenEXRUtil)
+ endif()
+
+ if(TARGET OpenEXR::OpenEXRConfig)
+ get_target_property(_openexr_include_dirs OpenEXR::OpenEXRConfig INTERFACE_INCLUDE_DIRECTORIES)
+ else()
+ get_target_property(_openexr_include_dirs OpenEXR::OpenEXR INTERFACE_INCLUDE_DIRECTORIES)
+ endif()
+
+ if(TARGET Imath::ImathConfig)
+ get_target_property(_imath_include_dirs Imath::ImathConfig INTERFACE_INCLUDE_DIRECTORIES)
+ elseif(TARGET Imath::Imath)
+ get_target_property(_imath_include_dirs Imath::Imath INTERFACE_INCLUDE_DIRECTORIES)
+ endif()
+
+ set(_openexr_include_dir "")
+ foreach(_openexr_dir IN LISTS _openexr_include_dirs)
+ if(EXISTS "${_openexr_dir}/OpenEXR/OpenEXRConfig.h")
+ set(_openexr_include_dir "${_openexr_dir}")
+ break()
+ endif()
+ endforeach()
+ if(NOT _openexr_include_dir)
+ list(GET _openexr_include_dirs 0 _openexr_include_dir)
+ endif()
+
+ if(TARGET Imath::Imath)
+ set(IMATH_LIBRARIES Imath::Imath PARENT_SCOPE)
+ endif()
+ if(_imath_include_dirs)
+ set(IMATH_INCLUDE_DIRS "${_imath_include_dirs}" PARENT_SCOPE)
+ list(GET _imath_include_dirs 0 _imath_include_dir)
+ set(IMATH_INCLUDE_DIR "${_imath_include_dir}" PARENT_SCOPE)
+ endif()
+
+ set(OpenEXR_FOUND TRUE PARENT_SCOPE)
+ set(OPENEXR_FOUND TRUE PARENT_SCOPE)
+ set(OPENEXR_LIBRARIES "${_openexr_libraries}" PARENT_SCOPE)
+ set(OPENEXR_INCLUDE_DIRS "${_openexr_include_dirs}" PARENT_SCOPE)
+ set(OPENEXR_INCLUDE_DIR "${_openexr_include_dir}" PARENT_SCOPE)
+endblock()
+
+if(0)
# If `OPENEXR_ROOT_DIR` was defined in the environment, use it.
if(DEFINED OPENEXR_ROOT_DIR)
# Pass.
@@ -204,6 +252,8 @@
set(IMATH_INCLUDE_DIRS
${IMATH_INCLUDE_DIR})
endif()
+
+endif()

mark_as_advanced(
OPENEXR_INCLUDE_DIR
3 changes: 3 additions & 0 deletions scripts/test_ports/vcpkg-ci-blender/portfile.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,9 @@ vcpkg_from_github(
smid.patch
python.patch
fix_dep.patch
fix_openexr.patch
fix_apple.patch
fix_epoxy.patch
fix_windows.patch
dynamic-internal-libs.patch
gl.patch
Expand All @@ -37,6 +39,7 @@ set(ENV{PKG_CONFIG} "${PKGCONFIG}")
vcpkg_cmake_configure(
SOURCE_PATH "${SOURCE_PATH}"
OPTIONS
"-DVCPKG_CURRENT_INSTALLED_DIR=${CURRENT_INSTALLED_DIR}"
-DPKG_CONFIG_USE_STATIC_LIBS=ON
-DENABLE_MSYS2=OFF
-DMSYS2_USE_UPSTREAM_PACKAGES=OFF
Expand Down
2 changes: 1 addition & 1 deletion scripts/test_ports/vcpkg-ci-blender/vcpkg.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
"description": "3D creation suite",
"homepage": "https://www.blender.org/",
"license": "GPL-1.0-or-later",
"supports": "x64 & windows",
"supports": "(x64 & (windows | linux)) | osx",
"dependencies": [
"bzip2",
"freetype",
Expand Down
6 changes: 3 additions & 3 deletions versions/baseline.json
Original file line number Diff line number Diff line change
Expand Up @@ -5090,7 +5090,7 @@
},
"libiconv": {
"baseline": "1.18",
"port-version": 3
"port-version": 4
},
"libics": {
"baseline": "1.7.0",
Expand Down Expand Up @@ -7378,7 +7378,7 @@
},
"openmpi": {
"baseline": "4.1.8",
"port-version": 0
"port-version": 1
},
"openmvg": {
"baseline": "2.1",
Expand Down Expand Up @@ -8306,7 +8306,7 @@
},
"qtbase": {
"baseline": "6.10.2",
"port-version": 0
"port-version": 1
},
"qtcharts": {
"baseline": "6.10.2",
Expand Down
5 changes: 5 additions & 0 deletions versions/l-/libiconv.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,10 @@
{
"versions": [
{
"git-tree": "dca28e93ad5a661156d8ea85aa4d26328dc309ed",
"version": "1.18",
"port-version": 4
},
{
"git-tree": "cd6e884bcb53ce8481ea9594639f3d21aed0e138",
"version": "1.18",
Expand Down
5 changes: 5 additions & 0 deletions versions/o-/openmpi.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,10 @@
{
"versions": [
{
"git-tree": "b331e84d5d13199f2179a51e9688017881ae096e",
"version": "4.1.8",
"port-version": 1
},
{
"git-tree": "72fb28e830e8fbfb52a524fcdeaea95850d32a58",
"version": "4.1.8",
Expand Down
5 changes: 5 additions & 0 deletions versions/q-/qtbase.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,10 @@
{
"versions": [
{
"git-tree": "4911a9ea38cd27d4f626bda9357083896f5b5d6e",
"version": "6.10.2",
"port-version": 1
},
{
"git-tree": "0e931a0ffedd613937a8b9cad29f92087a7f83e8",
"version": "6.10.2",
Expand Down
Loading