From e194cec922d114773959b8f3dc8a518e0092fc03 Mon Sep 17 00:00:00 2001 From: "Eduardo Ramos Testillano (eramedu)" Date: Sun, 12 Apr 2020 19:04:35 +0200 Subject: [PATCH] Skip oracle and database build by mean cmake variable You could avoid database resources compilation to ease the add of requirements: > cmake -DSKIP_DATABASE_BUILD=1 . --- CMakeLists.txt | 9 +++++++++ README.md | 4 ++++ 2 files changed, 13 insertions(+) diff --git a/CMakeLists.txt b/CMakeLists.txt index 11a2a24..1e53a36 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -100,6 +100,15 @@ MACRO(SUBDIRLIST result curdir) FILE(GLOB children RELATIVE ${curdir} ${curdir}/*) SET(dirlist "") FOREACH(child ${children}) + + # EXCLUDE DATABASE RESOURCES (-DSKIP_DATABASE_BUILD) + if(SKIP_DATABASE_BUILD) + string(REGEX MATCH "dbms|dbos" DATABASE ${child}) + IF(DATABASE) + CONTINUE() + ENDIF() + ENDIF() + IF(IS_DIRECTORY ${curdir}/${child}) LIST(APPEND dirlist ${child}) ENDIF() diff --git a/README.md b/README.md index 5bf77ea..8826728 100644 --- a/README.md +++ b/README.md @@ -30,6 +30,10 @@ You could specify type of build, 'Debug' or 'Release', for example: > cmake -DCMAKE_BUILD_TYPE=Debug . > cmake -DCMAKE_BUILD_TYPE=Release . +You could avoid database resources compilation to ease the add of requirements: + + > cmake -DSKIP_DATABASE_BUILD=1 . + ## Clean project > make clean -- 2.20.1