# # spec file for package perl-Mozilla-CA # # Copyright (c) 2021 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 Mozilla-CA Name: perl-Mozilla-CA Version: 20211001 Release: 0 #Upstream: SUSE-Public-Domain Summary: Mozilla's CA cert bundle in PEM format License: MPL-1.1 OR GPL-2.0-or-later OR LGPL-2.1-or-later URL: https://metacpan.org/release/%{cpan_name} Source0: https://cpan.metacpan.org/authors/id/A/AB/ABH/%{cpan_name}-%{version}.tar.gz Source1: cpanspec.yml BuildArch: noarch BuildRequires: perl BuildRequires: perl-macros %{perl_requires} %description Mozilla::CA provides a copy of Mozilla's bundle of Certificate Authority certificates in a form that can be consumed by modules and libraries based on OpenSSL. The module provide a single function: * SSL_ca_file() Returns the absolute path to the Mozilla's CA cert bundle PEM file. %prep %autosetup -n %{cpan_name}-%{version} find . -type f ! -path "*/t/*" ! -name "*.pl" ! -path "*/bin/*" ! -path "*/script/*" ! -name "configure" -print0 | xargs -0 chmod 644 %build perl Makefile.PL INSTALLDIRS=vendor %make_build %check make test %install %perl_make_install %perl_process_packlist # MANUAL BEGIN mkdir -p %{buildroot}/%{_bindir} sed -e "s|/usr/bin/env perl|%{_bindir}/perl|g" %{buildroot}/%{perl_vendorlib}/Mozilla/mk-ca-bundle.pl > %{buildroot}/%{_bindir}/mk-ca-bundle.pl chmod +x %{buildroot}/%{_bindir}/mk-ca-bundle.pl rm %{buildroot}/%{perl_vendorlib}/Mozilla/mk-ca-bundle.pl sed -i "s|./mk-ca-bundle.pl|%{_bindir}/mk-ca-bundle.pl|g; \ s|lib/Mozilla/CA.pm|%{perl_vendorlib}/Mozilla/CA.pm|g; \ s|lib/Mozilla/CA/cacert.pem|%{perl_vendorlib}/Mozilla/CA/cacert.pem|g" update-cacert-file # MANUAL END %perl_gen_filelist %files -f %{name}.files %doc Changes README update-cacert-file %changelog