unqlite: Patching unqlite to be able to build a shared library (#15830)

* Patching unqlite to be able to build a shared library

* Correcting a whitespace for flake8 to pass

* added comment about PR on unqlite

* extra commit to force github to merge
This commit is contained in:
Matthieu Dorier 2020-04-02 23:15:45 +01:00 committed by GitHub
parent 144557e945
commit 8b52f9f37d
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 34 additions and 0 deletions

View file

@ -0,0 +1,26 @@
From 7c14b18c4967c04344ceba2da90467cd27ee5678 Mon Sep 17 00:00:00 2001
From: Matthieu Dorier <mdorier@anl.gov>
Date: Thu, 2 Apr 2020 12:43:19 +0100
Subject: [PATCH] Removed the STATIC key word to enable building a shared
library
---
CMakeLists.txt | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/CMakeLists.txt b/CMakeLists.txt
index f2bb3cd..efb63a7 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -18,7 +18,7 @@ SET(SOURCES_UNQLITE
)
SET(UNQLITE_STATIC_LIB unqlite)
-ADD_LIBRARY(${UNQLITE_STATIC_LIB} STATIC ${HEADERS_UNQLITE} ${SOURCES_UNQLITE})
+ADD_LIBRARY(${UNQLITE_STATIC_LIB} ${HEADERS_UNQLITE} ${SOURCES_UNQLITE})
INSTALL(TARGETS ${UNQLITE_STATIC_LIB} COMPONENT devel ARCHIVE DESTINATION lib)
INSTALL(FILES ${HEADERS_UNQLITE} COMPONENT devel DESTINATION include)
--
2.20.1

View file

@ -16,3 +16,11 @@ class Unqlite(CMakePackage):
version('master', branch='master') version('master', branch='master')
version('1.1.9', sha256='33d5b5e7b2ca223942e77d31112d2e20512bc507808414451c8a98a7be5e15c0') version('1.1.9', sha256='33d5b5e7b2ca223942e77d31112d2e20512bc507808414451c8a98a7be5e15c0')
# This patch corresponds to https://github.com/symisc/unqlite/pull/99
# It should restricted to @1.1.9 once the PR lands.
patch('0001-Removed-the-STATIC-key-word-to-enable-building-a-sha.patch')
def cmake_args(self):
args = ["-DBUILD_SHARED_LIBS:BOOL=ON"]
return args