incubator-ooo-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From a.@apache.org
Subject svn commit: r1351712 - in /incubator/ooo/trunk/main/postprocess/signing: makefile.mk signing.pl
Date Tue, 19 Jun 2012 13:39:53 GMT
Author: af
Date: Tue Jun 19 13:39:52 2012
New Revision: 1351712

URL: http://svn.apache.org/viewvc?rev=1351712&view=rev
Log:
Use file to pass list of names instead of flooding the command line.

Modified:
    incubator/ooo/trunk/main/postprocess/signing/makefile.mk
    incubator/ooo/trunk/main/postprocess/signing/signing.pl

Modified: incubator/ooo/trunk/main/postprocess/signing/makefile.mk
URL: http://svn.apache.org/viewvc/incubator/ooo/trunk/main/postprocess/signing/makefile.mk?rev=1351712&r1=1351711&r2=1351712&view=diff
==============================================================================
--- incubator/ooo/trunk/main/postprocess/signing/makefile.mk (original)
+++ incubator/ooo/trunk/main/postprocess/signing/makefile.mk Tue Jun 19 13:39:52 2012
@@ -32,25 +32,33 @@ TARGET=signing
 # PFXFILE	has to be set elsewhere
 # PFXPASSWORD	has to be set elsewhere
 
+.IF "$(VISTA_SIGNING)"!=""
+.IF "$(COM)"=="MSC"
+.IF "$(product)"=="full"
+
 EXCLUDELIST=no_signing.txt
 LOGFILE=$(MISC)$/signing_log.txt
 IMAGENAMES=$(SOLARBINDIR)$/*.dll $(SOLARBINDIR)$/so$/*.dll $(SOLARBINDIR)$/*.exe $(SOLARBINDIR)$/so$/*.exe
 TIMESTAMPURL*="http://timestamp.verisign.com/scripts/timstamp.dll"
 
-signing.done :
-.IF "$(VISTA_SIGNING)"!=""
-.IF "$(COM)"=="MSC"
-.IF "$(product)"=="full"
-	$(PERL) signing.pl -e $(EXCLUDELIST) -f $(PFXFILE) -p $(PFXPASSWORD) -t $(TIMESTAMPURL)
$(IMAGENAMES) && $(TOUCH) $(MISC)$/signing.done
+signing.done : $(MISC)/signing-filelist.txt
+	$(PERL) signing.pl -e $(EXCLUDELIST) -f $(PFXFILE) -p $(PFXPASSWORD) -t $(TIMESTAMPURL)
-i $(MISC)/signing-filelist.txt && $(TOUCH) $(MISC)$/signing.done
+
+# Create a file that contains all dlls that are to be signed.
+$(MISC)/signing-filelist.txt :
+	-ls -1U $(IMAGENAMES) > $@ 2>/dev/null
+
+.INCLUDE : target.mk
+
 .ELSE  # "$(product)"=="full"
+all :
 	@echo Doing nothing on non product builds ...
 .ENDIF # "$(product)"=="full"
 .ELSE  # "$(GUI)"=="MSC"
+all :
 	@echo Nothing to do, signing is Windows \(MSC\) only.
 .ENDIF # "$(GUI)"=="MSC"
 .ELSE  # "$(VISTA_SIGNING)"!=""
+all :
 	@echo Doing nothing. To switch on signing set VISTA_SIGNING=TRUE ...
 .ENDIF # "$(VISTA_SIGNING)"!=""
-
-.INCLUDE : target.mk
-

Modified: incubator/ooo/trunk/main/postprocess/signing/signing.pl
URL: http://svn.apache.org/viewvc/incubator/ooo/trunk/main/postprocess/signing/signing.pl?rev=1351712&r1=1351711&r2=1351712&view=diff
==============================================================================
--- incubator/ooo/trunk/main/postprocess/signing/signing.pl (original)
+++ incubator/ooo/trunk/main/postprocess/signing/signing.pl Tue Jun 19 13:39:52 2012
@@ -82,9 +82,10 @@ sub parse_options		#09.07.2007 08:13
 {
 	# e exclude list file
 	# v verbose
+    my $filelist_filename = undef;
 	my $success = GetOptions('h' => \$opt_help,
          'd=s' => \$opt_dir, 'e=s'=>\$opt_exclude, 'f=s'=>\$opt_pfxfile, 'l=s'=>\$opt_log,
-		 'p=s'=>\$opt_pass,'v'=>\$opt_verbose, 't=s'=>\$opt_timestamp_url);
+		 'p=s'=>\$opt_pass,'v'=>\$opt_verbose, 't=s'=>\$opt_timestamp_url, 'i=s'=>\$filelist_filename);
     if ( !$success || $opt_help ) {
         usage();
         exit(1);
@@ -94,7 +95,17 @@ sub parse_options		#09.07.2007 08:13
         usage();
         exit(1);
 	}
-	return @ARGV;
+
+    # Read the names of files to sign from the given file.
+    die "no list of files given" unless defined $filelist_filename;
+    open my $in, $filelist_filename;
+    my @filelist = ();
+    while (<$in>)
+    {
+        chomp($_);
+        push @filelist, $_;
+    }
+	return @filelist;
 }	##parse_options
 
 ############################################################################
@@ -251,7 +262,7 @@ sub print_error		#09.07.2007 11:21
 sub usage		#09.07.2007 08:39
 ############################################################################
  {
-	print "Usage:\t $myname <-e filename> <-f filename> <-p password> <-t
timestamp> [-l filename] [-v] <file[list]> \n";
+	print "Usage:\t $myname <-e filename> <-f filename> <-p password> <-t
timestamp> <-i filename> [-l filename] [-v]\n";
     print "Options:\n";
 	print "\t -e filename\t\t\tFile which contains a list of files which don't have to be signed.\n";
     print                            "Mandatory.\n";
@@ -259,11 +270,8 @@ sub usage		#09.07.2007 08:39
     print                            "Mandatory.\n";
     print "\t -p password\t\t\tPassword for \"Personal Information Exchange\" file. Mandatory.\n";
     print "\t -t timestamp\t\t\tTimestamp URL e.g. \"http://timestamp.verisign.com/scripts/timstamp.dll\"\n";
+    print "\t -i filename\t\t\tName of the file that contains the names of files to sign.\"\n";
     print "\t\t\t\t\tMandatory.\n";
 	print "\t -l log_filename\t\tFile for logging.\n";
     print "\t -v\t\t\t\tVerbose.\n";
 }	##usage
-
-
-
-



Mime
View raw message