aboutsummaryrefslogtreecommitdiffstats
path: root/host/CMakeLists.txt
diff options
context:
space:
mode:
Diffstat (limited to 'host/CMakeLists.txt')
-rw-r--r--host/CMakeLists.txt13
1 files changed, 13 insertions, 0 deletions
diff --git a/host/CMakeLists.txt b/host/CMakeLists.txt
index beb4d396f..c235ffe82 100644
--- a/host/CMakeLists.txt
+++ b/host/CMakeLists.txt
@@ -281,6 +281,19 @@ LIBUHD_REGISTER_COMPONENT("Utils" ENABLE_UTILS ON "ENABLE_LIBUHD" OFF)
LIBUHD_REGISTER_COMPONENT("Tests" ENABLE_TESTS ON "ENABLE_LIBUHD" OFF)
########################################################################
+# Check for fpga-src submodule
+########################################################################
+SET(HAS_FPGA_SUBMODULE FALSE)
+EXECUTE_PROCESS(
+ COMMAND ${PYTHON_EXECUTABLE} -c "import os; print os.path.abspath(os.path.join('${CMAKE_SOURCE_DIR}', '..', 'fpga-src'))"
+ OUTPUT_VARIABLE FPGA_SUBMODULE_DIR OUTPUT_STRIP_TRAILING_WHITESPACE
+)
+message(STATUS ${FPGA_SUBMODULE_DIR})
+IF(EXISTS "${FPGA_SUBMODULE_DIR}/docs/fpga.md")
+ SET(HAS_FPGA_SUBMODULE TRUE)
+ENDIF(EXISTS "${FPGA_SUBMODULE_DIR}/docs/fpga.md")
+
+########################################################################
# Add the subdirectories
########################################################################
ADD_SUBDIRECTORY(docs)