get rid of argp dependency

This commit is contained in:
John
2023-10-01 14:09:38 +02:00
parent 1b9723c96f
commit 22b6f02752
20 changed files with 740 additions and 304 deletions
-12
View File
@@ -74,18 +74,6 @@ check_function_exists(ppoll HAVE_PPOLL)
check_include_file(linux/serial.h HAVE_LINUX_SERIAL -DHAVE_LINUX_SERIAL=1)
check_include_file(dev/usb/uftdiio.h HAVE_FREEBSD_UFTDI -DHAVE_FREEBSD_UFTDI=1)
check_function_exists(argp_parse HAVE_ARGP_H)
if(NOT HAVE_ARGP_H)
if(NOT ARGP_HINTS)
set(ARGP_HINTS ~/argp-standalone/src)
endif(NOT ARGP_HINTS)
find_library(LIB_ARGP NAMES argp argp-standalone HINTS ARGP_HINTS)
if (NOT LIB_ARGP)
message(FATAL_ERROR "argp library not available")
endif(NOT LIB_ARGP)
set(CMAKE_REQUIRED_LIBRARIES "${CMAKE_REQUIRED_LIBRARIES} ${LIB_ARGP}")
endif(NOT HAVE_ARGP_H)
option(coverage "enable code coverage tracking." OFF)
if(NOT coverage STREQUAL OFF)
add_definitions(-g -O0 --coverage -Wall)