Репозиторий Sisyphus
Последнее обновление: 1 октября 2023 | Пакетов: 18631 | Посещений: 37041790
en ru br
Репозитории ALT
S:3.42.0-alt1
5.1: 3.7.2-alt1.M50P.1
4.1: 3.5.9-alt2.M41.1
4.0: 3.4.2-alt1
3.0: 3.2.2-alt1
www.altlinux.org/Changes

Группа :: Разработка/Базы Данных
Пакет: sqlite3

 Главная   Изменения   Спек   Патчи   Sources   Загрузить   Gear   Bugs and FR  Repocop 

%def_disable static

Name: sqlite3
Version: 3.42.0
Release: alt1
Summary: An Embeddable SQL Database Engine
License: ALT-Public-Domain
Group: Development/Databases
URL: http://www.sqlite.org/

Source0: sqlite-%version.tar
Source1: sqlite3.watch

Patch1: 0001-FEDORA-no-malloc-usable-size.patch
Patch2: 0002-FEDORA-percentile-test.patch
Patch3: 0003-FEDORA-ALT-datetest-2.2c.patch
Patch4: 0004-ALT-TEA-Policy.patch
Patch5: 0005-ALT-run-func7-pg-181-test-only-on-x86_64.patch

BuildRequires(Pre): tcl-devel
BuildRequires: libreadline-devel
# need for test
BuildRequires: zlib-devel unzip

%define _unpackaged_files_terminate_build 1

%description
SQLite is a C library that implements an SQL database engine.
Programs that link with the SQLite library can have SQL database
access without running a separate RDBMS process.

%package -n lib%name
Summary: An Embeddable SQL Database Engine (shared library)
Group: System/Libraries
Provides: sqlite(SECURE_DELETE) sqlite(COLUMN_METADATA) sqlite(FTS3) sqlite(UNLOCK_NOTIFY)
Provides: %name-fts3 = %version-%release
Obsoletes: %name-fts3 < %version-%release

%description -n lib%name
SQLite is a C library that implements an SQL database engine.
Programs that link with the SQLite library can have SQL database
access without running a separate RDBMS process.

%package -n lib%name-devel
Summary: An Embeddable SQL Database Engine (header files)
Group: Development/Databases
Requires: lib%name = %version-%release

%description -n lib%name-devel
SQLite is a C library that implements an SQL database engine.
Programs that link with the SQLite library can have SQL database
access without running a separate RDBMS process.

%package -n lib%name-devel-static
Summary: An Embeddable SQL Database Engine (static library)
Group: Development/Databases
Requires: lib%name-devel = %version-%release

%description -n lib%name-devel-static
SQLite is a C library that implements an SQL database engine.
Programs that link with the SQLite library can have SQL database
access without running a separate RDBMS process.

%package -n tcl-sqlite3
Summary: An Embeddable SQL Database Engine (TCL bindings)
Group: Development/Tcl
Provides: sqlite3-tcl = %version
Obsoletes: sqlite3-tcl < %version

%description -n tcl-sqlite3
SQLite is a C library that implements an SQL database engine.
Programs that link with the SQLite library can have SQL database
access without running a separate RDBMS process.

%package doc
Summary: An Embeddable SQL Database Engine (documentation)
Group: Development/Documentation
Conflicts: %name < 3.3.8-alt1
BuildArch: noarch

%description doc
SQLite is a C library that implements an SQL database engine.
Programs that link with the SQLite library can have SQL database
access without running a separate RDBMS process.

%package -n lemon
Summary: The Lemon Parser Generator
Group: Development/Other

%description -n lemon
Lemon is an LALR(1) parser generator for C or C++. It does the same
job as bison and yacc. But lemon is not another bison or yacc
clone. It uses a different grammar syntax which is designed to reduce
the number of coding errors. Lemon also uses a more sophisticated
parsing engine that is faster than yacc and bison and which is both
reentrant and thread-safe. Furthermore, Lemon implements features
that can be used to eliminate resource leaks, making is suitable for
use in long-running programs such as graphical user interfaces or
embedded controllers.

%prep
%setup -q -n sqlite-%version
%autopatch -p2

%build
export TCLLIBDIR=%_tcllibdir
export TCLDATADIR=%_tcldatadir/%name
export CFLAGS="%optflags \
-DSQLITE_CORE \
-DSQLITE_ENABLE_API_ARMOR \
-DSQLITE_ENABLE_COLUMN_METADATA \
-DSQLITE_ENABLE_DBSTAT_VTAB \
-DSQLITE_ENABLE_DESERIALIZE \
-DSQLITE_ENABLE_FTS3 \
-DSQLITE_ENABLE_FTS3_PARENTHESIS \
-DSQLITE_ENABLE_FTS4 \
-DSQLITE_ENABLE_FTS5 \
-DSQLITE_ENABLE_RTREE \
-DSQLITE_ENABLE_UNLOCK_NOTIFY \
-DSQLITE_SECURE_DELETE \
-fno-strict-aliasing "
%ifarch %e2k
# FIXME: lcc-1.23 lacks some gcc5 builtins
cc --version | grep -q '^lcc:1.21' || export CFLAGS+="-D__INTEL_COMPILER=1"
%endif
autoreconf -i
%configure \
%{subst_enable static} \
--disable-amalgamation \
--enable-fst3 \
--enable-fst4 \
--enable-fts5 \
--enable-load-extension \
--enable-readline \
--enable-rtree \
--enable-threadsafe \
#

make all sqlite3_analyzer sqldiff

%check
sed -Ei 's at -DSQLITE_ENABLE_FTS[34](\s|$) at  at g' Makefile
export LD_LIBRARY_PATH=%buildroot%_libdir
%make test

%install
%make_install install tcl_install DESTDIR=%buildroot

install -pD -m644 %name.1 %buildroot%_man1dir/%name.1

install -pD -m755 sqlite3_analyzer %buildroot%_bindir/sqlite3_analyzer
install -pD -m755 sqldiff %buildroot%_bindir/sqldiff

install -pD -m755 lemon %buildroot%_bindir/lemon
install -pD -m644 lempar.c %buildroot%_datadir/lemon/lempar.c

# for perl-DBD-SQLite

install -p -m644 ext/fts3/fts3.h ext/fts3/fts3_*.h %buildroot%_includedir/

%define pkgdocdir %_docdir/%name
mkdir -p %buildroot%pkgdocdir
cp -a doc %buildroot%pkgdocdir/html
install -pD -m644 doc/lemon.html %buildroot%_docdir/lemon/lemon.html

%files
%_bindir/%name
%_bindir/sqlite3_analyzer
%_bindir/sqldiff
%_man1dir/%name.*

%files -n lib%name
%_libdir/lib%name.so.*

%files -n lib%name-devel
%_includedir/sqlite3.h
%_includedir/sqlite3ext.h
%_includedir/fts3.h
%_includedir/fts3_*.h
%_libdir/lib%name.so
%_pkgconfigdir/%name.pc

%if_enabled static
%files -n lib%name-devel-static
%_libdir/lib%name.a
%endif # static

%files -n tcl-sqlite3
%_tcllibdir/libtcl%name.so*
%_tcllibdir/sqlite3

%files doc
%pkgdocdir

%files -n lemon
%dir %_docdir/lemon
%_docdir/lemon/lemon.html
%_bindir/lemon
%_datadir/lemon

%changelog

Полный changelog можно просмотреть здесь

 
дизайн и разработка: Vladimir Lettiev aka crux © 2004-2005, Andrew Avramenko aka liks © 2007-2008
текущий майнтейнер: Michael Shigorin