From de3acc40fabcbf2efc71422bc867c882ffbdaa65 Mon Sep 17 00:00:00 2001 From: Stanislaw Halik Date: Thu, 18 Jan 2018 19:31:07 +0100 Subject: cmake: fix otr_module(x SUBDIRS ...) --- cmake/opentrack-boilerplate.cmake | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/cmake/opentrack-boilerplate.cmake b/cmake/opentrack-boilerplate.cmake index 0db91bd0..fca876ff 100644 --- a/cmake/opentrack-boilerplate.cmake +++ b/cmake/opentrack-boilerplate.cmake @@ -136,7 +136,12 @@ function(otr_module n_) set(n "opentrack-${n_}") - otr_glob_sources(${n} ${arg_SUBDIRS}) + if(NOT arg_SUBDIRS) + otr_glob_sources(${n} .) + else() + otr_glob_sources(${n} ${arg_SUBDIRS}) + endif() + list(APPEND ${n}-all ${arg_SOURCES}) if(NOT arg_NO-QT) -- cgit v1.2.3