4675d9c9c4
Thanks to @sgn for the cross compile fixes!
37 lines
1.2 KiB
Diff
37 lines
1.2 KiB
Diff
From 7e5f9b857eb78c4c17a1321a5a5a55bb4afcf2c9 Mon Sep 17 00:00:00 2001
|
|
From: Andrew Benson <abenson@gmail.com>
|
|
Date: Tue, 16 Jun 2020 17:59:44 -0500
|
|
Subject: [PATCH] cmake: Make musl support more distro agnostic
|
|
|
|
---
|
|
CMakeLists.txt | 17 +++++------------
|
|
1 file changed, 5 insertions(+), 12 deletions(-)
|
|
|
|
diff --git CMakeLists.txt CMakeLists.txt
|
|
index 9e6d5c73cb..3efae8fa6b 100644
|
|
--- CMakeLists.txt
|
|
+++ CMakeLists.txt
|
|
@@ -334,18 +334,11 @@ include_directories(BEFORE ${OPENSSL_INCLUDE_DIR})
|
|
# Make everyone find the highwayhash includes
|
|
include_directories(BEFORE ${CMAKE_CURRENT_SOURCE_DIR}/auxil/highwayhash)
|
|
|
|
-# Alpine support
|
|
-if ( ${CMAKE_SYSTEM_NAME} MATCHES Linux AND EXISTS /etc/os-release )
|
|
- execute_process(
|
|
- COMMAND grep -q alpine /etc/os-release
|
|
- RESULT_VARIABLE os_release_alpine
|
|
- )
|
|
-
|
|
- if ( os_release_alpine EQUAL 0 )
|
|
- find_package(FTS REQUIRED)
|
|
- list(APPEND OPTLIBS ${FTS_LIBRARY})
|
|
- include_directories(BEFORE ${FTS_INCLUDE_DIR})
|
|
- endif ()
|
|
+# Determine if libfts is external to libc, i.e. musl
|
|
+find_package(FTS)
|
|
+if ( FTS_FOUND )
|
|
+ list(APPEND OPTLIBS ${FTS_LIBRARY})
|
|
+ include_directories(BEFORE ${FTS_INCLUDE_DIR})
|
|
endif ()
|
|
|
|
set(zeekdeps ${zeekdeps}
|