Skip to content

Commit cdb47df

Browse files
ksh8281clover2123
authored andcommitted
Generate EscargotInfo.h file in CMAKE_BINARY_DIR/escargot_generated/ not on src
Signed-off-by: Seonghyun Kim <[email protected]>
1 parent 98133d2 commit cdb47df

File tree

2 files changed

+6
-3
lines changed

2 files changed

+6
-3
lines changed

.gitignore

+1
Original file line numberDiff line numberDiff line change
@@ -39,3 +39,4 @@ cmake_install.cmake
3939
.vscode
4040
EscargotInfo.h
4141
escargot.pc
42+
escargot_generated/*

build/config.cmake

+5-3
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,9 @@ CMAKE_MINIMUM_REQUIRED (VERSION 2.8.12 FATAL_ERROR)
33
#######################################################
44
# CONFIGURATION
55
#######################################################
6+
SET (ESCARGOT_LIBRARIES)
7+
SET (ESCARGOT_INCDIRS)
8+
69
# CONFIGURE ESCARGOT VERSION
710
FIND_PACKAGE(Git)
811
IF (GIT_FOUND)
@@ -17,7 +20,8 @@ IF ((NOT DEFINED ESCARGOT_BUILD_VERSION) OR (ESCARGOT_BUILD_VERSION STREQUAL "")
1720
FILE (STRINGS "${PROJECT_SOURCE_DIR}/RELEASE_VERSION" ESCARGOT_BUILD_VERSION)
1821
ENDIF()
1922
MESSAGE(STATUS "Escargot Build Version: ${ESCARGOT_BUILD_VERSION}")
20-
CONFIGURE_FILE (${PROJECT_SOURCE_DIR}/src/EscargotInfo.h.in ${PROJECT_SOURCE_DIR}/src/EscargotInfo.h @ONLY)
23+
CONFIGURE_FILE (${PROJECT_SOURCE_DIR}/src/EscargotInfo.h.in ${CMAKE_BINARY_DIR}/escargot_generated/EscargotInfo.h @ONLY)
24+
SET (ESCARGOT_INCDIRS ${ESCARGOT_INCDIRS} ${CMAKE_BINARY_DIR}/escargot_generated)
2125

2226
#######################################################
2327
# PATH
@@ -29,8 +33,6 @@ SET (GCUTIL_ROOT ${ESCARGOT_THIRD_PARTY_ROOT}/GCutil)
2933
#######################################################
3034
# FLAGS FOR TARGET
3135
#######################################################
32-
SET (ESCARGOT_LIBRARIES)
33-
SET (ESCARGOT_INCDIRS)
3436
INCLUDE (${ESCARGOT_ROOT}/build/target.cmake)
3537

3638
#######################################################

0 commit comments

Comments
 (0)