summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSander Vrijders <sander.vrijders@intec.ugent.be>2016-10-23 09:45:14 +0000
committerSander Vrijders <sander.vrijders@intec.ugent.be>2016-10-23 09:45:14 +0000
commit84b11f3322797759fef746786badcd10936dfda4 (patch)
treeae95f030431073db2035cd35fe82134a2b57536f
parent282aab31ebdb831725fa8192b985a1e8b0e63403 (diff)
parent322d0a2a350b63cec13f5e5dff3fc632ba0c5565 (diff)
downloadouroboros-84b11f3322797759fef746786badcd10936dfda4.tar.gz
ouroboros-84b11f3322797759fef746786badcd10936dfda4.zip
Merged in dstaesse/ouroboros/be-fix-build (pull request #272)
Be fix build
-rw-r--r--CMakeLists.txt7
-rw-r--r--src/ipcpd/shim-udp/CMakeLists.txt17
2 files changed, 4 insertions, 20 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 3ab2f35e..ef321e4c 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -41,13 +41,14 @@ include(FindPkgConfig)
include(CompilerUtils)
test_and_set_c_compiler_flag_global(-std=c89)
test_and_set_c_compiler_flag_global(-Wall)
-test_and_set_c_compiler_flag_global(-Wextra)
+#Wextra may fail on clobbered warning due to pthread_cleanup
+#test_and_set_c_compiler_flag_global(-Wextra)
test_and_set_c_compiler_flag_global(-Werror)
test_and_set_c_compiler_flag_global(-Wundef)
test_and_set_c_compiler_flag_global(-Wpointer-arith)
test_and_set_c_compiler_flag_global(-Wstrict-prototypes)
-test_and_set_c_compiler_flag_global(-Wswitch-default)
-test_and_set_c_compiler_flag_global(-Wstrict-overflow=5)
+#Wswitch-default check fails on the swig-generated code
+#test_and_set_c_compiler_flag_global(-Wswitch-default)
test_and_set_c_compiler_flag_global(-Wunreachable-code)
test_and_set_c_compiler_flag_global(-Wdeclaration-after-statement)
test_and_set_c_compiler_flag_global(-fmax-errors=5)
diff --git a/src/ipcpd/shim-udp/CMakeLists.txt b/src/ipcpd/shim-udp/CMakeLists.txt
index 3b740783..cc60cfb7 100644
--- a/src/ipcpd/shim-udp/CMakeLists.txt
+++ b/src/ipcpd/shim-udp/CMakeLists.txt
@@ -15,23 +15,6 @@ include_directories(${CMAKE_BINARY_DIR}/include)
protobuf_generate_c(SHIM_UDP_PROTO_SRCS SHIM_UDP_PROTO_HDRS
shim_udp_messages.proto)
-# Find library needed for gethostbyname.
-include(CheckFunctionExists)
-include(CheckLibraryExists)
-CHECK_FUNCTION_EXISTS("gethostbyname" CMAKE_HAVE_GETHOSTBYNAME)
-IF(NOT CMAKE_HAVE_GETHOSTBYNAME)
- CHECK_LIBRARY_EXISTS("nsl" "gethostbyname" "" CMAKE_LIB_NSL_HAS_GETHOSTBYNAME)
- IF (CMAKE_LIB_NSL_HAS_GETHOSTBYNAME)
- SET (X11_X_EXTRA_LIBS ${X11_X_EXTRA_LIBS} -lnsl)
- ELSE (CMAKE_LIB_NSL_HAS_GETHOSTBYNAME)
- CHECK_LIBRARY_EXISTS("bsd" "gethostbyname" ""
- CMAKE_LIB_BSD_HAS_GETHOSTBYNAME)
- IF (CMAKE_LIB_BSD_HAS_GETHOSTBYNAME)
- SET (X11_X_EXTRA_LIBS ${X11_X_EXTRA_LIBS} -lbsd)
- ENDIF (CMAKE_LIB_BSD_HAS_GETHOSTBYNAME)
- ENDIF (CMAKE_LIB_NSL_HAS_GETHOSTBYNAME)
-ENDIF(NOT CMAKE_HAVE_GETHOSTBYNAME)
-
configure_file(
"${CMAKE_CURRENT_SOURCE_DIR}/shim_udp_config.h.in"
"${CMAKE_CURRENT_BINARY_DIR}/shim_udp_config.h")