summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--cmake/Modules/GrComponent.cmake16
-rw-r--r--gr-atsc/CMakeLists.txt2
-rw-r--r--gr-audio/CMakeLists.txt2
-rw-r--r--gr-comedi/CMakeLists.txt2
-rw-r--r--gr-digital/CMakeLists.txt2
-rw-r--r--gr-noaa/CMakeLists.txt2
-rw-r--r--gr-pager/CMakeLists.txt2
-rw-r--r--gr-qtgui/CMakeLists.txt2
-rw-r--r--gr-trellis/CMakeLists.txt4
-rw-r--r--gr-uhd/CMakeLists.txt2
-rw-r--r--gr-video-sdl/CMakeLists.txt2
-rw-r--r--gr-vocoder/CMakeLists.txt2
-rw-r--r--gr-wxgui/CMakeLists.txt4
-rw-r--r--grc/CMakeLists.txt4
14 files changed, 30 insertions, 18 deletions
diff --git a/cmake/Modules/GrComponent.cmake b/cmake/Modules/GrComponent.cmake
index 3891f6981..d45b8003c 100644
--- a/cmake/Modules/GrComponent.cmake
+++ b/cmake/Modules/GrComponent.cmake
@@ -54,9 +54,21 @@ function(GR_REGISTER_COMPONENT name var)
set(var_force FALSE)
endif()
+ #rewrite the dependency list so that deps that are also components use the cached version
+ unset(comp_deps)
+ foreach(dep ${ARGN})
+ list(FIND _gr_enabled_components ${dep} dep_enb_index)
+ list(FIND _gr_disabled_components ${dep} dep_dis_index)
+ if (${dep_enb_index} EQUAL -1 AND ${dep_dis_index} EQUAL -1)
+ list(APPEND comp_deps ${dep})
+ else()
+ list(APPEND comp_deps ${dep}_cached) #is a component, use cached version
+ endif()
+ endforeach(dep)
+
#setup the dependent option for this component
- CMAKE_DEPENDENT_OPTION(${var} "enable ${name} support" ${ENABLE_DEFAULT} "${ARGN}" OFF)
- set(${var}_ "${${var}}" CACHE INTERNAL "" FORCE)
+ CMAKE_DEPENDENT_OPTION(${var} "enable ${name} support" ${ENABLE_DEFAULT} "${comp_deps}" OFF)
+ set(${var}_cached "${${var}}" CACHE INTERNAL "" FORCE)
#force was specified, but the dependencies were not met
if(NOT ${var} AND var_force)
diff --git a/gr-atsc/CMakeLists.txt b/gr-atsc/CMakeLists.txt
index 9ed084465..670ff7e40 100644
--- a/gr-atsc/CMakeLists.txt
+++ b/gr-atsc/CMakeLists.txt
@@ -28,7 +28,7 @@ include(GrBoost)
include(GrComponent)
GR_REGISTER_COMPONENT("gr-atsc" ENABLE_GR_ATSC
Boost_FOUND
- ENABLE_GR_CORE_
+ ENABLE_GR_CORE
)
GR_SET_GLOBAL(GR_ATSC_INCLUDE_DIRS
diff --git a/gr-audio/CMakeLists.txt b/gr-audio/CMakeLists.txt
index 839f4a49e..ce09c4456 100644
--- a/gr-audio/CMakeLists.txt
+++ b/gr-audio/CMakeLists.txt
@@ -28,7 +28,7 @@ include(GrBoost)
include(GrComponent)
GR_REGISTER_COMPONENT("gr-audio" ENABLE_GR_AUDIO
Boost_FOUND
- ENABLE_GR_CORE_
+ ENABLE_GR_CORE
)
GR_SET_GLOBAL(GR_AUDIO_INCLUDE_DIRS ${CMAKE_CURRENT_SOURCE_DIR}/include)
diff --git a/gr-comedi/CMakeLists.txt b/gr-comedi/CMakeLists.txt
index 9f97ba90d..b12177fda 100644
--- a/gr-comedi/CMakeLists.txt
+++ b/gr-comedi/CMakeLists.txt
@@ -34,7 +34,7 @@ GR_REGISTER_COMPONENT("gr-comedi" ENABLE_GR_COMEDI
COMEDI_FOUND
LINUX #comedi uses linux specific device noces
Boost_FOUND
- ENABLE_GR_CORE_
+ ENABLE_GR_CORE
)
remove_definitions(-fvisibility=hidden) #FIXME until we do symbol visibility
diff --git a/gr-digital/CMakeLists.txt b/gr-digital/CMakeLists.txt
index babf64eee..76128b7ce 100644
--- a/gr-digital/CMakeLists.txt
+++ b/gr-digital/CMakeLists.txt
@@ -28,7 +28,7 @@ include(GrBoost)
include(GrComponent)
GR_REGISTER_COMPONENT("gr-digital" ENABLE_GR_DIGITAL
Boost_FOUND
- ENABLE_GR_CORE_
+ ENABLE_GR_CORE
)
GR_SET_GLOBAL(GR_DIGITAL_INCLUDE_DIRS
diff --git a/gr-noaa/CMakeLists.txt b/gr-noaa/CMakeLists.txt
index eecb3d602..621dd5d6e 100644
--- a/gr-noaa/CMakeLists.txt
+++ b/gr-noaa/CMakeLists.txt
@@ -28,7 +28,7 @@ include(GrBoost)
include(GrComponent)
GR_REGISTER_COMPONENT("gr-noaa" ENABLE_GR_NOAA
Boost_FOUND
- ENABLE_GR_CORE_
+ ENABLE_GR_CORE
)
GR_SET_GLOBAL(GR_NOAA_INCLUDE_DIRS
diff --git a/gr-pager/CMakeLists.txt b/gr-pager/CMakeLists.txt
index 9d23e617d..8dfecced7 100644
--- a/gr-pager/CMakeLists.txt
+++ b/gr-pager/CMakeLists.txt
@@ -28,7 +28,7 @@ include(GrBoost)
include(GrComponent)
GR_REGISTER_COMPONENT("gr-pager" ENABLE_GR_PAGER
Boost_FOUND
- ENABLE_GR_CORE_
+ ENABLE_GR_CORE
)
GR_SET_GLOBAL(GR_PAGER_INCLUDE_DIRS
diff --git a/gr-qtgui/CMakeLists.txt b/gr-qtgui/CMakeLists.txt
index 90371625c..ac2491b90 100644
--- a/gr-qtgui/CMakeLists.txt
+++ b/gr-qtgui/CMakeLists.txt
@@ -40,7 +40,7 @@ GR_REGISTER_COMPONENT("gr-qtgui" ENABLE_GR_QTGUI
Boost_FOUND
QT4_FOUND
QWT_FOUND
- ENABLE_GR_CORE_
+ ENABLE_GR_CORE
PYTHONLIBS_FOUND
PYQT4_FOUND
)
diff --git a/gr-trellis/CMakeLists.txt b/gr-trellis/CMakeLists.txt
index 226ea7e4d..dc077571c 100644
--- a/gr-trellis/CMakeLists.txt
+++ b/gr-trellis/CMakeLists.txt
@@ -28,8 +28,8 @@ include(GrBoost)
include(GrComponent)
GR_REGISTER_COMPONENT("gr-trellis" ENABLE_GR_TRELLIS
Boost_FOUND
- ENABLE_GR_CORE_
- ENABLE_GR_DIGITAL_
+ ENABLE_GR_CORE
+ ENABLE_GR_DIGITAL
)
GR_SET_GLOBAL(GR_TRELLIS_INCLUDE_DIRS
diff --git a/gr-uhd/CMakeLists.txt b/gr-uhd/CMakeLists.txt
index d660cfd36..8eacc6105 100644
--- a/gr-uhd/CMakeLists.txt
+++ b/gr-uhd/CMakeLists.txt
@@ -31,7 +31,7 @@ include(GrComponent)
GR_REGISTER_COMPONENT("gr-uhd" ENABLE_GR_UHD
Boost_FOUND
UHD_FOUND
- ENABLE_GR_CORE_
+ ENABLE_GR_CORE
)
GR_SET_GLOBAL(GR_UHD_INCLUDE_DIRS
diff --git a/gr-video-sdl/CMakeLists.txt b/gr-video-sdl/CMakeLists.txt
index 43d11dce8..6b1d7f79e 100644
--- a/gr-video-sdl/CMakeLists.txt
+++ b/gr-video-sdl/CMakeLists.txt
@@ -31,7 +31,7 @@ include(GrComponent)
GR_REGISTER_COMPONENT("gr-video-sdl" ENABLE_GR_VIDEO_SDL
SDL_FOUND
Boost_FOUND
- ENABLE_GR_CORE_
+ ENABLE_GR_CORE
)
GR_SET_GLOBAL(GR_VIDEO_SDL_INCLUDE_DIRS
diff --git a/gr-vocoder/CMakeLists.txt b/gr-vocoder/CMakeLists.txt
index d14366400..f601b4670 100644
--- a/gr-vocoder/CMakeLists.txt
+++ b/gr-vocoder/CMakeLists.txt
@@ -28,7 +28,7 @@ include(GrBoost)
include(GrComponent)
GR_REGISTER_COMPONENT("gr-vocoder" ENABLE_GR_VOCODER
Boost_FOUND
- ENABLE_GR_CORE_
+ ENABLE_GR_CORE
)
GR_SET_GLOBAL(GR_VOCODER_INCLUDE_DIRS
diff --git a/gr-wxgui/CMakeLists.txt b/gr-wxgui/CMakeLists.txt
index 5bb9c3824..54fe4fb64 100644
--- a/gr-wxgui/CMakeLists.txt
+++ b/gr-wxgui/CMakeLists.txt
@@ -30,8 +30,8 @@ GR_PYTHON_CHECK_MODULE("numpy" numpy True
########################################################################
include(GrComponent)
GR_REGISTER_COMPONENT("gr-wxgui" ENABLE_WXGUI
- ENABLE_GR_CORE_
- ENABLE_PYTHON_
+ ENABLE_GR_CORE
+ ENABLE_PYTHON
NUMPY_FOUND
WX_FOUND
)
diff --git a/grc/CMakeLists.txt b/grc/CMakeLists.txt
index cc7696210..2f7305cb7 100644
--- a/grc/CMakeLists.txt
+++ b/grc/CMakeLists.txt
@@ -42,8 +42,8 @@ if(NOT CMAKE_CROSSCOMPILING)
endif(NOT CMAKE_CROSSCOMPILING)
GR_REGISTER_COMPONENT("gnuradio-companion" ENABLE_GRC
- ENABLE_GR_CORE_
- ENABLE_PYTHON_
+ ENABLE_GR_CORE
+ ENABLE_PYTHON
PYTHON_MIN_VER_FOUND
${grc_python_deps}
)