diff options
| -rw-r--r-- | CMakeLists.txt | 2 | ||||
| -rw-r--r-- | CMakeScripts/ConfigChecks.cmake | 5 | ||||
| -rw-r--r-- | CMakeScripts/DefineDependsandFlags.cmake | 6 | ||||
| -rw-r--r-- | config.h.cmake | 6 | ||||
| -rw-r--r-- | src/main-cmdlinexact.cpp | 4 | ||||
| -rw-r--r-- | src/main-cmdlinexact.h | 5 | ||||
| -rw-r--r-- | src/main.cpp | 4 | ||||
| -rw-r--r-- | src/path-prefix.h | 5 |
8 files changed, 25 insertions, 12 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt index 5a9c31fc2..2680fc033 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -125,8 +125,6 @@ include(CMakeScripts/HelperMacros.cmake) # Misc Utility Macros if (NOT CMAKE_BUILD_TYPE MATCHES Debug) add_definitions(-D_FORTIFY_SOURCE=2) endif() -add_definitions(-DHAVE_CONFIG_H) -add_definitions(-DHAVE_CAIRO_PDF=1) # needed for src/libnrtype/Layout-TNG.h if(BUILD_SHARED_LIBS AND NOT WIN32) add_definitions(-fPIC) endif() diff --git a/CMakeScripts/ConfigChecks.cmake b/CMakeScripts/ConfigChecks.cmake index 123263ff4..c475970c9 100644 --- a/CMakeScripts/ConfigChecks.cmake +++ b/CMakeScripts/ConfigChecks.cmake @@ -31,11 +31,6 @@ if(HAVE_CAIRO_PDF) set(PANGO_ENABLE_ENGINE TRUE) endif() -# Relocatable Binary -if (ENABLE_BINRELOC) - add_definitions(-DENABLE_BINRELOC) -endif() - # Create the configuration files config.h in the binary root dir configure_file(${CMAKE_SOURCE_DIR}/config.h.cmake ${CMAKE_BINARY_DIR}/include/config.h) add_definitions(-DHAVE_CONFIG_H) diff --git a/CMakeScripts/DefineDependsandFlags.cmake b/CMakeScripts/DefineDependsandFlags.cmake index a6b59e26a..aa637ead1 100644 --- a/CMakeScripts/DefineDependsandFlags.cmake +++ b/CMakeScripts/DefineDependsandFlags.cmake @@ -218,9 +218,9 @@ else() endif() if(WITH_LPETOOL) - add_definitions(-DWITH_LPETOOL -DLPE_ENABLE_TEST_EFFECTS) + set(LPE_ENABLE_TEST_EFFECTS ON) else() - add_definitions(-UWITH_LPETOOL -ULPE_ENABLE_TEST_EFFECTS) + set(LPE_ENABLE_TEST_EFFECTS OFF) endif() # ---------------------------------------------------------------------------- @@ -245,7 +245,6 @@ list(APPEND INKSCAPE_LIBS ${GTK3_LIBRARIES}) pkg_check_modules(GDL_3_6 gdl-3.0>=3.6) if("${GDL_3_6_FOUND}") message(STATUS "Using GDL 3.6 or higher") - add_definitions(-DWITH_GDL_3_6) set (WITH_GDL_3_6 ON) endif() @@ -351,7 +350,6 @@ if(WITH_YAML) set (WITH_YAML ON) list(APPEND INKSCAPE_INCS_SYS ${YAML_INCLUDE_DIRS}) list(APPEND INKSCAPE_LIBS ${YAML_LIBRARIES}) - add_definitions(-DWITH_YAML) else(YAML_FOUND) set(WITH_YAML OFF) message(STATUS "Could not locate the yaml library headers: xverb feature will be disabled") diff --git a/config.h.cmake b/config.h.cmake index 4584505f2..d899d6b8e 100644 --- a/config.h.cmake +++ b/config.h.cmake @@ -120,7 +120,13 @@ first (like Motorola and SPARC, unlike Intel and VAX). */ #cmakedefine WORDS_BIGENDIAN 1 +/* Enable LPE Tool? */ +#cmakedefine WITH_LPETOOL 1 + /* Do we want experimental, unsupported, unguaranteed, etc., LivePathEffects enabled? */ #cmakedefine LPE_ENABLE_TEST_EFFECTS 1 +/* Build using libyaml (for xverbs) */ +#cmakedefine WITH_YAML 1 + #endif /* _CONFIG_H_ */ diff --git a/src/main-cmdlinexact.cpp b/src/main-cmdlinexact.cpp index 46f42d0d2..a30251275 100644 --- a/src/main-cmdlinexact.cpp +++ b/src/main-cmdlinexact.cpp @@ -9,6 +9,10 @@ * more details: http://wiki.inkscape.org/wiki/index.php/Using_xverbs */ +#ifdef HAVE_CONFIG_H +# include "config.h" // only include where actually required! +#endif + #ifdef WITH_YAML #include <list> diff --git a/src/main-cmdlinexact.h b/src/main-cmdlinexact.h index 431b046fa..8b9c137d9 100644 --- a/src/main-cmdlinexact.h +++ b/src/main-cmdlinexact.h @@ -1,7 +1,10 @@ - #ifndef __INK_MAIN_CMD_LINE_XACTIONS_H__ #define __INK_MAIN_CMD_LINE_XACTIONS_H__ +#ifdef HAVE_CONFIG_H +# include "config.h" // only include where actually required! +#endif + #ifdef WITH_YAML /** \file diff --git a/src/main.cpp b/src/main.cpp index 5af472ff7..25119b43a 100644 --- a/src/main.cpp +++ b/src/main.cpp @@ -23,6 +23,10 @@ * Released under GNU GPL, read the file 'COPYING' for more information */ +#ifdef HAVE_CONFIG_H +# include "config.h" // only include where actually required! +#endif + // This has to be included prior to anything that includes setjmp.h, it croaks otherwise #include <png.h> diff --git a/src/path-prefix.h b/src/path-prefix.h index 929419c1d..71bbb40fb 100644 --- a/src/path-prefix.h +++ b/src/path-prefix.h @@ -12,6 +12,11 @@ */ #ifndef SEEN_PATH_PREFIX_H #define SEEN_PATH_PREFIX_H + +#ifdef HAVE_CONFIG_H +# include "config.h" // only include where actually required! +#endif + #include "prefix.h" |
