degesch: detect //TRANSLIT support, use cp1252
Now BSDs should have it enabled as well.
This commit is contained in:
@@ -64,10 +64,18 @@ endif ("${CMAKE_SYSTEM_NAME}" MATCHES "BSD")
|
||||
foreach (extra iconv rt)
|
||||
find_library (extra_lib_${extra} ${extra})
|
||||
if (extra_lib_${extra})
|
||||
list (APPEND project_libraries ${extra})
|
||||
list (APPEND project_libraries ${extra_lib_${extra}})
|
||||
endif (extra_lib_${extra})
|
||||
endforeach (extra)
|
||||
|
||||
include (CheckCSourceRuns)
|
||||
set (CMAKE_REQUIRED_LIBRARIES ${project_libraries})
|
||||
get_property (CMAKE_REQUIRED_INCLUDES
|
||||
DIRECTORY "${PROJECT_SOURCE_DIR}" PROPERTY INCLUDE_DIRECTORIES)
|
||||
CHECK_C_SOURCE_RUNS ("#include <iconv.h>
|
||||
int main () { return iconv_open (\"UTF-8//TRANSLIT\", \"ISO-8859-1\")
|
||||
== (iconv_t) -1; }" ICONV_ACCEPTS_TRANSLIT)
|
||||
|
||||
# Dependencies for degesch
|
||||
pkg_check_modules (libffi REQUIRED libffi)
|
||||
list (APPEND degesch_libraries ${libffi_LIBRARIES})
|
||||
|
||||
Reference in New Issue
Block a user