building new cmake files for the core (WIP)

fixing a missign header in bsdstring.h (need size_t)
This commit is contained in:
Enno Rehling 2012-06-03 11:59:21 -07:00
parent 533c267b9a
commit ee456c49b1
3 changed files with 58 additions and 0 deletions

9
src/CMakeLists.txt Normal file
View File

@ -0,0 +1,9 @@
cmake_minimum_required(VERSION 2.4)
project (eressea-core)
enable_testing()
set(CMAKE_MODULE_PATH ${CMAKE_MODULE_PATH} "${CMAKE_SOURCE_DIR}/../../cmake/Modules/")
add_subdirectory (../../dependencies "${CMAKE_CURRENT_BINARY_DIR}/dependencies")
add_subdirectory (util)

48
src/util/CMakeLists.txt Normal file
View File

@ -0,0 +1,48 @@
cmake_minimum_required (VERSION 2.4)
project (util)
find_package (Lua51 REQUIRED)
find_package (LibXml2 REQUIRED)
#find_package (CuTest REQUIRED HINTS ${DEPENDENCIES_DIR})
#find_package (QuickList REQUIRED)
#find_package (CritBit REQUIRED)
include_directories (${LUA_INCLUDE_DIR} ${LIBXML2_INCLUDE_DIR})
include_directories (..
${CRITBIT_INCLUDE_DIR}
${QUICKLIST_INCLUDE_DIR}
${CUTEST_INCLUDE_DIR}
)
add_library (util attrib.c
base36.c
base36_test.c
bsdstring.c
bsdstring_test.c
console.c
crmessage.c
dice.c
eventbus.c
event.c
filereader.c
functions.c
functions_test.c
goodies.c
language.c
listbox.c
lists.c
log.c
message.c
nrmessage.c
os.c
parser.c
rand.c
resolve.c
sql.c
strings.c
translation.c
umlaut.c
umlaut_test.c
unicode.c
xml.c
)

View File

@ -1,6 +1,7 @@
#ifndef UTIL_BSDSTRING_H #ifndef UTIL_BSDSTRING_H
#define UTIL_BSDSTRING_H #define UTIL_BSDSTRING_H
#include <stddef.h>
extern int wrptr(char **ptr, size_t * size, int bytes); extern int wrptr(char **ptr, size_t * size, int bytes);
#ifndef HAVE_STRLCPY #ifndef HAVE_STRLCPY