[packages/sqlitebrowser] - up to 3.11.2 - really build with system libs - qt5 project now
baggins
baggins at pld-linux.org
Mon Sep 16 00:10:10 CEST 2019
commit b22885d11c080eea24ed857849399348d358d053
Author: Jan Rękorajski <baggins at pld-linux.org>
Date: Mon Sep 16 00:08:59 2019 +0200
- up to 3.11.2
- really build with system libs
- qt5 project now
sqlitebrowser.spec | 36 +++++++++++++++++++++---------------
system-libs.patch | 41 +++++++++++++++++++++++++++++++++++++++++
2 files changed, 62 insertions(+), 15 deletions(-)
---
diff --git a/sqlitebrowser.spec b/sqlitebrowser.spec
index 0a2fe23..0063aad 100644
--- a/sqlitebrowser.spec
+++ b/sqlitebrowser.spec
@@ -1,22 +1,26 @@
-# TODO: use system-wide QCustomPlot
+# TODO: use system-wide QCustomPlot and QHexEdit
Summary: DB Browser for SQLite
Name: sqlitebrowser
-Version: 3.7.0
-Release: 6
+Version: 3.11.2
+Release: 1
License: MPLv2/GPLv3
Group: Applications/Databases/Interfaces
-Source0: https://github.com/sqlitebrowser/sqlitebrowser/archive/v%{version}.tar.gz
-# Source0-md5: 1033f076944316a713d4831bf581cf3a
+Source0: https://github.com/sqlitebrowser/sqlitebrowser/archive/v%{version}/%{name}-%{version}.tar.gz
+# Source0-md5: 9991541d1f93ebcd7769ac8e15475c71
+Patch0: system-libs.patch
URL: http://sqlitebrowser.org/
-#BuildRequires: QCustomPlot-devel
-BuildRequires: QtCore-devel
-BuildRequires: QtGui-devel
-BuildRequires: QtNetwork-devel
+BuildRequires: Qt5Concurrent-devel
+BuildRequires: Qt5Gui-devel
+BuildRequires: Qt5Network-devel
+BuildRequires: Qt5PrintSupport-devel
+BuildRequires: Qt5Test-devel
+BuildRequires: Qt5Widgets-devel
+BuildRequires: Qt5Xml-devel
BuildRequires: antlr
BuildRequires: cmake >= 2.8.7
-BuildRequires: qscintilla2-qt4-devel
-BuildRequires: qt4-build
-BuildRequires: qt4-linguist
+BuildRequires: qscintilla2-qt5-devel
+BuildRequires: qt5-build
+BuildRequires: qt5-linguist
BuildRequires: rpmbuild(macros) >= 1.596
BuildRequires: sqlite3-devel
Requires: desktop-file-utils
@@ -33,14 +37,16 @@ to create databases, edit and search data using a familiarspreadsheet-
%prep
%setup -q
-# use system-wide qscintilla2
-sed -e '/QSCINTILLA_DIR[ }][^"]/d' -e 's/qcustomplot qscintilla2/qcustomplot/' -i CMakeLists.txt
+%patch0 -p1
+
+%{__rm} -r libs/{antlr-*,qscintilla}
%build
mkdir build
cd build
%cmake ../ \
- -DBUILD_SHARED_LIBS:BOOL=OFF
+ -DBUILD_SHARED_LIBS:BOOL=OFF \
+ -DQT_INCLUDE_DIR:PATH=%{_includedir}/qt5
%{__make}
%install
diff --git a/system-libs.patch b/system-libs.patch
new file mode 100644
index 0000000..dd55f26
--- /dev/null
+++ b/system-libs.patch
@@ -0,0 +1,41 @@
+diff -rupN sqlitebrowser-3.11.2/cmake/FindQScintilla.cmake sqlitebrowser-3.11.2-new/cmake/FindQScintilla.cmake
+--- sqlitebrowser-3.11.2/cmake/FindQScintilla.cmake 2019-04-03 14:36:58.000000000 +0200
++++ sqlitebrowser-3.11.2-new/cmake/FindQScintilla.cmake 2019-04-04 10:37:16.923765903 +0200
+@@ -80,7 +80,7 @@ endif ()
+
+
+ find_library ( QSCINTILLA_LIBRARY
+- NAMES qscintilla qscintilla2 libqscintilla2
++ NAMES qscintilla qscintilla2-qt5 libqscintilla2-qt5 qscintilla2_qt5 libqscintilla2_qt5
+ HINTS ${QT_LIBRARY_DIR}
+ )
+
+diff -rupN sqlitebrowser-3.11.2/CMakeLists.txt sqlitebrowser-3.11.2-new/CMakeLists.txt
+--- sqlitebrowser-3.11.2/CMakeLists.txt 2019-04-03 14:36:58.000000000 +0200
++++ sqlitebrowser-3.11.2-new/CMakeLists.txt 2019-04-04 10:37:16.923765903 +0200
+@@ -336,16 +335,6 @@ endif()
+ ${QCUSTOMPLOT_DIR}
+ ${ADDITIONAL_INCLUDE_PATHS}
+ src)
+-if(ANTLR2_FOUND)
+- include_directories(${ANTLR2_INCLUDE_DIRS})
+-else()
+- include_directories(${ANTLR_DIR})
+-endif()
+-if(QSCINTILLA_FOUND)
+- include_directories(${QSCINTILLA_INCLUDE_DIR})
+-else()
+- include_directories(${QSCINTILLA_DIR})
+-endif()
+
+ add_executable(${PROJECT_NAME}
+ ${SQLB_HDR}
+@@ -396,7 +382,7 @@ endif()
+ if(QSCINTILLA_FOUND)
+ target_link_libraries(${PROJECT_NAME} ${QSCINTILLA_LIBRARIES})
+ else()
+- target_link_libraries(${PROJECT_NAME} qscintilla2)
++ target_link_libraries(${PROJECT_NAME} qscintilla2_qt5)
+ endif()
+
+ if(WIN32 AND MSVC)
================================================================
---- gitweb:
http://git.pld-linux.org/gitweb.cgi/packages/sqlitebrowser.git/commitdiff/b22885d11c080eea24ed857849399348d358d053
More information about the pld-cvs-commit
mailing list