2008-01-14 10:18:35 +01:00
|
|
|
#
|
2011-01-24 16:01:30 +01:00
|
|
|
# spec file for package sqlite3
|
2008-01-14 10:18:35 +01:00
|
|
|
#
|
2021-01-25 16:23:22 +01:00
|
|
|
# Copyright (c) 2021 SUSE LLC
|
2008-01-14 10:18:35 +01:00
|
|
|
#
|
2008-09-13 12:16:31 +02:00
|
|
|
# All modifications and additions to the file contributed by third parties
|
|
|
|
# remain the property of their copyright owners, unless otherwise agreed
|
|
|
|
# upon. The license for this file, and modifications and additions to the
|
|
|
|
# file, is the same license as for the pristine package itself (unless the
|
|
|
|
# license for the pristine package is not an Open Source License, in which
|
|
|
|
# case the license is the MIT License). An "Open Source License" is a
|
|
|
|
# license that conforms to the Open Source Definition (Version 1.9)
|
|
|
|
# published by the Open Source Initiative.
|
|
|
|
|
2019-01-17 18:17:18 +01:00
|
|
|
# Please submit bugfixes or comments via https://bugs.opensuse.org/
|
2008-01-14 10:18:35 +01:00
|
|
|
#
|
|
|
|
|
|
|
|
|
2014-01-07 18:09:45 +01:00
|
|
|
%define oname sqlite
|
2021-06-25 15:38:01 +02:00
|
|
|
%define tarversion 3360000
|
2020-06-20 13:26:28 +02:00
|
|
|
%bcond_with icu
|
2016-08-02 14:04:29 +02:00
|
|
|
Name: sqlite3
|
2021-06-25 15:38:01 +02:00
|
|
|
Version: 3.36.0
|
2012-05-04 13:08:27 +02:00
|
|
|
Release: 0
|
|
|
|
Summary: Embeddable SQL Database Engine
|
2011-12-06 19:05:34 +01:00
|
|
|
License: SUSE-Public-Domain
|
2008-01-14 10:18:35 +01:00
|
|
|
Group: Productivity/Databases/Servers
|
2020-06-20 13:26:28 +02:00
|
|
|
URL: https://www.sqlite.org/
|
2021-04-20 10:14:11 +02:00
|
|
|
Source0: https://www.sqlite.org/2021/sqlite-src-%{tarversion}.zip
|
2016-01-07 15:08:29 +01:00
|
|
|
Source1: baselibs.conf
|
2021-04-20 10:14:11 +02:00
|
|
|
Source2: https://www.sqlite.org/2021/sqlite-doc-%{tarversion}.zip
|
2016-03-07 15:02:44 +01:00
|
|
|
BuildRequires: automake
|
|
|
|
BuildRequires: libtool
|
2016-08-02 14:04:29 +02:00
|
|
|
BuildRequires: pkgconfig
|
2012-05-04 13:08:27 +02:00
|
|
|
BuildRequires: readline-devel
|
2018-06-29 15:06:55 +02:00
|
|
|
BuildRequires: tcl-devel
|
2014-02-13 11:47:47 +01:00
|
|
|
BuildRequires: unzip
|
2021-04-06 17:00:05 +02:00
|
|
|
%if 0%{suse_version} < 1500
|
|
|
|
# As of 2021 we still need to be able to compile this on SLE-12
|
|
|
|
BuildRoot: %{_tmppath}/%{name}-%{version}-build
|
|
|
|
BuildRequires: zlib-devel
|
|
|
|
%global make_build make
|
|
|
|
%else
|
2018-02-02 09:02:41 +01:00
|
|
|
BuildRequires: pkgconfig(zlib)
|
2021-04-06 17:00:05 +02:00
|
|
|
%endif
|
2016-01-07 15:08:29 +01:00
|
|
|
Provides: %{oname} = %{version}
|
|
|
|
Obsoletes: %{oname} < %{version}
|
2020-06-20 13:26:28 +02:00
|
|
|
%if %{with icu}
|
|
|
|
BuildRequires: libicu-devel
|
|
|
|
%endif
|
2014-01-07 18:09:45 +01:00
|
|
|
|
2008-01-14 10:18:35 +01:00
|
|
|
%description
|
|
|
|
SQLite is a C library that implements an embeddable SQL database
|
|
|
|
engine. Programs that link with the SQLite library can have SQL
|
|
|
|
database access without running a separate RDBMS process.
|
|
|
|
|
|
|
|
SQLite is not a client library used to connect to a big database
|
|
|
|
server. SQLite is a server and the SQLite library reads and writes
|
|
|
|
directly to and from the database files on disk.
|
|
|
|
|
|
|
|
SQLite can be used via the sqlite command line tool or via any
|
|
|
|
application that supports the Qt database plug-ins.
|
|
|
|
|
|
|
|
%package -n libsqlite3-0
|
|
|
|
Summary: Shared libraries for the Embeddable SQL Database Engine
|
|
|
|
Group: Development/Libraries/C and C++
|
|
|
|
|
|
|
|
%description -n libsqlite3-0
|
|
|
|
This package contains the shared libraries for the Embeddable SQL
|
|
|
|
Database Engine.
|
|
|
|
|
|
|
|
SQLite is a C library that implements an embeddable SQL database
|
|
|
|
engine. Programs that link with the SQLite library can have SQL
|
|
|
|
database access without running a separate RDBMS process.
|
|
|
|
|
|
|
|
SQLite is not a client library used to connect to a big database
|
|
|
|
server. SQLite is a server and the SQLite library reads and writes
|
|
|
|
directly to and from the database files on disk.
|
|
|
|
|
|
|
|
SQLite can be used via the sqlite command line tool or via any
|
|
|
|
application that supports the Qt database plug-ins.
|
|
|
|
|
|
|
|
%package devel
|
|
|
|
Summary: Embeddable SQL Database Engine
|
2012-05-04 13:08:27 +02:00
|
|
|
Group: Development/Libraries/C and C++
|
|
|
|
Requires: glibc-devel
|
2016-01-07 15:08:29 +01:00
|
|
|
Requires: libsqlite3-0 = %{version}
|
|
|
|
Suggests: %{name}-doc
|
|
|
|
Provides: %{oname}-devel = %{version}
|
|
|
|
Obsoletes: %{oname}-devel < %{version}
|
2008-01-14 10:18:35 +01:00
|
|
|
|
|
|
|
%description devel
|
|
|
|
SQLite is a C library that implements an embeddable SQL database
|
|
|
|
engine. Programs that link with the SQLite library can have SQL
|
|
|
|
database access without running a separate RDBMS process.
|
|
|
|
|
|
|
|
SQLite is not a client library used to connect to a big database
|
|
|
|
server; SQLite is the server. The SQLite library reads and writes
|
|
|
|
directly to and from the database files on disk.
|
|
|
|
|
|
|
|
SQLite can be used via the sqlite command-line tool or via any
|
|
|
|
application which supports the Qt database plug-ins.
|
|
|
|
|
2014-02-13 11:47:47 +01:00
|
|
|
%package doc
|
2016-01-07 15:08:29 +01:00
|
|
|
Summary: Documentation for %{name}
|
2016-08-02 14:04:29 +02:00
|
|
|
Group: Documentation/Other
|
2014-02-13 11:47:47 +01:00
|
|
|
BuildArch: noarch
|
|
|
|
|
|
|
|
%description doc
|
|
|
|
|
|
|
|
Contains HTML documentation for SQLite: SQL Syntax, C/C++ API and
|
|
|
|
other documentation found on sqlite.org. The files can be found in
|
2016-01-07 15:08:29 +01:00
|
|
|
%{_docdir}/%{name}-doc.
|
2014-02-13 11:47:47 +01:00
|
|
|
|
2008-01-14 10:18:35 +01:00
|
|
|
%prep
|
2018-06-11 16:45:59 +02:00
|
|
|
%setup -q -n sqlite-src-%{tarversion} -a2
|
2020-01-21 08:56:37 +01:00
|
|
|
|
2014-03-29 19:10:03 +01:00
|
|
|
rm -v sqlite-doc-%{tarversion}/releaselog/current.html
|
|
|
|
ln -sv `echo %{version} | sed "s/\./_/g"`.html sqlite-doc-%{tarversion}/releaselog/current.html
|
2017-08-30 12:34:18 +02:00
|
|
|
find -type f -name sqlite.css~ -delete
|
2020-01-21 08:56:37 +01:00
|
|
|
cmp sqlite-doc-%{tarversion}/fileformat{,2}.html && ln -sf fileformat.html sqlite-doc-%{tarversion}/fileformat2.html
|
2008-01-14 10:18:35 +01:00
|
|
|
|
|
|
|
%build
|
2020-01-21 08:56:37 +01:00
|
|
|
export LIBS="$LIBS -lm %{?with_icu:-licuuc -licui18n}"
|
2016-01-07 15:08:29 +01:00
|
|
|
export CFLAGS="%{optflags} \
|
2016-03-25 09:53:27 +01:00
|
|
|
-DSQLITE_ENABLE_API_ARMOR \
|
2015-10-15 17:23:13 +02:00
|
|
|
-DSQLITE_ENABLE_COLUMN_METADATA \
|
2016-03-25 09:53:27 +01:00
|
|
|
-DSQLITE_ENABLE_DBSTAT_VTAB \
|
|
|
|
-DSQLITE_ENABLE_HIDDEN_COLUMNS \
|
2018-07-04 11:26:58 +02:00
|
|
|
-DSQLITE_ENABLE_FTS3 \
|
2015-10-15 17:23:13 +02:00
|
|
|
-DSQLITE_ENABLE_FTS4 \
|
2016-03-07 15:02:44 +01:00
|
|
|
-DSQLITE_ENABLE_FTS5 \
|
2020-01-21 08:56:37 +01:00
|
|
|
%if %{with icu}
|
|
|
|
-DSQLITE_ENABLE_ICU \
|
|
|
|
%endif
|
2015-10-15 17:23:13 +02:00
|
|
|
-DSQLITE_ENABLE_JSON1 \
|
2016-03-25 09:53:27 +01:00
|
|
|
-DSQLITE_ENABLE_RBU \
|
|
|
|
-DSQLITE_ENABLE_RTREE \
|
2018-06-07 13:00:01 +02:00
|
|
|
-DSQLITE_ENABLE_UPDATE_DELETE_LIMIT \
|
2016-03-25 09:53:27 +01:00
|
|
|
-DSQLITE_SOUNDEX \
|
|
|
|
-DSQLITE_ENABLE_UNLOCK_NOTIFY \
|
|
|
|
-DSQLITE_SECURE_DELETE \
|
2021-03-19 17:18:37 +01:00
|
|
|
-DSQLITE_ENABLE_MATH_FUNCTIONS \
|
2015-10-15 17:23:13 +02:00
|
|
|
"
|
2017-06-16 09:20:49 +02:00
|
|
|
%configure \
|
|
|
|
--disable-static \
|
|
|
|
--disable-static-shell \
|
2018-06-11 16:45:59 +02:00
|
|
|
--enable-readline \
|
2018-07-04 11:26:58 +02:00
|
|
|
--enable-fts3 \
|
2018-06-11 16:45:59 +02:00
|
|
|
--enable-fts4 \
|
|
|
|
--enable-fts5 \
|
|
|
|
--enable-json1 \
|
|
|
|
--enable-update-limit \
|
|
|
|
--enable-rtree
|
2020-06-20 13:26:28 +02:00
|
|
|
%make_build sqlite3.c
|
|
|
|
%make_build
|
2008-01-14 10:18:35 +01:00
|
|
|
|
2018-06-29 15:06:55 +02:00
|
|
|
%check
|
2020-06-20 13:26:28 +02:00
|
|
|
%make_build test
|
2018-06-29 15:06:55 +02:00
|
|
|
|
2008-01-14 10:18:35 +01:00
|
|
|
%install
|
2017-06-16 09:20:49 +02:00
|
|
|
%make_install
|
2018-06-11 16:45:59 +02:00
|
|
|
mkdir -p %{buildroot}/%{_mandir}/man1/
|
2018-06-29 15:06:55 +02:00
|
|
|
install -Dpm 0644 sqlite3.1 \
|
|
|
|
%{buildroot}/%{_mandir}/man1/sqlite3.1
|
|
|
|
# tcl bindings are provided by tcl itself
|
|
|
|
rm -rf %{buildroot}%{_libdir}/tcl/tcl8.?/sqlite3*
|
2016-01-07 15:08:29 +01:00
|
|
|
find %{buildroot} -type f -name "*.la" -delete -print
|
2008-01-14 10:18:35 +01:00
|
|
|
|
|
|
|
%post -n libsqlite3-0 -p /sbin/ldconfig
|
|
|
|
%postun -n libsqlite3-0 -p /sbin/ldconfig
|
2016-08-02 14:04:29 +02:00
|
|
|
|
2008-01-14 10:18:35 +01:00
|
|
|
%files
|
2016-01-07 15:08:29 +01:00
|
|
|
%{_bindir}/sqlite3
|
2018-06-06 20:59:40 +02:00
|
|
|
%{_mandir}/man1/sqlite3.1%{?ext_man}
|
2008-01-14 10:18:35 +01:00
|
|
|
|
|
|
|
%files -n libsqlite3-0
|
2017-06-16 09:20:49 +02:00
|
|
|
%{_libdir}/libsqlite3.so.*
|
2008-01-14 10:18:35 +01:00
|
|
|
|
|
|
|
%files devel
|
2017-06-16 09:20:49 +02:00
|
|
|
%{_includedir}/sqlite3.h
|
|
|
|
%{_includedir}/sqlite3ext.h
|
|
|
|
%{_libdir}/libsqlite3.so
|
2016-01-07 15:08:29 +01:00
|
|
|
%{_libdir}/pkgconfig/sqlite3.pc
|
2008-01-14 10:18:35 +01:00
|
|
|
|
2014-02-13 11:47:47 +01:00
|
|
|
%files doc
|
2016-01-07 15:08:29 +01:00
|
|
|
%doc sqlite-doc-%{tarversion}/*
|
2014-02-13 11:47:47 +01:00
|
|
|
|
2008-01-14 10:18:35 +01:00
|
|
|
%changelog
|