From 805a02fe990f194af59cdaca61817d31b56506c6 Mon Sep 17 00:00:00 2001 From: Jafar Abdi Date: Thu, 10 Jun 2021 21:26:29 +0300 Subject: [PATCH] [yaml-cpp] Fix visibility attribute for ubuntu (#17728) * Replace YAML_CPP_DLL with 1 iff the library is build as shared library & target is windows * Update port version * Run x-add-version --- ports/yaml-cpp/CONTROL | 1 + ports/yaml-cpp/portfile.cmake | 4 ++-- versions/baseline.json | 2 +- versions/y-/yaml-cpp.json | 5 +++++ 4 files changed, 9 insertions(+), 3 deletions(-) diff --git a/ports/yaml-cpp/CONTROL b/ports/yaml-cpp/CONTROL index bbd8056b25..54a1c8dc08 100644 --- a/ports/yaml-cpp/CONTROL +++ b/ports/yaml-cpp/CONTROL @@ -1,4 +1,5 @@ Source: yaml-cpp Version: 0.6.3 +Port-Version: 1 Homepage: https://github.com/jbeder/yaml-cpp Description: yaml-cpp is a YAML parser and emitter in C++ matching the YAML 1.2 spec. diff --git a/ports/yaml-cpp/portfile.cmake b/ports/yaml-cpp/portfile.cmake index 718bb50f1a..d6ca086ef9 100644 --- a/ports/yaml-cpp/portfile.cmake +++ b/ports/yaml-cpp/portfile.cmake @@ -36,7 +36,7 @@ endif() file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/debug/include) file(READ ${CURRENT_PACKAGES_DIR}/include/yaml-cpp/dll.h DLL_H) -if(VCPKG_LIBRARY_LINKAGE STREQUAL "dynamic") +if(VCPKG_LIBRARY_LINKAGE STREQUAL "dynamic" AND VCPKG_TARGET_IS_WINDOWS) string(REPLACE "#ifdef YAML_CPP_DLL" "#if 1" DLL_H "${DLL_H}") else() string(REPLACE "#ifdef YAML_CPP_DLL" "#if 0" DLL_H "${DLL_H}") @@ -44,4 +44,4 @@ endif() file(WRITE ${CURRENT_PACKAGES_DIR}/include/yaml-cpp/dll.h "${DLL_H}") # Handle copyright -file(INSTALL ${SOURCE_PATH}/LICENSE DESTINATION ${CURRENT_PACKAGES_DIR}/share/${PORT} RENAME copyright) \ No newline at end of file +file(INSTALL ${SOURCE_PATH}/LICENSE DESTINATION ${CURRENT_PACKAGES_DIR}/share/${PORT} RENAME copyright) diff --git a/versions/baseline.json b/versions/baseline.json index 7d671275c4..4c55511014 100644 --- a/versions/baseline.json +++ b/versions/baseline.json @@ -6750,7 +6750,7 @@ }, "yaml-cpp": { "baseline": "0.6.3", - "port-version": 0 + "port-version": 1 }, "yara": { "baseline": "4.1.0", diff --git a/versions/y-/yaml-cpp.json b/versions/y-/yaml-cpp.json index 433f4172c2..3e5888040c 100644 --- a/versions/y-/yaml-cpp.json +++ b/versions/y-/yaml-cpp.json @@ -1,5 +1,10 @@ { "versions": [ + { + "git-tree": "045045b2d5b8cb6166b6d0d548effc0764623341", + "version-string": "0.6.3", + "port-version": 1 + }, { "git-tree": "fabfdd85c28d751aa769d2e743bf0e9ccd8dd178", "version-string": "0.6.3",