From a904183b4e65a6d982db3d12ad9d0a9a883edc1d Mon Sep 17 00:00:00 2001 From: Yegor Yefremov Date: Tue, 11 Mar 2025 18:16:27 +0100 Subject: [PATCH] CMakeLists.txt: add an option to control shared library creation Signed-off-by: Yegor Yefremov --- CMakeLists.txt | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index 8f1dbcd..6c73566 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -19,6 +19,7 @@ endif() # Add an option to enable treating warnings as errors option(ENABLE_WERROR "Treat all compiler warnings as errors" OFF) option(ENABLE_GPS "Enable GPS support" OFF) +option(BUILD_SHARED_LIBS "Build shared libraries" ON) find_package(PkgConfig REQUIRED) if(ENABLE_GPS) @@ -129,7 +130,7 @@ if(NOT ANDROID) PRIVATE can ) - add_library(isobusfs SHARED + add_library(isobusfs isobusfs/isobusfs_cmn.c isobusfs/isobusfs_cmn_dh.c )