Skip to content

Commit 993f8f4

Browse files
committed
packaging: Skip DEB package configuration if not run on a DEB system
1 parent a601a58 commit 993f8f4

File tree

1 file changed

+12
-3
lines changed

1 file changed

+12
-3
lines changed

packaging/deb-in/CMakeLists.txt

Lines changed: 12 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -26,9 +26,18 @@
2626
# along with this program; if not, write to the Free Software Foundation, Inc.,
2727
# 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
2828

29-
IF(NOT CMAKE_SYSTEM_NAME STREQUAL "Linux")
30-
RETURN()
31-
ENDIF()
29+
if(NOT CMAKE_SYSTEM_NAME STREQUAL "Linux")
30+
message("Skipping DEB package configuration: not a Linux system")
31+
return()
32+
endif()
33+
34+
find_program(LSB_RELEASE lsb_release)
35+
if(NOT LSB_RELEASE)
36+
message("Skipping DEB package configuration: lsb_release was not found")
37+
return()
38+
endif()
39+
40+
3241
IF (NOT DEFINED DEB_CODENAME)
3342
execute_process(
3443
COMMAND lsb_release -cs

0 commit comments

Comments
 (0)