From 45713b0dd2376d4b441f6793d911c97696a4fc5c Mon Sep 17 00:00:00 2001 From: Moandor Date: Sat, 8 Aug 2020 01:23:55 +0800 Subject: [PATCH] [build] exclude URL library where unused (#5351) This sets the URL library to be included only in POSIX builds, removing unnecessary dependencies. --- src/lib/Makefile.am | 5 ++++- src/lib/url/CMakeLists.txt | 2 +- 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/src/lib/Makefile.am b/src/lib/Makefile.am index 1bb226c11..112372cda 100644 --- a/src/lib/Makefile.am +++ b/src/lib/Makefile.am @@ -32,7 +32,10 @@ SUBDIRS = \ hdlc \ platform \ spinel \ - url \ $(NULL) +if OPENTHREAD_PLATFORM_POSIX +SUBDIRS += url +endif + include $(abs_top_nlbuild_autotools_dir)/automake/post.am diff --git a/src/lib/url/CMakeLists.txt b/src/lib/url/CMakeLists.txt index 79c862935..dd55b0689 100644 --- a/src/lib/url/CMakeLists.txt +++ b/src/lib/url/CMakeLists.txt @@ -26,7 +26,7 @@ # POSSIBILITY OF SUCH DAMAGE. # -add_library(openthread-url +add_library(openthread-url EXCLUDE_FROM_ALL url.cpp )