summary refs log tree commit diff
diff options
context:
space:
mode:
-rw-r--r--gnu/packages/perl.scm13
1 files changed, 13 insertions, 0 deletions
diff --git a/gnu/packages/perl.scm b/gnu/packages/perl.scm
index 86d07c3ccc..cde75bc06e 100644
--- a/gnu/packages/perl.scm
+++ b/gnu/packages/perl.scm
@@ -2541,9 +2541,22 @@ the DateTime.pm class.")
         (base32
          "0kz5kz47awf2bhb85xx5rbajkr093ipm2d2vkhqs8lqq0f305r3a"))))
     (build-system perl-build-system)
+    (arguments
+     '(#:phases
+       (modify-phases %standard-phases
+         (add-after 'unpack 'patch-tzdata
+           (lambda* (#:key inputs #:allow-other-keys)
+             (substitute* "lib/DateTime/TimeZone/Local/Unix.pm"
+               (("our \\$ZoneinfoDir = '\\/usr\\/share\\/zoneinfo';")
+                (string-append "our $ZoneinfoDir = '"
+                               (assoc-ref inputs "tzdata") "/share/zoneinfo"
+                               "';")))
+             #t)))))
     (native-inputs
      `(("perl-test-fatal" ,perl-test-fatal)
        ("perl-test-requires" ,perl-test-requires)))
+    (inputs
+     `(("tzdata" ,tzdata)))
     (propagated-inputs
      `(("perl-class-singleton" ,perl-class-singleton)
        ("perl-list-allutils" ,perl-list-allutils)