From a4b94e97b3bc5d50251a72547dffab6104357436 Mon Sep 17 00:00:00 2001 From: Chen Yufei Date: Mon, 28 Mar 2022 19:44:35 +0800 Subject: [PATCH] librdkafka: patch for installed cmake config files. --- packages/l/librdkafka/xmake.lua | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/packages/l/librdkafka/xmake.lua b/packages/l/librdkafka/xmake.lua index a53d594d1..216b9c330 100644 --- a/packages/l/librdkafka/xmake.lua +++ b/packages/l/librdkafka/xmake.lua @@ -53,6 +53,13 @@ package("librdkafka") table.insert(configs, "-DWITH_" .. config:upper() .. "=" .. (package:config(config) and "ON" or "OFF")) end import("package.tools.cmake").install(package, configs) + + if package:version():startswith("v1.8.2") then + io.replace(path.join(package:installdir("lib"), "cmake", "RdKafka", "RdKafkaConfig.cmake"), + "find_dependency(LZ4)", + 'list(APPEND CMAKE_MODULE_PATH "${CMAKE_CURRENT_LIST_DIR}")\n find_dependency(LZ4)', + {plain = true}) + end end) on_test(function (package)