Permalink
Browse files

generate config.h

  • Loading branch information...
1 parent 7dd00a3 commit 773da55b35aaebd24979e8139e8c57abe9f55520 @tokuhirom committed Jul 13, 2012
Showing with 9 additions and 0 deletions.
  1. +2 −0 CMakeLists.txt
  2. +7 −0 tora/config.h.in
View
@@ -25,6 +25,8 @@ find_package(RE2C REQUIRED)
SET(TORA_VERSION "0.0.5")
+CONFIGURE_FILE(${CMAKE_CURRENT_SOURCE_DIR}/tora/config.h.in ${CMAKE_CURRENT_BINARY_DIR}/tora/config.h)
+
RE2C_TARGET(
tora/lexer.re
tora/lexer.gen.cc
View
@@ -0,0 +1,7 @@
+#ifndef TORA_CONFIG_H_
+#define TORA_CONFIG_H_
+
+#cmakedefine TORA_VERSION "@TORA_VERSION@"
+
+#endif // TORA_CONFIG_H_
+

0 comments on commit 773da55

Please sign in to comment.