summaryrefslogtreecommitdiff
path: root/src/common
diff options
context:
space:
mode:
Diffstat (limited to 'src/common')
-rw-r--r--src/common/CMakeLists.txt17
-rw-r--r--src/common/conf.c2
-rw-r--r--src/common/conf.h2
-rw-r--r--src/common/showmsg.h2
4 files changed, 17 insertions, 6 deletions
diff --git a/src/common/CMakeLists.txt b/src/common/CMakeLists.txt
index f7acda740..effd0b2ab 100644
--- a/src/common/CMakeLists.txt
+++ b/src/common/CMakeLists.txt
@@ -40,14 +40,17 @@ set( COMMON_MINI_HEADERS
"${COMMON_SOURCE_DIR}/malloc.h"
"${COMMON_SOURCE_DIR}/showmsg.h"
"${COMMON_SOURCE_DIR}/strlib.h"
+ ${LIBCONFIG_HEADERS} # needed by showmsg.h
CACHE INTERNAL "" )
set( COMMON_MINI_SOURCES
"${COMMON_SOURCE_DIR}/core.c"
"${COMMON_SOURCE_DIR}/malloc.c"
"${COMMON_SOURCE_DIR}/showmsg.c"
"${COMMON_SOURCE_DIR}/strlib.c"
+ ${LIBCONFIG_SOURCES} # needed by showmsg.c
CACHE INTERNAL "" )
-set( COMMON_MINI_DEFINITIONS "-DMINICORE" CACHE INTERNAL "" )
+set( COMMON_MINI_INCLUDE_DIRS ${LIBCONFIG_INCLUDE_DIRS} CACHE INTERNAL "" )
+set( COMMON_MINI_DEFINITIONS "-DMINICORE ${LIBCONFIG_DEFINITIONS}" CACHE INTERNAL "" )
#
@@ -75,6 +78,7 @@ set( COMMON_BASE_HEADERS
"${COMMON_SOURCE_DIR}/strlib.h"
"${COMMON_SOURCE_DIR}/timer.h"
"${COMMON_SOURCE_DIR}/utils.h"
+ ${LIBCONFIG_HEADERS} # needed by conf.h/showmsg.h
CACHE INTERNAL "common_base headers" )
set( COMMON_BASE_SOURCES
"${COMMON_SOURCE_DIR}/conf.c"
@@ -95,10 +99,17 @@ set( COMMON_BASE_SOURCES
"${COMMON_SOURCE_DIR}/strlib.c"
"${COMMON_SOURCE_DIR}/timer.c"
"${COMMON_SOURCE_DIR}/utils.c"
+ ${LIBCONFIG_SOURCES} # needed by conf.c/showmsg.c
CACHE INTERNAL "common_base sources" )
+set( COMMON_BASE_INCLUDE_DIRS
+ ${LIBCONFIG_INCLUDE_DIRS}
+ CACHE INTERNAL "common_base include dirs" )
+set( COMMON_BASE_DEFINITIONS
+ ${LIBCONFIG_DEFINITIONS}
+ CACHE INTERNAL "common_base definitions" )
set( LIBRARIES ${GLOBAL_LIBRARIES} ${ZLIB_LIBRARIES} )
-set( INCLUDE_DIRS ${GLOBAL_INCLUDE_DIRS} ${MT19937AR_INCLUDE_DIRS} ${ZLIB_INCLUDE_DIRS} ${LIBCONFIG_INCLUDE_DIRS} )
-set( DEFINITIONS "${GLOBAL_DEFINITIONS}" )
+set( INCLUDE_DIRS ${GLOBAL_INCLUDE_DIRS} ${MT19937AR_INCLUDE_DIRS} ${ZLIB_INCLUDE_DIRS} ${COMMON_BASE_INCLUDE_DIRS} )
+set( DEFINITIONS "${GLOBAL_DEFINITIONS} ${COMMON_BASE_DEFINITIONS}" )
set( SOURCE_FILES ${MT19937AR_HEADERS} ${MT19937AR_SOURCES} ${COMMON_BASE_HEADERS} ${COMMON_BASE_SOURCES} )
source_group( mt19937ar FILES ${MT19937AR_HEADERS} ${MT19937AR_SOURCES} )
source_group( common FILES ${COMMON_BASE_HEADERS} ${COMMON_BASE_SOURCES} )
diff --git a/src/common/conf.c b/src/common/conf.c
index eed39d409..a5bfec159 100644
--- a/src/common/conf.c
+++ b/src/common/conf.c
@@ -2,7 +2,7 @@
// For more information, see LICENCE in the main folder
#include "conf.h"
-#include <libconfig.h>
+#include "libconfig.h"
#include "../common/showmsg.h" // ShowError
diff --git a/src/common/conf.h b/src/common/conf.h
index 0b70a0c79..4c3dec89f 100644
--- a/src/common/conf.h
+++ b/src/common/conf.h
@@ -5,7 +5,7 @@
#define _CONF_H_
#include "../common/cbasetypes.h"
-#include <libconfig.h>
+#include "libconfig.h"
int conf_read_file(config_t *config, const char *config_filename);
int config_setting_copy(config_setting_t *parent, const config_setting_t *src);
diff --git a/src/common/showmsg.h b/src/common/showmsg.h
index 839f1dc7e..302ba5cd0 100644
--- a/src/common/showmsg.h
+++ b/src/common/showmsg.h
@@ -4,7 +4,7 @@
#ifndef _SHOWMSG_H_
#define _SHOWMSG_H_
-#include <libconfig.h>
+#include "libconfig.h"
// for help with the console colors look here:
// http://www.edoceo.com/liberum/?doc=printf-with-color