SPECS: adapter.awk - replace %{_{beta,rc,snap}} vars in sources
glen
glen at pld-linux.org
Sat Jul 16 18:03:46 CEST 2005
Author: glen Date: Sat Jul 16 16:03:46 2005 GMT
Module: SPECS Tag: HEAD
---- Log message:
- replace %{_{beta,rc,snap}} vars in sources
---- Files affected:
SPECS:
adapter.awk (1.163 -> 1.164)
---- Diffs:
================================================================
Index: SPECS/adapter.awk
diff -u SPECS/adapter.awk:1.163 SPECS/adapter.awk:1.164
--- SPECS/adapter.awk:1.163 Sat Jul 16 17:19:38 2005
+++ SPECS/adapter.awk Sat Jul 16 18:03:41 2005
@@ -468,12 +468,23 @@
filename = url[n]
url[n] = fixedsub(name, "%{name}", url[n])
- if (field ~ /source/)
+ if (field ~ /source/) {
url[n] = fixedsub(version, "%{version}", url[n])
+ if (_beta) {
+ url[n] = fixedsub(_beta, "%{_beta}", url[n])
+ }
+ if (_rc) {
+ url[n] = fixedsub(_rc, "%{_rc}", url[n])
+ }
+ if (_snap) {
+ url[n] = fixedsub(_snap, "%{_snap}", url[n])
+ }
+ }
$2 = fixedsub(filename, url[n], $2)
# sourceforge urls
sub("[?]use_mirror=.*$", "", $2);
+ sub("[?]download$", "", $2);
sub("^http://prdownloads\.sourceforge\.net/", "http://dl.sourceforge.net/", $2)
sub("^http://.*\.dl\.sourceforge\.net/", "http://dl.sourceforge.net/", $2)
@@ -515,6 +526,13 @@
mandir = $3
if ($2 ~ /_infodir/)
infodir = $3
+
+ if ($2 ~ /_beta/)
+ _beta = $3
+ if ($2 ~ /_rc/)
+ _rc = $3
+ if ($2 ~ /_snap/)
+ _snap = $3
}
if (field ~ /buildrequires:/) {
================================================================
---- CVS-web:
http://cvs.pld-linux.org/SPECS/adapter.awk?r1=1.163&r2=1.164&f=u
More information about the pld-cvs-commit
mailing list