summaryrefslogtreecommitdiff
path: root/CMakeLists.txt
diff options
context:
space:
mode:
authorNaram Qashat <cyberbotx@cyberbotx.com>2011-10-24 16:32:29 -0400
committerNaram Qashat <cyberbotx@cyberbotx.com>2011-10-24 16:32:29 -0400
commit377a7a968b6a906f262a45abea9a563ffc471938 (patch)
tree3743f5d564bd7b40db5659bf6e18dd102b5c5c19 /CMakeLists.txt
parentd0513d6506ce34b57874ad265daf38ca67878aa0 (diff)
Fixed bug #1349 (m_sqlite compiles without error under FreeBSD), as well as use C99's stdint.h (or cstdint if available) to get (u)intX_t types instead of our stupid typedefs. pstdint.h included in case there is no cstdint or stdint.h available.
Diffstat (limited to 'CMakeLists.txt')
-rw-r--r--CMakeLists.txt15
1 files changed, 3 insertions, 12 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 0e863bf06..774f8c2e7 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -248,7 +248,7 @@ else(MSVC)
if(UNIX)
set(CXXFLAGS "${CXXFLAGS} -ansi -pedantic")
if (CMAKE_CXX_COMPILER_ID STREQUAL "GNU")
- set(CXXFLAGS "${CXXFLAGS} -fno-leading-underscore")
+ set(CXXFLAGS "${CXXFLAGS} -Wno-long-long -fno-leading-underscore")
endif(CMAKE_CXX_COMPILER_ID STREQUAL "GNU")
# If we aren't on a *nix system, we are using MinGW
else(UNIX)
@@ -329,7 +329,8 @@ if(CMAKE_BUILD_TYPE STREQUAL "DEBUG" OR CMAKE_BUILD_TYPE STREQUAL "RELWITHDEBINF
endif(CMAKE_BUILD_TYPE STREQUAL "DEBUG" OR CMAKE_BUILD_TYPE STREQUAL "RELWITHDEBINFO")
# Check for the existance of the following include files
-check_include_file(sys/types.h HAVE_SYS_TYPES_H)
+check_include_file(cstdint HAVE_CSTDINT)
+check_include_file(stdint.h HAVE_STDINT_H)
check_include_file(strings.h HAVE_STRINGS_H)
# Check for the existance of the following functions
@@ -341,16 +342,6 @@ check_function_exists(epoll_wait HAVE_EPOLL)
check_function_exists(poll HAVE_POLL)
check_function_exists(kqueue HAVE_KQUEUE)
-# Check for the existance of the following types
-check_type_size(uint8_t UINT8_T)
-check_type_size(u_int8_t U_INT8_T)
-check_type_size(int16_t INT16_T)
-check_type_size(uint16_t UINT16_T)
-check_type_size(u_int16_t U_INT16_T)
-check_type_size(int32_t INT32_T)
-check_type_size(uint32_t UINT32_T)
-check_type_size(u_int32_t U_INT32_T)
-
# Check if eventfd works
try_run(EVENTFD_TEST_RUN_RESULT EVENTFD_TEST_COMPILE_RESULT ${CMAKE_CURRENT_BINARY_DIR} ${Anope_SOURCE_DIR}/cmake/eventfd_test.cpp)
set(HAVE_EVENTFD FALSE)