Skip to content

Commit 1a35d70

Browse files
committed
build UPDATE new option to control building binaries
1 parent 5209845 commit 1a35d70

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

CMakeLists.txt

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -245,6 +245,7 @@ option(ENABLE_COVERAGE "Build code coverage report from tests" OFF)
245245
option(ENABLE_FUZZ_TARGETS "Build target programs suitable for fuzzing with AFL" OFF)
246246
option(ENABLE_INTERNAL_DOCS "Generate doxygen documentation also from internal headers" OFF)
247247
option(ENABLE_YANGLINT_INTERACTIVE "Enable interactive CLI yanglint" ON)
248+
option(ENABLE_TOOLS "Build binary tools 'yanglint' and 'yangre'" ON)
248249
option(BUILD_SHARED_LIBS "By default, shared libs are enabled. Turn off for a static build." ON)
249250
set(YANG_MODULE_DIR "${CMAKE_INSTALL_PREFIX}/${CMAKE_INSTALL_DATADIR}/yang/modules/libyang" CACHE STRING "Directory where to copy the YANG modules to")
250251

@@ -456,7 +457,9 @@ endif()
456457
gen_coverage("utest_.*" "utest_.*_valgrind")
457458

458459
# tools - yanglint, yangre
459-
add_subdirectory(tools)
460+
if(ENABLE_TOOLS)
461+
add_subdirectory(tools)
462+
endif()
460463

461464
# generate doxygen documentation for libyang API
462465
gen_doc("${doxy_files}" ${LIBYANG_VERSION} ${LIBYANG_DESCRIPTION} ${project_logo})

0 commit comments

Comments
 (0)