File: reproducible.patch

package info (click to toggle)
juman 7.0-3.10
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 40,528 kB
  • sloc: sh: 10,168; ansic: 9,976; perl: 5,195; makefile: 738
file content (18 lines) | stat: -rw-r--r-- 757 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
Author: Andreas Beckmann <anbe@debian.org>
Description: create Grammar.pm reproducibly

--- a/perl/mkgrammarpm
+++ b/perl/mkgrammarpm
@@ -55,10 +55,11 @@ sub main {
     my $fh = IO::File->new( $TARGET, "w" ) or die "Cannot open $TARGET: $!\n";
     print STDERR "Writing $TARGET ... ";
     $fh->print( <DATA> );
+    local $Data::Dumper::Sortkeys = 1;
     $fh->print( Data::Dumper->Dump( [ \@hinsi, \%bunrui, \@type, \%form ],
 				    [ "HINSI", "BUNRUI", "TYPE", "FORM" ] ) );
     $fh->print( "\n1;\n\n" );
-    $fh->printf( <<'__memo__', $grammar_file, $katuyou_file, $0, scalar(localtime) );
+    $fh->printf( <<'__memo__', $grammar_file, $katuyou_file, $0, scalar($ENV{'SOURCE_DATE_EPOCH'} || localtime) );
 =head1 MEMO
 
 This module is generated