2011-01-10 17:09:40 +01:00
|
|
|
/*
|
|
|
|
* config.h.in
|
|
|
|
*
|
|
|
|
* Tries to fix various differences in compilers and libraries.
|
2010-09-13 19:24:53 +02:00
|
|
|
*
|
|
|
|
*/
|
|
|
|
|
2011-01-10 17:09:40 +01:00
|
|
|
#ifndef __CONFIG_H__
|
|
|
|
#define __CONFIG_H__
|
2010-09-13 19:24:53 +02:00
|
|
|
|
|
|
|
#define PROJECT_NAME "${PROJECT_NAME}"
|
2021-10-22 15:04:24 +02:00
|
|
|
#define PROJECT_VERSION "${PROJECT_VERSION}"
|
2022-07-25 13:30:27 +02:00
|
|
|
#define PROJECT_ID "${project_ID}"
|
2011-02-07 18:03:15 +01:00
|
|
|
#define PROJECT_URL "${project_URL}"
|
2010-09-13 19:24:53 +02:00
|
|
|
|
2015-01-21 20:25:59 +01:00
|
|
|
#cmakedefine OPTION_NOINSTALL
|
|
|
|
|
|
|
|
#ifdef OPTION_NOINSTALL
|
2010-09-13 19:24:53 +02:00
|
|
|
/* For developers. */
|
2021-10-25 00:59:01 +02:00
|
|
|
#define PROJECT_DOC_DIR "${CMAKE_SOURCE_DIR}/docs/"
|
2010-09-13 19:24:53 +02:00
|
|
|
#define PROJECT_SHARE_DIR "${CMAKE_SOURCE_DIR}/share/"
|
2011-06-10 18:18:58 +02:00
|
|
|
#define PROJECT_GSETTINGS_DIR "${CMAKE_BINARY_DIR}"
|
2011-01-22 19:48:30 +01:00
|
|
|
#elif defined (_WIN32)
|
2021-10-25 00:59:01 +02:00
|
|
|
#define PROJECT_DOC_DIR "share/doc/${PROJECT_NAME}/"
|
2011-01-22 19:48:30 +01:00
|
|
|
#define PROJECT_SHARE_DIR "share/${PROJECT_NAME}/"
|
2010-09-13 19:24:53 +02:00
|
|
|
#else
|
2021-10-25 00:59:01 +02:00
|
|
|
#define PROJECT_DOC_DIR "${CMAKE_INSTALL_PREFIX}/share/doc/${PROJECT_NAME}/"
|
2010-09-13 19:24:53 +02:00
|
|
|
#define PROJECT_SHARE_DIR "${CMAKE_INSTALL_PREFIX}/share/${PROJECT_NAME}/"
|
|
|
|
#endif
|
|
|
|
|
|
|
|
|
2011-02-12 02:07:39 +01:00
|
|
|
#include <glib/gi18n.h>
|
2010-09-13 19:24:53 +02:00
|
|
|
|
2011-02-12 02:07:39 +01:00
|
|
|
#define GETTEXT_DOMAIN "${PROJECT_NAME}"
|
|
|
|
#ifdef _WIN32
|
|
|
|
#define GETTEXT_DIRNAME "share/locale"
|
|
|
|
#else
|
2010-09-13 19:24:53 +02:00
|
|
|
#define GETTEXT_DIRNAME "${CMAKE_INSTALL_PREFIX}/share/locale"
|
2011-02-12 02:07:39 +01:00
|
|
|
#endif
|
2010-09-13 19:24:53 +02:00
|
|
|
|
|
|
|
|
2011-02-02 17:22:34 +01:00
|
|
|
/* We have to remove nodes first due to a bug in json-glib. */
|
|
|
|
#define json_object_set_member(object, name, node) \
|
|
|
|
G_STMT_START { \
|
|
|
|
json_object_remove_member ((object), (name)); \
|
|
|
|
json_object_set_member ((object), (name), (node)); \
|
|
|
|
} G_STMT_END
|
|
|
|
|
2011-01-10 17:09:40 +01:00
|
|
|
#endif /* __CONFIG_H__ */
|
2010-09-13 19:24:53 +02:00
|
|
|
|