aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAndrew Yourtchenko <ayourtch@gmail.com>2022-03-24 11:45:10 +0000
committerAndrew Yourtchenko <ayourtch@gmail.com>2022-03-24 12:34:54 +0000
commit534dfc1f18db74f4a2c78d62fe6893daba56dc86 (patch)
treee9bcac900e5192a768e2aaf2c063953935f75e23
parent4e26a78525ba43a5e9bd0c9541fb6d8029212187 (diff)
build: set OS_ID_LIKE on to be OS_ID on Debian proper
OS_ID_LIKE from /etc/os-release is used to determine the type of packaging. On Debian it ends up being empty, so the "ninja package" does not work for out of tree plugin builds. Solution: if OS_ID_LIKE is not set, set it to OS_ID Type: fix Signed-off-by: Andrew Yourtchenko <ayourtch@gmail.com> Change-Id: I077d4fdb509ea94b187d11391b1f49edb94c4e30 Signed-off-by: Andrew Yourtchenko <ayourtch@gmail.com>
-rw-r--r--src/cmake/pack.cmake5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/cmake/pack.cmake b/src/cmake/pack.cmake
index a89a90c452c..f4edecb956a 100644
--- a/src/cmake/pack.cmake
+++ b/src/cmake/pack.cmake
@@ -64,6 +64,11 @@ macro(add_vpp_packaging)
set(CPACK_${type}_PACKAGE_DESCRIPTION "${ARG_DESCRIPTION}")
set(CPACK_${type}_PACKAGE_RELEASE 1)
+ # Pure Debian does not set the "OS_ID_LIKE", it only sets "OS_ID"
+ if (OS_ID_LIKE MATCHES "")
+ set(OS_ID_LIKE "${OS_ID}")
+ endif()
+
if(OS_ID_LIKE MATCHES "debian")
set(CPACK_GENERATOR "DEB")
set(type "DEBIAN")