introduce sqlite-tools package

This commit is contained in:
Petr Kubat 2020-01-20 10:41:54 +01:00
parent 683ae70000
commit 5cf0d06ce8

View File

@ -1,5 +1,6 @@
# bcond default logic is nicely backwards... # bcond default logic is nicely backwards...
%bcond_without tcl %bcond_without tcl
%bcond_without sqldiff
%bcond_with static %bcond_with static
%bcond_without check %bcond_without check
@ -10,7 +11,7 @@
Summary: Library that implements an embeddable SQL database engine Summary: Library that implements an embeddable SQL database engine
Name: sqlite Name: sqlite
Version: %{rpmver} Version: %{rpmver}
Release: 2%{?dist} Release: 3%{?dist}
License: Public Domain License: Public Domain
URL: http://www.sqlite.org/ URL: http://www.sqlite.org/
@ -101,6 +102,17 @@ that can be used to eliminate resource leaks, making is suitable for
use in long-running programs such as graphical user interfaces or use in long-running programs such as graphical user interfaces or
embedded controllers. embedded controllers.
%if %{with sqldiff}
%package tools
Summary: %{name} tools
Group: Development/Tools
%description tools
%{name} related tools. Currently contains only sqldiff.
- sqldiff: The sqldiff binary is a command-line utility program
that displays the differences between SQLite databases.
%endif
%if %{with tcl} %if %{with tcl}
%package tcl %package tcl
Summary: Tcl module for the sqlite3 embeddable SQL database engine Summary: Tcl module for the sqlite3 embeddable SQL database engine
@ -161,6 +173,11 @@ make %{?_smp_mflags}
make %{?_smp_mflags} sqlite3_analyzer make %{?_smp_mflags} sqlite3_analyzer
%endif %endif
# Build sqldiff
%if %{with tcl}
make %{?_smp_mflags} sqldiff
%endif
%install %install
make DESTDIR=${RPM_BUILD_ROOT} install make DESTDIR=${RPM_BUILD_ROOT} install
@ -175,6 +192,11 @@ chmod 0755 ${RPM_BUILD_ROOT}/%{tcl_sitearch}/sqlite3/*.so
install -D -m0755 sqlite3_analyzer $RPM_BUILD_ROOT/%{_bindir}/sqlite3_analyzer install -D -m0755 sqlite3_analyzer $RPM_BUILD_ROOT/%{_bindir}/sqlite3_analyzer
%endif %endif
# Install sqldiff
%if %{with tcl}
install -D -m0755 sqldiff $RPM_BUILD_ROOT/%{_bindir}/sqldiff
%endif
%if ! %{with static} %if ! %{with static}
rm -f $RPM_BUILD_ROOT/%{_libdir}/*.{la,a} rm -f $RPM_BUILD_ROOT/%{_libdir}/*.{la,a}
%endif %endif
@ -228,11 +250,19 @@ make test
%files tcl %files tcl
%{tcl_sitearch}/sqlite3 %{tcl_sitearch}/sqlite3
%if %{with sqldiff}
%files tools
%{_bindir}/sqldiff
%endif
%files analyzer %files analyzer
%{_bindir}/sqlite3_analyzer %{_bindir}/sqlite3_analyzer
%endif %endif
%changelog %changelog
* Mon Jan 20 2020 Petr Kubat <pkubat@redhat.com> - 3.30.1-3
- introduce sqlite-tools package
* Thu Jan 9 2020 Tom Callaway <spot@fedoraproject.org> - 3.30.1-2 * Thu Jan 9 2020 Tom Callaway <spot@fedoraproject.org> - 3.30.1-2
- apply upstream fix for CVE-2019-19926 (bz1789441) - apply upstream fix for CVE-2019-19926 (bz1789441)