packages: pldnotify.awk - xulrunner hacks

glen glen at pld-linux.org
Mon Oct 25 07:55:43 CEST 2010


Author: glen                         Date: Mon Oct 25 05:55:43 2010 GMT
Module: packages                      Tag: HEAD
---- Log message:
- xulrunner hacks

---- Files affected:
packages:
   pldnotify.awk (1.97 -> 1.98) 

---- Diffs:

================================================================
Index: packages/pldnotify.awk
diff -u packages/pldnotify.awk:1.97 packages/pldnotify.awk:1.98
--- packages/pldnotify.awk:1.97	Sat Oct 16 10:06:51 2010
+++ packages/pldnotify.awk	Mon Oct 25 07:55:37 2010
@@ -454,12 +454,12 @@
 	return url
 }
 
-function process_source(number,lurl,name,version) {
+function process_source(number, lurl, name, version) {
 # fetches file list, and compares version numbers
 	d("Processing " lurl)
 
-	if ( index(lurl,version)==0 ) {
-		d("There is no version number.")
+	if (index(lurl, version) == 0) {
+		d("There is no version number ["version"] in ["lurl"]")
 		return 0
 	}
 
@@ -544,7 +544,7 @@
 				}
 			}
 		}
-		if (finished==0)
+		if (finished == 0)
 			print name "(" number ") seems ok: " oldversion
 		else
 			print name "(" number ") [OLD] " oldversion " [NEW] " version
@@ -615,7 +615,7 @@
 	}
 }
 
-function process_data(name,ver,rel,src) {
+function process_data(name, ver, rel, src) {
 	if (name ~ /^php-pear-/) {
 		return pear_upgrade(name, ver);
 	}
@@ -628,16 +628,20 @@
 	if (name == "vim") {
 		return vim_upgrade(name, ver);
 	}
+	if (name == "xulrunner") {
+		ver = subst_defines(DEFS["firefox_ver"], DEFS)
+		d("package xulrunner, change version to firefox ["ver"]")
+	}
 
 # this function checks if substitutions were valid, and if true:
 # processes each URL and tries to get current file list
 	for (i in src) {
-		if ( src[i] ~ /%{nil}/ ) {
+		if (src[i] ~ /%{nil}/) {
 			gsub(/\%\{nil\}/, "", src[i])
 		}
 		if ( src[i] !~ /%{.*}/ && src[i] !~ /%[A-Za-z0-9_]/ )  {
 			d("Source: " src[i])
-			process_source(i,src[i],name,ver)
+			process_source(i, src[i], name, ver)
 		} else {
 			print FNAME ":" i ": impossible substitution: " src[i]
 		}
================================================================

---- CVS-web:
    http://cvs.pld-linux.org/cgi-bin/cvsweb.cgi/packages/pldnotify.awk?r1=1.97&r2=1.98&f=u



More information about the pld-cvs-commit mailing list