[github_actions] improve port compatibility (#23202)

* use vcpkg provided libs before system frameworks on macOS, remove now unnecessary mod to giflib

* fix references

* fixes from review

* apply fixes from review - remove warnings too!

* [giflib] add license

* fix references

Co-authored-by: Victor Romero <viromer@microsoft.com>
This commit is contained in:
Stefano Sinigardi 2022-03-15 21:21:32 +01:00 committed by GitHub
parent 4c98968595
commit 5a7640f6a2
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
6 changed files with 13 additions and 7 deletions

View File

@ -29,6 +29,4 @@ vcpkg_cmake_configure(
vcpkg_cmake_install()
vcpkg_copy_pdbs()
file(COPY ${CMAKE_CURRENT_LIST_DIR}/vcpkg-cmake-wrapper.cmake DESTINATION ${CURRENT_PACKAGES_DIR}/share/gif)
file(INSTALL "${SOURCE_PATH}/COPYING" DESTINATION "${CURRENT_PACKAGES_DIR}/share/${PORT}" RENAME copyright)

View File

@ -1,3 +0,0 @@
find_path(GIF_INCLUDE_DIR gif_lib.h PATH_SUFFIXES include PATHS "${_VCPKG_INSTALLED_DIR}/${VCPKG_TARGET_TRIPLET}" NO_DEFAULT_PATH)
_find_package(${ARGS})

View File

@ -1,9 +1,10 @@
{
"name": "giflib",
"version": "5.2.1",
"port-version": 1,
"port-version": 2,
"description": "A library for reading and writing gif images.",
"homepage": "https://sourceforge.net/projects/giflib/",
"license": "MIT",
"dependencies": [
{
"name": "vcpkg-cmake",

View File

@ -404,6 +404,11 @@ z_vcpkg_add_vcpkg_to_cmake_path(CMAKE_PREFIX_PATH "")
z_vcpkg_add_vcpkg_to_cmake_path(CMAKE_LIBRARY_PATH "/lib/manual-link")
z_vcpkg_add_vcpkg_to_cmake_path(CMAKE_FIND_ROOT_PATH "")
if(NOT VCPKG_PREFER_SYSTEM_LIBS)
set(CMAKE_FIND_FRAMEWORK "LAST") # we assume that frameworks are usually system-wide libs, not vcpkg-built
set(CMAKE_FIND_APPBUNDLE "LAST") # we assume that appbundles are usually system-wide libs, not vcpkg-built
endif()
# If one CMAKE_FIND_ROOT_PATH_MODE_* variables is set to ONLY, to make sure that ${_VCPKG_INSTALLED_DIR}/${VCPKG_TARGET_TRIPLET}
# and ${_VCPKG_INSTALLED_DIR}/${VCPKG_TARGET_TRIPLET}/debug are searched, it is not sufficient to just add them to CMAKE_FIND_ROOT_PATH,
# as CMAKE_FIND_ROOT_PATH specify "one or more directories to be prepended to all other search directories", so to make sure that

View File

@ -2470,7 +2470,7 @@
},
"giflib": {
"baseline": "5.2.1",
"port-version": 1
"port-version": 2
},
"ginkgo": {
"baseline": "1.4.0",

View File

@ -1,5 +1,10 @@
{
"versions": [
{
"git-tree": "5b5833304ba0e1be5ff125f265d1f2e1098a93cb",
"version": "5.2.1",
"port-version": 2
},
{
"git-tree": "14178ec83d76a40e314adcf9bba75b63e99bc56d",
"version": "5.2.1",