From: William A. Rowe Jr Date: Thu, 12 Jan 2006 16:11:01 +0000 (+0000) Subject: Determined that yes; apr_general.h may be included in .rc files, X-Git-Tag: 2.3.0~2619 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=10be84690a6271af58ae9734c22fd781d0325401;p=thirdparty%2Fapache%2Fhttpd.git Determined that yes; apr_general.h may be included in .rc files, so eliminate a substitute declaration. Correct version and copyright generation, this involves 'long line' flavor of the first ASF copyright line; next step will be no more awk generation of .rc files, so there we will use the new macro AP_SERVER_COPYRIGHT and defined tokens from this file for versions. git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@368395 13f79535-47bb-0310-9956-ffa450edef68 --- diff --git a/build/win32/win32ver.awk b/build/win32/win32ver.awk index 5ecf4d314fe..0f4f8de24e5 100644 --- a/build/win32/win32ver.awk +++ b/build/win32/win32ver.awk @@ -50,7 +50,7 @@ BEGIN { } while ((getline < rel_h) > 0) { - if (match ($0, /^.*Copyright /)) { + if (match ($0, /^.*\* Copyright /)) { copyright = substr($0, RLENGTH + 1); } if (match ($0, /^#define AP_SERVER_MAJORVERSION_NUMBER /)) { @@ -62,20 +62,25 @@ BEGIN { else if (match ($0, /^#define AP_SERVER_PATCHLEVEL_NUMBER /)) { ver_patch = $3; } + else if (match ($0, /^#define AP_SERVER_DEVBUILD_BOOLEAN /)) { + ver_devbuild = $3; + } else if (match ($0, /^#define AP_SERVER_ADD_STRING +"[^"]+"/)) { ver_build = substr($3, 2, length($3) - 2); } } - ver = ver_major "." ver_minor "." ver_patch ver_build; - gsub(/\./, ",", verc); - if (match (ver_build, /-dev/)) { + ver = ver_major "." ver_minor "." ver_patch; + if (!ver_devbuild) { + verc = ver_major "," ver_minor "," ver_patch; + } else if (!match (ver_build, /-dev/)) { ff = ff + 2; - verc = verc "," 0; - } else if (!ver_build) { - verc = verc "," 200; + verc = ver_major "," ver_minor "," ver_patch "," 100; + ver = ver ver_build; } else { - verc = verc "," 100; + ff = ff + 2; + verc = ver_major "," ver_minor "," ver_patch "," 0; + ver = ver ver_build; } if (length(vendor)) { diff --git a/include/ap_release.h b/include/ap_release.h index 40ae2155e0a..ff93a213449 100644 --- a/include/ap_release.h +++ b/include/ap_release.h @@ -1,5 +1,4 @@ -/* Copyright 2001-2005 The Apache Software Foundation or its licensors, as - * applicable. +/* Copyright 2001-2005 The Apache Software Foundation or its licensors, as applicable. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. @@ -22,13 +21,10 @@ #ifndef AP_RELEASE_H #define AP_RELEASE_H -/* The numeric compile-time version constants. These constants are the - * authoritative version numbers for APR. - */ -/** Properly quote a value as a string in the C preprocessor */ -#define AP_STRINGIFY(n) AP_STRINGIFY_HELPER(n) -/** Helper macro for AP_STRINGIFY */ -#define AP_STRINGIFY_HELPER(n) #n +#include "apr_general.h" /* stringify */ + +#define AP_SERVER_COPYRIGHT "Copyright 2001-2005 The Apache Software Foundation" \ + " or its licensors, as applicable." /* * The below defines the base string of the Server: header. Additional @@ -57,9 +53,9 @@ #endif /* keep old macros as well */ -#define AP_SERVER_MAJORVERSION AP_STRINGIFY(AP_SERVER_MAJORVERSION_NUMBER) -#define AP_SERVER_MINORVERSION AP_STRINGIFY(AP_SERVER_MINORVERSION_NUMBER) -#define AP_SERVER_PATCHLEVEL AP_STRINGIFY(AP_SERVER_PATCHLEVEL_NUMBER) \ +#define AP_SERVER_MAJORVERSION APR_STRINGIFY(AP_SERVER_MAJORVERSION_NUMBER) +#define AP_SERVER_MINORVERSION APR_STRINGIFY(AP_SERVER_MINORVERSION_NUMBER) +#define AP_SERVER_PATCHLEVEL APR_STRINGIFY(AP_SERVER_PATCHLEVEL_NUMBER) \ AP_SERVER_ADD_STRING #define AP_SERVER_MINORREVISION AP_SERVER_MAJORVERSION "." AP_SERVER_MINORVERSION diff --git a/support/win32/ApacheMonitor.dsp b/support/win32/ApacheMonitor.dsp index 14616aa991e..42f8575b254 100644 --- a/support/win32/ApacheMonitor.dsp +++ b/support/win32/ApacheMonitor.dsp @@ -43,11 +43,11 @@ RSC=rc.exe # PROP Ignore_Export_Lib 0 # PROP Target_Dir "" # ADD BASE CPP /nologo /MD /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /FD /c -# ADD CPP /nologo /MD /W3 /GX /O2 /Oy- /Zi /I "../../include" /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /D "STRICT" /Fd"Release/ApacheMonitor_src" /FD /c +# ADD CPP /nologo /MD /W3 /GX /O2 /Oy- /Zi /I "../../include" /I "../../srclib/apr/include" /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /D "STRICT" /Fd"Release/ApacheMonitor_src" /FD /c # ADD BASE MTL /nologo /D "NDEBUG" /mktyplib203 /win32 # ADD MTL /nologo /D "NDEBUG" /mktyplib203 /win32 # ADD BASE RSC /l 0x409 /d "NDEBUG" -# ADD RSC /l 0x409 /i "../../include" /d "NDEBUG" +# ADD RSC /l 0x409 /i "../../include" /I "../../srclib/apr/include" /d "NDEBUG" BSC32=bscmake.exe # ADD BASE BSC32 /nologo # ADD BSC32 /nologo @@ -69,11 +69,11 @@ LINK32=link.exe # PROP Ignore_Export_Lib 0 # PROP Target_Dir "" # ADD BASE CPP /nologo /W3 /Gm /GX /Zi /Od /D "WIN32" /D "_DEBUG" /D "_WINDOWS" /D "_MBCS" /FD /c -# ADD CPP /nologo /MDd /W3 /Gm /GX /Zi /Od /I "../../include" /D "WIN32" /D "_DEBUG" /D "_WINDOWS" /D "_MBCS" /D "STRICT" /Fd"Debug/ApacheMonitor_src" /FD /c +# ADD CPP /nologo /MDd /W3 /Gm /GX /Zi /Od /I "../../include" /I "../../srclib/apr/include" /D "WIN32" /D "_DEBUG" /D "_WINDOWS" /D "_MBCS" /D "STRICT" /Fd"Debug/ApacheMonitor_src" /FD /c # ADD BASE MTL /nologo /D "_DEBUG" /mktyplib203 /win32 # ADD MTL /nologo /D "_DEBUG" /mktyplib203 /win32 # ADD BASE RSC /l 0x409 /d "_DEBUG" -# ADD RSC /l 0x409 /i "../../include" /d "_DEBUG" +# ADD RSC /l 0x409 /i "../../include" /I "../../srclib/apr/include" /d "_DEBUG" BSC32=bscmake.exe # ADD BASE BSC32 /nologo # ADD BSC32 /nologo