Sync from SUSE:SLFO:Main perl-DBD-SQLite revision 807fdb3313d58b0601ed4548eca0fb5a

This commit is contained in:
Adrian Schröter 2024-05-03 18:00:28 +02:00
commit ad524164e2
6 changed files with 1226 additions and 0 deletions

23
.gitattributes vendored Normal file
View File

@ -0,0 +1,23 @@
## Default LFS
*.7z filter=lfs diff=lfs merge=lfs -text
*.bsp filter=lfs diff=lfs merge=lfs -text
*.bz2 filter=lfs diff=lfs merge=lfs -text
*.gem filter=lfs diff=lfs merge=lfs -text
*.gz filter=lfs diff=lfs merge=lfs -text
*.jar filter=lfs diff=lfs merge=lfs -text
*.lz filter=lfs diff=lfs merge=lfs -text
*.lzma filter=lfs diff=lfs merge=lfs -text
*.obscpio filter=lfs diff=lfs merge=lfs -text
*.oxt filter=lfs diff=lfs merge=lfs -text
*.pdf filter=lfs diff=lfs merge=lfs -text
*.png filter=lfs diff=lfs merge=lfs -text
*.rpm filter=lfs diff=lfs merge=lfs -text
*.tbz filter=lfs diff=lfs merge=lfs -text
*.tbz2 filter=lfs diff=lfs merge=lfs -text
*.tgz filter=lfs diff=lfs merge=lfs -text
*.ttf filter=lfs diff=lfs merge=lfs -text
*.txz filter=lfs diff=lfs merge=lfs -text
*.whl filter=lfs diff=lfs merge=lfs -text
*.xz filter=lfs diff=lfs merge=lfs -text
*.zip filter=lfs diff=lfs merge=lfs -text
*.zst filter=lfs diff=lfs merge=lfs -text

BIN
DBD-SQLite-1.74.tar.gz (Stored with Git LFS) Normal file

Binary file not shown.

47
cpanspec.yml Normal file
View File

@ -0,0 +1,47 @@
---
#description_paragraphs: 3
#description: |-
# override description from CPAN
#summary: override summary from CPAN
#no_testing: broken upstream
#sources:
# - source1
# - source2
patches:
perl-DBD-SQLite-use-external-sqlite3.patch: -p1 PATCH-FIX-OPENSUSE use system sqlite
preamble: |-
%if 0%{?sle_version} >= 140000 && 0%{?sle_version} <= 150400
%else
BuildRequires: sqlite3-devel >= 3.35
Recommends: sqlite3-devel
%endif
post_prep: |-
%if 0%{?sle_version} >= 140000 && 0%{?sle_version} <= 150400
patch -p1 --reverse <%{PATCH0}
%endif
#post_build: |-
# rm unused.files
post_install: |-
%if 0%{?sle_version} >= 140000 && 0%{?sle_version} <= 150400
%else
ln -fs %{_includedir}/sqlite3ext.h %{buildroot}%{perl_vendorarch}/auto/share/dist/%{cpan_name}/
ln -fs %{_includedir}/sqlite3.h %{buildroot}%{perl_vendorarch}/auto/share/dist/%{cpan_name}/
rm %{buildroot}%{perl_vendorarch}/auto/share/dist/%{cpan_name}/sqlite3.c
echo >%{buildroot}%{perl_vendorarch}/auto/share/dist/%{cpan_name}/sqlite3.c
chmod 444 %{buildroot}%{perl_vendorarch}/auto/share/dist/%{cpan_name}/sqlite3.c
%endif
#license: SUSE-NonFree
#skip_noarch: 1
#custom_build: |-
#./Build build flags=%{?_smp_mflags} --myflag
#custom_test: |-
#startserver && make test
#ignore_requires: Bizarre::Module
#skip_doc: regexp_to_skip_for_doc.*
#add_doc: files to add to docs
misc: |-
# the links are ignored by perl_gen_filelist, so we need to add them manually again
%if 0%{?sle_version} >= 140000 && 0%{?sle_version} <= 150400
%else
%{perl_vendorarch}/auto/share/dist/%{cpan_name}/*.h
%endif

View File

@ -0,0 +1,13 @@
Index: DBD-SQLite-1.70/Makefile.PL
===================================================================
--- DBD-SQLite-1.70.orig/Makefile.PL
+++ DBD-SQLite-1.70/Makefile.PL
@@ -129,7 +129,7 @@ SCOPE: {
# a system sqlite is also sophisticated enough to have a patching system
# that can change the if ( 0 ) to if ( 1 )
my ($sqlite_local, $sqlite_base, $sqlite_lib, $sqlite_inc);
-if ( 0 ) {
+if ( 1 ) {
require File::Spec;
if ( $sqlite_base = (grep(/SQLITE_LOCATION=.*/, @ARGV))[0] ) {
$sqlite_base =~ /=(.*)/;

1009
perl-DBD-SQLite.changes Normal file

File diff suppressed because it is too large Load Diff

131
perl-DBD-SQLite.spec Normal file
View File

@ -0,0 +1,131 @@
#
# spec file for package perl-DBD-SQLite
#
# Copyright (c) 2023 SUSE LLC
#
# 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.
# Please submit bugfixes or comments via https://bugs.opensuse.org/
#
%define cpan_name DBD-SQLite
Name: perl-DBD-SQLite
Version: 1.740.0
Release: 0
%define cpan_version 1.74
License: Artistic-1.0 OR GPL-1.0-or-later
Summary: Self Contained SQLite RDBMS in a DBI Driver
URL: https://metacpan.org/release/%{cpan_name}
Source0: https://cpan.metacpan.org/authors/id/I/IS/ISHIGAKI/%{cpan_name}-%{cpan_version}.tar.gz
Source1: cpanspec.yml
# PATCH-FIX-OPENSUSE use system sqlite
Patch0: perl-DBD-SQLite-use-external-sqlite3.patch
BuildRequires: perl
BuildRequires: perl-macros
BuildRequires: perl(DBI) >= 1.57
BuildRequires: perl(ExtUtils::MakeMaker) >= 6.48
BuildRequires: perl(Test::More) >= 0.88
Requires: perl(DBI) >= 1.57
Provides: perl(DBD::SQLite) = 1.740.0
Provides: perl(DBD::SQLite::Constants)
Provides: perl(DBD::SQLite::GetInfo)
Provides: perl(DBD::SQLite::VirtualTable) = 1.740.0
Provides: perl(DBD::SQLite::VirtualTable::Cursor)
Provides: perl(DBD::SQLite::VirtualTable::FileContent)
Provides: perl(DBD::SQLite::VirtualTable::FileContent::Cursor)
Provides: perl(DBD::SQLite::VirtualTable::PerlData)
Provides: perl(DBD::SQLite::VirtualTable::PerlData::Cursor)
%define __perllib_provides /bin/true
%{perl_requires}
# MANUAL BEGIN
%if 0%{?sle_version} >= 140000 && 0%{?sle_version} <= 150400
%else
BuildRequires: sqlite3-devel >= 3.35
Recommends: sqlite3-devel
%endif
# MANUAL END
%description
SQLite is a public domain file-based relational database engine that you
can find at https://www.sqlite.org/.
*DBD::SQLite* is a Perl DBI driver for SQLite, that includes the entire
thing in the distribution. So in order to get a fast transaction capable
RDBMS working for your perl project you simply have to install this module,
and *nothing* else.
SQLite supports the following features:
* Implements a large subset of SQL92
See https://www.sqlite.org/lang.html for details.
* A complete DB in a single disk file
Everything for your database is stored in a single disk file, making it
easier to move things around than with DBD::CSV.
* Atomic commit and rollback
Yes, *DBD::SQLite* is small and light, but it supports full transactions!
* Extensible
User-defined aggregate or regular functions can be registered with the SQL
parser.
There's lots more to it, so please refer to the docs on the SQLite web
page, listed above, for SQL details. Also refer to DBI for details on how
to use DBI itself. The API works like every DBI module does. However,
currently many statement attributes are not implemented or are limited by
the typeless nature of the SQLite database.
%prep
%autosetup -n %{cpan_name}-%{cpan_version} -p1
# MANUAL BEGIN
%if 0%{?sle_version} >= 140000 && 0%{?sle_version} <= 150400
patch -p1 --reverse <%{PATCH0}
%endif
# MANUAL END
%build
perl Makefile.PL INSTALLDIRS=vendor OPTIMIZE="%{optflags}"
%make_build
%check
make test
%install
%perl_make_install
%perl_process_packlist
# MANUAL BEGIN
%if 0%{?sle_version} >= 140000 && 0%{?sle_version} <= 150400
%else
ln -fs %{_includedir}/sqlite3ext.h %{buildroot}%{perl_vendorarch}/auto/share/dist/%{cpan_name}/
ln -fs %{_includedir}/sqlite3.h %{buildroot}%{perl_vendorarch}/auto/share/dist/%{cpan_name}/
rm %{buildroot}%{perl_vendorarch}/auto/share/dist/%{cpan_name}/sqlite3.c
echo >%{buildroot}%{perl_vendorarch}/auto/share/dist/%{cpan_name}/sqlite3.c
chmod 444 %{buildroot}%{perl_vendorarch}/auto/share/dist/%{cpan_name}/sqlite3.c
%endif
# MANUAL END
%perl_gen_filelist
%files -f %{name}.files
%doc Changes constants.inc dbdimp_tokenizer.inc dbdimp_virtual_table.inc README
%license LICENSE
# the links are ignored by perl_gen_filelist, so we need to add them manually again
%if 0%{?sle_version} >= 140000 && 0%{?sle_version} <= 150400
%else
%{perl_vendorarch}/auto/share/dist/%{cpan_name}/*.h
%endif
%changelog