libyaml-cpp: fix pkgconfig file

This avoids leaking OS paths.

Signed-off-by: Rosen Penev <rosenp@gmail.com>
This commit is contained in:
Rosen Penev
2025-08-01 12:34:39 -07:00
committed by Tianling Shen
parent 0f743e07c1
commit 9bb8db08d0

View File

@@ -44,6 +44,12 @@ CMAKE_OPTIONS += \
-DYAML_CPP_BUILD_TESTS=OFF \
-DYAML_CPP_BUILD_TOOLS=OFF
define Build/InstallDev
$(call Build/InstallDev/cmake,$(1))
$(SED) 's,/usr/include,$$$${prefix}/include,g' $(1)/usr/lib/pkgconfig/yaml-cpp.pc
$(SED) 's,/usr/lib,$$$${exec_prefix}/lib,g' $(1)/usr/lib/pkgconfig/yaml-cpp.pc
endef
define Package/libyaml-cpp/install
$(INSTALL_DIR) $(1)/usr/lib
$(INSTALL_DATA) $(PKG_INSTALL_DIR)/usr/lib/libyaml-cpp.so.$(ABI_VERSION) $(1)/usr/lib/