107 lines
3.8 KiB
RPMSpec
107 lines
3.8 KiB
RPMSpec
#
|
|
# spec file for package perl-DBIx-Class-EncodedColumn
|
|
#
|
|
# Copyright (c) 2025 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 DBIx-Class-EncodedColumn
|
|
Name: perl-DBIx-Class-EncodedColumn
|
|
Version: 0.110.0
|
|
Release: 0
|
|
# 0.11 -> normalize -> 0.110.0
|
|
%define cpan_version 0.11
|
|
License: Artistic-1.0 OR GPL-1.0-or-later
|
|
Summary: Automatically encode columns
|
|
URL: https://metacpan.org/release/%{cpan_name}
|
|
Source0: https://cpan.metacpan.org/authors/id/W/WR/WREIS/%{cpan_name}-%{cpan_version}.tar.gz
|
|
Source1: cpanspec.yml
|
|
Source100: README.md
|
|
BuildArch: noarch
|
|
BuildRequires: perl
|
|
BuildRequires: perl-macros
|
|
BuildRequires: perl(Crypt::URandom)
|
|
BuildRequires: perl(Crypt::URandom::Token)
|
|
BuildRequires: perl(DBD::SQLite)
|
|
BuildRequires: perl(DBIx::Class) >= 0.06002
|
|
BuildRequires: perl(Dir::Self)
|
|
BuildRequires: perl(Module::Build)
|
|
BuildRequires: perl(Module::Build::Tiny) >= 0.34.0
|
|
BuildRequires: perl(Sub::Name) >= 0.40.0
|
|
BuildRequires: perl(Test::Exception)
|
|
Requires: perl(Crypt::URandom)
|
|
Requires: perl(Crypt::URandom::Token)
|
|
Requires: perl(DBIx::Class) >= 0.06002
|
|
Requires: perl(Sub::Name) >= 0.40.0
|
|
Provides: perl(DBIx::Class::EncodedColumn) = %{version}
|
|
Provides: perl(DBIx::Class::EncodedColumn::Crypt) = %{version}
|
|
Provides: perl(DBIx::Class::EncodedColumn::Crypt::Eksblowfish::Bcrypt) = %{version}
|
|
Provides: perl(DBIx::Class::EncodedColumn::Crypt::OpenPGP) = %{version}
|
|
Provides: perl(DBIx::Class::EncodedColumn::Digest) = %{version}
|
|
%undefine __perllib_provides
|
|
Recommends: perl(Crypt::OpenPGP)
|
|
Recommends: perl(Digest::SHA)
|
|
Recommends: perl(Math::Pari)
|
|
%{perl_requires}
|
|
|
|
%description
|
|
This DBIx::Class component can be used to automatically encode a column's
|
|
contents whenever the value of that column is set.
|
|
|
|
This module is similar to the existing DBIx::Class::DigestColumns, but
|
|
there is some key differences:
|
|
|
|
* 'DigestColumns' performs the encode operation on 'insert' and 'update',
|
|
and 'EncodedColumn' performs the operation when the value is set, or on
|
|
'new'.
|
|
|
|
* 'DigestColumns' supports only algorithms of the Digest family.
|
|
'EncodedColumn' employs a set of thin wrappers around different cipher
|
|
modules
|
|
to provide support for any cipher you wish to use and wrappers are very
|
|
simple
|
|
to write (typically less than 30 lines).
|
|
|
|
* 'EncodedColumn' supports having more than one encoded column per table
|
|
and each column can use a different cipher.
|
|
|
|
* 'Encode' adds only one item to the namespace of the object utilizing
|
|
it ('_column_encoders').
|
|
|
|
There is, unfortunately, some features that 'EncodedColumn' doesn't
|
|
support. 'DigestColumns' supports changing certain options at runtime, as
|
|
well as the option to not automatically encode values on set. The author of
|
|
this module found these options to be non-essential and omitted them by
|
|
design.
|
|
|
|
%prep
|
|
%autosetup -n %{cpan_name}-%{cpan_version} -p1
|
|
|
|
%build
|
|
perl Build.PL --installdirs=vendor
|
|
./Build build --flags=%{?_smp_mflags}
|
|
|
|
%check
|
|
./Build test
|
|
|
|
%install
|
|
./Build install --destdir=%{buildroot} --create_packlist=0
|
|
%perl_gen_filelist
|
|
|
|
%files -f %{name}.files
|
|
%doc Changes README
|
|
%license LICENSE
|
|
|
|
%changelog
|