X-Git-Url: https://review.fuel-infra.org/gitweb?a=blobdiff_plain;f=cirros-testvm%2Fsrc-cirros%2Fbuildroot-2015.05%2Fpackage%2Ftaglib%2F0001-cmake-use-the-standard-CMake-flag-to-drive-the-share.patch;fp=cirros-testvm%2Fsrc-cirros%2Fbuildroot-2015.05%2Fpackage%2Ftaglib%2F0001-cmake-use-the-standard-CMake-flag-to-drive-the-share.patch;h=535ccb4d387479e35abea603882c6e6c7b06b43d;hb=b0a0f15dfaa205161a7fcb20cf1b8cd4948c2ef3;hp=0000000000000000000000000000000000000000;hpb=c6ac3cd55ee2da956195eee393b0882105dfad4e;p=packages%2Ftrusty%2Fcirros-testvm.git diff --git a/cirros-testvm/src-cirros/buildroot-2015.05/package/taglib/0001-cmake-use-the-standard-CMake-flag-to-drive-the-share.patch b/cirros-testvm/src-cirros/buildroot-2015.05/package/taglib/0001-cmake-use-the-standard-CMake-flag-to-drive-the-share.patch new file mode 100644 index 0000000..535ccb4 --- /dev/null +++ b/cirros-testvm/src-cirros/buildroot-2015.05/package/taglib/0001-cmake-use-the-standard-CMake-flag-to-drive-the-share.patch @@ -0,0 +1,40 @@ +From 4e6a75eed3602f10aff516f49c8088c6da8db9df Mon Sep 17 00:00:00 2001 +From: Samuel Martin +Date: Sun, 31 Aug 2014 12:11:57 +0200 +Subject: [PATCH 1/1] cmake: use the standard CMake flag to drive the shared + object build + +If BUILD_SHARED_LIBS is set and ENABLE_STATIC undefined, then drive +ENABLE_STATIC with the BUILD_SHARED_LIBS value. + +Signed-off-by: Samuel Martin +--- + CMakeLists.txt | 12 +++++++++++- + 1 file changed, 11 insertions(+), 1 deletion(-) + +diff --git a/CMakeLists.txt b/CMakeLists.txt +index 317ffa1..9931957 100644 +--- a/CMakeLists.txt ++++ b/CMakeLists.txt +@@ -2,7 +2,17 @@ project(taglib) + + cmake_minimum_required(VERSION 2.6.0 FATAL_ERROR) + +-option(ENABLE_STATIC "Make static version of libtag" OFF) ++# Use the standard CMake flag to drive the shared object build. ++if(DEFINED BUILD_SHARED_LIBS AND NOT DEFINED ENABLE_STATIC) ++ if(BUILD_SHARED_LIBS) ++ set(ENABLE_STATIC OFF) ++ else() ++ set(ENABLE_STATIC ON) ++ endif() ++else() ++ option(ENABLE_STATIC "Make static version of libtag" OFF) ++endif() ++ + if(ENABLE_STATIC) + add_definitions(-DTAGLIB_STATIC) + set(BUILD_SHARED_LIBS OFF) +-- +2.1.0 +