diff options
Diffstat (limited to 'gnu/packages/perl.scm')
-rw-r--r-- | gnu/packages/perl.scm | 97 |
1 files changed, 96 insertions, 1 deletions
diff --git a/gnu/packages/perl.scm b/gnu/packages/perl.scm index d2c9d0d24e..d6ca055147 100644 --- a/gnu/packages/perl.scm +++ b/gnu/packages/perl.scm @@ -13,7 +13,7 @@ ;;; Copyright © 2016 Ben Woodcroft <donttrustben@gmail.com> ;;; Copyright © 2016, 2020 Jan (janneke) Nieuwenhuizen <janneke@gnu.org> ;;; Copyright © 2017 Raoul J.P. Bonnal <ilpuccio.febo@gmail.com> -;;; Copyright © 2017, 2018, 2020, 2021 Marius Bakke <marius@gnu.org> +;;; Copyright © 2017, 2018, 2020-2022 Marius Bakke <marius@gnu.org> ;;; Copyright © 2017 Adriano Peluso <catonano@gmail.com> ;;; Copyright © 2017, 2018–2021 Tobias Geerinckx-Rice <me@tobias.gr> ;;; Copyright © 2017 Leo Famulari <leo@famulari.name> @@ -65,6 +65,7 @@ #:use-module (gnu packages databases) #:use-module (gnu packages fontutils) #:use-module (gnu packages freedesktop) + #:use-module (gnu packages gcc) #:use-module (gnu packages gd) #:use-module (gnu packages gl) #:use-module (gnu packages gtk) @@ -258,6 +259,78 @@ more.") (home-page "https://www.perl.org/") (license license:gpl1+))) ; or "Artistic" +(define-public perl-5.14 + (package + (name "perl") + (version "5.14.4") + (source (origin + (method url-fetch) + (uri (string-append "mirror://cpan/src/5.0/perl-" + version ".tar.gz")) + (sha256 + (base32 + "1js47zzna3v38fjnirf2vq6y0rjp8m86ysj5vagzgkig956d8gw0")) + (patches (search-patches + "perl-5.14-no-sys-dirs.patch" + "perl-5.14-autosplit-default-time.patch" + "perl-5.14-module-pluggable-search.patch")))) + (properties `((release-date . "2013-03-10"))) + (build-system gnu-build-system) + (arguments + '(#:tests? #f + #:phases + (modify-phases %standard-phases + (replace 'configure + (lambda* (#:key inputs outputs #:allow-other-keys) + (let ((out (assoc-ref outputs "out")) + (libc (assoc-ref inputs "libc"))) + ;; Use the right path for `pwd'. + (substitute* "dist/Cwd/Cwd.pm" + (("/bin/pwd") + (which "pwd"))) + + (invoke "./Configure" + (string-append "-Dprefix=" out) + (string-append "-Dman1dir=" out "/share/man/man1") + (string-append "-Dman3dir=" out "/share/man/man3") + "-de" "-Dcc=gcc" + "-Uinstallusrbinperl" + "-Dinstallstyle=lib/perl5" + "-Duseshrplib" + (string-append "-Dlocincpth=" libc "/include") + (string-append "-Dloclibpth=" libc "/lib") + + ;; Force the library search path to contain only libc + ;; because it is recorded in Config.pm and + ;; Config_heavy.pl; we don't want to keep a reference + ;; to everything that's in $LIBRARY_PATH at build + ;; time (Binutils, bzip2, file, etc.) + (string-append "-Dlibpth=" libc "/lib") + (string-append "-Dplibpth=" libc "/lib"))))) + + (add-before 'strip 'make-shared-objects-writable + (lambda* (#:key outputs #:allow-other-keys) + ;; The 'lib/perl5' directory contains ~50 MiB of .so. Make them + ;; writable so that 'strip' actually strips them. + (let* ((out (assoc-ref outputs "out")) + (lib (string-append out "/lib"))) + (for-each (lambda (dso) + (chmod dso #o755)) + (find-files lib "\\.so$")))))))) + (native-inputs + (list gcc-7)) + (native-search-paths (list (search-path-specification + (variable "PERL5LIB") + (files '("lib/perl5/site_perl"))))) + (home-page "https://www.perl.org/") + (synopsis "Implementation of the Perl programming language") + (description + "Perl is a general-purpose programming language originally developed for +text manipulation and now used for a wide range of tasks including system +administration, web development, network programming, GUI development, and +more.") + (license license:gpl1+))) + (define-public perl-algorithm-c3 (package (name "perl-algorithm-c3") @@ -2958,6 +3031,28 @@ operations, such as comparing two times, determining a date a given amount of time from another, or parsing international times.") (license (package-license perl)))) +(define-public perl-date-range + (package + (name "perl-date-range") + (version "1.41") + (source + (origin + (method url-fetch) + (uri (string-append "mirror://cpan/authors/id/T/TM/TMTM/" + "Date-Range-" version ".tar.gz")) + (sha256 + (base32 "1fa8v75pbplmkb3ff6k0hd1m80p9xgksf54xhw1ha70h5d4rg65z")))) + (build-system perl-build-system) + (propagated-inputs + (list perl-date-simple)) + (home-page "https://metacpan.org/dist/Date-Range") + (synopsis "Work with a range of dates") + (description + "@code{Date::Range} is a library to work with date ranges. It can +be used to determine whether a given date is in a particular range, or what +the overlap between two ranges are.") + (license license:gpl2+))) + (define-public perl-date-simple (package (name "perl-date-simple") |