[Python-checkins] python/dist/src/PC python_nt.rc,1.15.14.1,1.15.14.2

tim_one@users.sourceforge.net tim_one@users.sourceforge.net
Fri, 11 Oct 2002 11:38:23 -0700


Update of /cvsroot/python/python/dist/src/PC
In directory usw-pr-cvs1:/tmp/cvs-serv893/22/PC

Modified Files:
      Tag: release22-maint
	python_nt.rc 
Log Message:
SF bug 621507:  python22.dll incorrect "File version".
The MS resource compiler can't do arithmetic.  Fixed it by hand.  Note
that the new PCbuild\field3.py was added to help with this, and injects
another manual step into the Python Windows release process.


Index: python_nt.rc
===================================================================
RCS file: /cvsroot/python/python/dist/src/PC/python_nt.rc,v
retrieving revision 1.15.14.1
retrieving revision 1.15.14.2
diff -C2 -d -r1.15.14.1 -r1.15.14.2
*** python_nt.rc	28 Feb 2002 07:43:20 -0000	1.15.14.1
--- python_nt.rc	11 Oct 2002 18:38:20 -0000	1.15.14.2
***************
*** 21,27 ****
  
  /* Nothing below this should need to be changed except for copyright
!  * notices and company name.
   */
  
  /* e.g., 2.1a2
   * PY_VERSION comes from patchevel.h
--- 21,47 ----
  
  /* Nothing below this should need to be changed except for copyright
!  * notices, company name, and FIELD3.  Unfortunately, all attempts
!  * to get the resource compiler to do arithmetic in macros have
!  * failed miserably -- it gives syntax errors, ignores operators,
!  * or does stuff that's simply bizarre.
   */
  
+ 
+ /* This is what we'd like FIELD3 to be:
+  *
+  * #define FIELD3 (PY_MICRO_VERSION*1000 + PY_RELEASE_LEVEL*10 + PY_RELEASE_SERIAL)
+  *
+  * but that neither gives an error nor comes anywhere close to working.  The
+  * following comment and #define are output from PCbuild\field3.py:
+  *
+  * For 2.2.2b1,
+  * PY_MICRO_VERSION = 2
+  * PY_RELEASE_LEVEL = 'beta' = 0xb
+  * PY_RELEASE_SERIAL = 1
+  *
+  * and 2*1000 + 11*10 + 1 = 2111
+  */
+ #define FIELD3 2111
+ 
  /* e.g., 2.1a2
   * PY_VERSION comes from patchevel.h
***************
*** 39,43 ****
  #   error "PY_RELEASE_SERIAL > 9"
  #endif
- #define FIELD3 (PY_MICRO_VERSION*1000 + PY_RELEASE_LEVEL*10 + PY_RELEASE_SERIAL)
  #define PYVERSION64 PY_MAJOR_VERSION, PY_MINOR_VERSION, FIELD3, PYTHON_API_VERSION
  
--- 59,62 ----