aboutsummaryrefslogtreecommitdiffstats
path: root/CMakeLists.txt
diff options
context:
space:
mode:
Diffstat (limited to 'CMakeLists.txt')
-rw-r--r--CMakeLists.txt5
1 files changed, 4 insertions, 1 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 07edfca3..410c0204 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -89,7 +89,7 @@ STRING( REGEX REPLACE ".*([0-9]+)\\.[0-9]+\\.[0-9]+.*" "\\1" GAWK_MAJOR_VERSION
STRING( REGEX REPLACE ".*[0-9]+\\.([0-9]+)\\.[0-9]+.*" "\\1" GAWK_MINOR_VERSION "${GAWK_AUTOMAKE_LINE_VERSION}")
STRING( REGEX REPLACE ".*[0-9]+\\.[0-9]+\\.([0-9]+).*" "\\1" GAWK_BUGFIX_VERSION "${GAWK_AUTOMAKE_LINE_VERSION}")
-add_definitions(-D GAWK)
+add_definitions(-DGAWK)
set(GAWK_VERSION "${GAWK_MAJOR_VERSION}.${GAWK_MINOR_VERSION}.${GAWK_BUGFIX_VERSION}")
add_definitions(-D VERSION=\\"${GAWK_VERSION}\\")
add_definitions(-D PACKAGE=\\"gawk\\")
@@ -270,6 +270,9 @@ set (GAWK_SOURCES ${GAWK_SOURCES}
add_executable (gawk ${GAWK_SOURCES})
target_link_libraries (gawk m ${EXTRA_LIBS})
+# Beware: before building the extension, -DGAWK gets undefined.
+add_subdirectory(extension)
+
if(NOT ${CMAKE_CROSSCOMPILING} STREQUAL "TRUE")
enable_testing()
add_subdirectory(test)