Files
perl-CPAN/perl-CPAN.spec
2025-08-12 18:12:44 +02:00

136 lines
4.8 KiB
RPMSpec

#
# spec file for package perl-CPAN
#
# Copyright (c) 2024 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 CPAN
Name: perl-CPAN
Version: 2.38
Release: 0
License: Artistic-1.0 OR GPL-1.0-or-later
Summary: Query, download and build perl modules from CPAN sites
URL: https://metacpan.org/release/%{cpan_name}
Source0: https://cpan.metacpan.org/authors/id/A/AN/ANDK/%{cpan_name}-%{version}.tar.gz
Source1: cpanspec.yml
Source100: README.md
BuildArch: noarch
BuildRequires: perl
BuildRequires: perl-macros
BuildRequires: perl(Archive::Tar)
BuildRequires: perl(Archive::Zip)
BuildRequires: perl(CPAN::Checksums)
BuildRequires: perl(CPAN::Meta)
BuildRequires: perl(CPAN::Meta::Requirements) >= 2.121
BuildRequires: perl(CPAN::Meta::YAML)
BuildRequires: perl(CPAN::Perl::Releases)
BuildRequires: perl(Compress::Bzip2)
BuildRequires: perl(Compress::Zlib)
BuildRequires: perl(Digest::SHA)
BuildRequires: perl(Expect)
BuildRequires: perl(ExtUtils::CBuilder)
BuildRequires: perl(File::HomeDir)
BuildRequires: perl(File::Which)
BuildRequires: perl(HTTP::Tiny)
BuildRequires: perl(IO::Compress::Base)
BuildRequires: perl(IO::Zlib)
BuildRequires: perl(JSON::PP)
BuildRequires: perl(LWP::UserAgent)
BuildRequires: perl(Module::Build)
BuildRequires: perl(Module::Signature)
BuildRequires: perl(Parse::CPAN::Meta)
BuildRequires: perl(Term::ReadKey)
BuildRequires: perl(Test::Harness) >= 2.62
BuildRequires: perl(Text::Glob)
BuildRequires: perl(YAML)
BuildRequires: perl(YAML::Syck)
BuildRequires: perl(YAML::XS)
Requires: perl(Archive::Tar)
Requires: perl(Archive::Zip)
Requires: perl(CPAN::Checksums)
Requires: perl(CPAN::Meta)
Requires: perl(CPAN::Meta::Requirements) >= 2.121
Requires: perl(CPAN::Meta::YAML)
Requires: perl(CPAN::Perl::Releases)
Requires: perl(Compress::Bzip2)
Requires: perl(Compress::Zlib)
Requires: perl(Digest::SHA)
Requires: perl(Expect)
Requires: perl(ExtUtils::CBuilder)
Requires: perl(File::HomeDir)
Requires: perl(File::Which)
Requires: perl(HTTP::Tiny)
Requires: perl(IO::Compress::Base)
Requires: perl(IO::Zlib)
Requires: perl(JSON::PP)
Requires: perl(LWP::UserAgent)
Requires: perl(Module::Build)
Requires: perl(Module::Signature)
Requires: perl(Parse::CPAN::Meta)
Requires: perl(Term::ReadKey)
Requires: perl(Test::Harness) >= 2.62
Requires: perl(Text::Glob)
Requires: perl(YAML)
Requires: perl(YAML::Syck)
Requires: perl(YAML::XS)
%{perl_requires}
%description
The CPAN module automates or at least simplifies the make and install of
perl modules and extensions. It includes some primitive searching
capabilities and knows how to use LWP, HTTP::Tiny, Net::FTP and certain
external download clients to fetch distributions from the net.
These are fetched from one or more mirrored CPAN (Comprehensive Perl
Archive Network) sites and unpacked in a dedicated directory.
The CPAN module also supports named and versioned _bundles_ of modules.
Bundles simplify handling of sets of related modules. See Bundles below.
The package contains a session manager and a cache manager. The session
manager keeps track of what has been fetched, built, and installed in the
current session. The cache manager keeps track of the disk space occupied
by the make processes and deletes excess space using a simple FIFO
mechanism.
All methods provided are accessible in a programmer style and in an
interactive shell style.
%prep
%autosetup -n %{cpan_name}-%{version}
%build
perl Makefile.PL INSTALLDIRS=vendor
%make_build
%check
make test
%install
%perl_make_install
%perl_process_packlist
# MANUAL BEGIN
## do not conflict with perl itself!
mv $RPM_BUILD_ROOT/usr/bin/cpan $RPM_BUILD_ROOT/usr/bin/CPAN
mv $RPM_BUILD_ROOT/usr/share/man/man1/cpan.1 $RPM_BUILD_ROOT/usr/share/man/man1/CPAN.1
#mv $RPM_BUILD_ROOT/usr/share/man/man3 $RPM_BUILD_ROOT/usr/share/man/man3pm
# MANUAL END
%perl_gen_filelist
%files -f %{name}.files
%doc Changes PAUSE2003.pub PAUSE2005.pub PAUSE2007.pub PAUSE2009.pub PAUSE2011.pub PAUSE2015.pub PAUSE2019.pub PAUSE2021.pub PAUSE2022.pub README SlayMakefile Todo
%changelog