Accepting request 901345 from home:pmonrealgonzalez:branches:devel:languages:perl

- Fix autoupdate build:
  * Add required build and test dependencies
  * Update spec file and add cpanspec.yml

OBS-URL: https://build.opensuse.org/request/show/901345
OBS-URL: https://build.opensuse.org/package/show/devel:languages:perl/perl-Net-SSLeay?expand=0&rev=50
This commit is contained in:
Pedro Monreal Gonzalez 2021-06-23 09:20:52 +00:00 committed by Git OBS Bridge
parent 90e235cd32
commit ba4a5df05f
3 changed files with 61 additions and 29 deletions

40
cpanspec.yml Normal file
View File

@ -0,0 +1,40 @@
----
#description_paragraphs: 3
#description: |-
# override description from CPAN
#summary: override summary from CPAN
#no_testing: broken upstream
#sources:
# - source1
# - source2
#patches:
# foo.patch: -p1
# bar.patch:
# baz.patch: PATCH-FIX-OPENSUSE
#preamble: |-
BuildRequires: libopenssl-devel
BuildRequires: zlib-devel
BuildRequires: perl(Test::Exception)
BuildRequires: perl(Test::NoWarnings)
BuildRequires: perl(Test::Pod) >= 1.41
BuildRequires: perl(Test::Warn)
#post_prep: |-
# hunspell=`pkg-config --libs hunspell | sed -e 's,-l,,; s, *,,g'`
# sed -i -e "s,hunspell-X,$hunspell," t/00-prereq.t Makefile.PL
#post_build: |-
# rm unused.files
#post_install: |-
# sed on %{name}.files
#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: |-
#anything else to be added to spec file
#follows directly after %files section, so it can contain new blocks or also
#changes to %files section

View File

@ -1,3 +1,10 @@
-------------------------------------------------------------------
Tue Jun 22 12:31:18 UTC 2021 - Pedro Monreal <pmonreal@suse.com>
- Fix autoupdate build:
* Add required build and test dependencies
* Update spec file and add cpanspec.yml
------------------------------------------------------------------- -------------------------------------------------------------------
Wed Jan 27 08:02:17 UTC 2021 - Dirk Müller <dmueller@suse.com> Wed Jan 27 08:02:17 UTC 2021 - Dirk Müller <dmueller@suse.com>

View File

@ -22,50 +22,35 @@ Version: 1.90
Release: 0 Release: 0
Summary: Perl extension for using OpenSSL Summary: Perl extension for using OpenSSL
License: Artistic-2.0 License: Artistic-2.0
Group: Development/Libraries/Perl
URL: https://metacpan.org/release/%{cpan_name} URL: https://metacpan.org/release/%{cpan_name}
Source0: https://cpan.metacpan.org/authors/id/C/CH/CHRISN/%{cpan_name}-%{version}.tar.gz Source0: https://cpan.metacpan.org/authors/id/C/CH/CHRISN/%{cpan_name}-%{version}.tar.gz
BuildRequires: libopenssl-devel Source1: cpanspec.yml
BuildRequires: openssl
BuildRequires: perl BuildRequires: perl
BuildRequires: perl-macros BuildRequires: perl-macros
BuildRequires: zlib-devel
%{perl_requires} %{perl_requires}
# MANUAL BEGIN
BuildRequires: libopenssl-devel
BuildRequires: zlib-devel
BuildRequires: perl(Test::Exception) BuildRequires: perl(Test::Exception)
BuildRequires: perl(Test::NoWarnings) BuildRequires: perl(Test::NoWarnings)
BuildRequires: perl(Test::Pod) >= 1.00 BuildRequires: perl(Test::Pod) >= 1.41
BuildRequires: perl(Test::Pod::Coverage)
BuildRequires: perl(Test::Warn) BuildRequires: perl(Test::Warn)
# MANUAL END
%description %description
Net::SSLeay module contains perl bindings to openssl (http://www.openssl.org) library. This module provides Perl bindings for libssl (an SSL/TLS API) and
Net::SSLeay module basically comprise of: libcrypto (a cryptography API).
High level functions for accessing web servers (by using HTTP/HTTPS)
Low level API (mostly mapped 1:1 to openssl's C functions)
Convenience functions (related to low level API but with more perl friendly interface)
%prep %prep
%setup -q -n %{cpan_name}-%{version} %autosetup -n %{cpan_name}-%{version}
find . -type f ! -path "*/t/*" ! -name "*.pl" ! -path "*/bin/*" ! -path "*/script/*" ! -name "configure" -print0 | xargs -0 chmod 644
# replace rest of /usr/local/bin/perl with /usr/bin/perl
for f in $(find . -type f -exec grep -l "%{_prefix}/local/bin/perl" {} \; ); do
sed -i -e "s@%{_prefix}/local/bin/perl@perl@g" $f
done
# delete .orig files created by patches
find . -type f -name "*.orig" -delete
# fix perm
pushd examples
chmod 0644 *.pl
popd
%build %build
perl Makefile.PL INSTALLDIRS=vendor OPTIMIZE="%{optflags} -Wall" < /dev/null perl Makefile.PL INSTALLDIRS=vendor OPTIMIZE="%{optflags}"
make %{?_smp_mflags} %make_build
%check %check
%if ! 0%{?qemu_user_space_build} make test
make %{?_smp_mflags} test
%endif
%install %install
%perl_make_install %perl_make_install
@ -74,6 +59,6 @@ make %{?_smp_mflags} test
%files -f %{name}.files %files -f %{name}.files
%license LICENSE %license LICENSE
%doc Changes Credits QuickRef README examples %doc Changes Credits QuickRef README examples CONTRIBUTING.md
%changelog %changelog