From: William A. Rowe Jr Date: Thu, 12 Jan 2006 16:27:56 +0000 (+0000) Subject: Correct version and copyright generation, this involves 'long line' X-Git-Tag: 2.0.56~106 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=bc7dd1f3c1fc48fb16758de2bb91040eab848bed;p=thirdparty%2Fapache%2Fhttpd.git Correct version and copyright generation, this involves 'long line' flavor of the first ASF copyright line; we could use the new macro AP_SERVER_COPYRIGHT and defined tokens from this file for versions, however this is 2.0 so not expecting that we will do so. Backports; 368395 git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/branches/2.0.x@368397 13f79535-47bb-0310-9956-ffa450edef68 --- diff --git a/build/win32/win32ver.awk b/build/win32/win32ver.awk index 0e3e847e7d8..52ae9e92d33 100644 --- a/build/win32/win32ver.awk +++ b/build/win32/win32ver.awk @@ -1,4 +1,4 @@ -# Copyright 2001-2005 The Apache Software Foundation or its licensors, as +# Copyright 2001-2006 The Apache Software Foundation or its licensors, as # applicable. # # Licensed under the Apache License, Version 2.0 (the "License"); @@ -50,30 +50,32 @@ BEGIN { } while ((getline < rel_h) > 0) { - if (match ($0, /^#define AP_SERVER_MAJORVERSION "[^"]+"/)) { - ver_major = substr($3, 2, length($3) - 2); + if (match ($0, /^.*\* Copyright /)) { + copyright = substr($0, RLENGTH + 1); } - else if (match ($0, /^#define AP_SERVER_MINORVERSION "[^"]+"/)) { - ver_minor = substr($3, 2, length($3) - 2); + if (match ($0, /^#define AP_SERVER_MAJORVERSION_NUMBER /)) { + ver_major = $3; } - else if (match ($0, /^#define AP_SERVER_PATCHLEVEL "[^"]+"/)) { - ver_patch = substr($3, 2, length($3) - 2); + else if (match ($0, /^#define AP_SERVER_MINORVERSION_NUMBER /)) { + ver_minor = $3; + } + else if (match ($0, /^#define AP_SERVER_PATCHLEVEL_NUMBER /)) { + ver_patch = $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; - verc = ver_major "," ver_minor "," ver_patch; - gsub(/\./, ",", verc); - if (build) { - sub(/-.*/, "", verc) - verc = verc "," build; - } else if (sub(/-dev/, ",0", verc)) { - ff = ff + 2; - } else if (!sub(/-alpha/, ",10", verc) \ - && !sub(/-beta/, ",100", verc) \ - && !sub(/-gold/, ",200", verc)) { - sub(/-.*/, "", verc); + ver = ver_major "." ver_minor "." ver_patch ver_build; + verc = ver_major "," ver_minor "," ver_patch; + if (match (ver_build, /-dev/)) { + ff = ff + 2; verc = verc "," 0; + } else if (!ver_build) { + verc = verc "," 200; + } else { + verc = verc "," 100; } if (length(vendor)) { @@ -100,17 +102,22 @@ BEGIN { print " BEGIN"; print " BLOCK \"040904b0\""; print " BEGIN"; - print " VALUE \"Comments\", \"All rights reserved. The license "\ - "is available at . "\ - "The Apache HTTP Server project pages are at "\ - ".\\0\""; + print " VALUE \"Comments\", "\ + "\"Licensed under the Apache License, Version 2.0 (the \"\"License\"\"); "\ + "you may not use this file except in compliance with the License. "\ + "You may obtain a copy of the License at\\r\\n\\r\\n"\ + "http://www.apache.org/licenses/LICENSE-2.0\\r\\n\\r\\n"\ + "Unless required by applicable law or agreed to in writing, "\ + "software distributed under the License is distributed on an "\ + "\"\"AS IS\"\" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, "\ + "either express or implied. See the License for the specific "\ + "language governing permissions and limitations under the License.\\0\""; print " VALUE \"CompanyName\", \"Apache Software Foundation\\0\""; print " VALUE \"FileDescription\", \"" desc "\\0\""; print " VALUE \"FileVersion\", \"" ver "\\0\""; print " VALUE \"InternalName\", \"" file "\\0\""; - print " VALUE \"LegalCopyright\", \"Copyright © 2000-2004 "\ - "The Apache Software Foundation.\\0\""; - print " VALUE \"OriginalFilename\", \"" file ".exe\\0\""; + print " VALUE \"LegalCopyright\", \"Copyright " copyright "\\0\""; + print " VALUE \"OriginalFilename\", \"" file "\\0\""; if (vendor) { print " VALUE \"PrivateBuild\", \"" vendor "\\0\""; } diff --git a/include/ap_release.h b/include/ap_release.h index 442da522578..b034af653b1 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. @@ -19,6 +18,10 @@ #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 * tokens can be added via the ap_add_version_component() API call.