diff --git a/misc/CMakeLists.txt b/misc/CMakeLists.txt index 911b9bf..4390f25 100644 --- a/misc/CMakeLists.txt +++ b/misc/CMakeLists.txt @@ -49,6 +49,7 @@ if (PCAP_CONFIG) execute_process (COMMAND pcap-config --libs OUTPUT_VARIABLE PCAP_LDFLAGS OUTPUT_STRIP_TRAILING_WHITESPACE) + string(STRIP "${PCAP_LDFLAGS}" PCAP_LDFLAGS) execute_process (COMMAND pcap-config --cflags OUTPUT_VARIABLE PCAP_CFLAGS OUTPUT_STRIP_TRAILING_WHITESPACE) diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt index 720d15a..0da706f 100644 --- a/src/CMakeLists.txt +++ b/src/CMakeLists.txt @@ -72,6 +72,7 @@ if (PCAP_CONFIG) execute_process (COMMAND pcap-config --cflags OUTPUT_VARIABLE PCAP_CFLAGS OUTPUT_STRIP_TRAILING_WHITESPACE) + string(STRIP "${PCAP_LDFLAGS}" PCAP_LDFLAGS) else (PCAP_CONFIG) message (STATUS "pcap-config not found, using defaults...") set (PCAP_LDFLAGS "-L/usr/lib -lpcap")