You are viewing a plain text version of this content. The canonical link for it is here.
Posted to cvs@httpd.apache.org by ia...@apache.org on 2002/08/23 21:36:26 UTC
cvs commit: httpd-2.0/build/win32 win32ver.awk
ianh 2002/08/23 12:36:26
Modified: build/win32 win32ver.awk
Log:
Make version strings work properly with update macro definitions
Submitted by : Branko Cibej <br...@xbc.nu>
Revision Changes Path
1.5 +10 -3 httpd-2.0/build/win32/win32ver.awk
Index: win32ver.awk
===================================================================
RCS file: /home/cvs/httpd-2.0/build/win32/win32ver.awk,v
retrieving revision 1.4
retrieving revision 1.5
diff -u -r1.4 -r1.5
--- win32ver.awk 13 Mar 2002 20:47:40 -0000 1.4
+++ win32ver.awk 23 Aug 2002 19:36:26 -0000 1.5
@@ -35,12 +35,19 @@
}
while ((getline < rel_h) > 0) {
- if (match ($0, /^#define AP_SERVER_BASEREVISION "[^"]+"/)) {
- ver = substr($0, RSTART + 32, RLENGTH - 33);
+ if (match ($0, /^#define AP_SERVER_MAJORVERSION "[^"]+"/)) {
+ ver_major = substr($3, 2, length($3) - 2);
+ }
+ else if (match ($0, /^#define AP_SERVER_MINORVERSION "[^"]+"/)) {
+ ver_minor = substr($3, 2, length($3) - 2);
+ }
+ else if (match ($0, /^#define AP_SERVER_PATCHLEVEL "[^"]+"/)) {
+ ver_patch = substr($3, 2, length($3) - 2);
}
}
- verc = ver;
+ ver = ver_major "." ver_minor "." ver_patch;
+ verc = ver_major "," ver_minor "," ver_patch;
gsub(/\./, ",", verc);
if (build) {
sub(/-.*/, "", verc)