Mercurial > cpython-lru_cache-weakref
annotate PC/make_versioninfo.c @ 58925:eecf1bef052d 2.6
Merged revisions 78207 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/trunk
........
r78207 | ezio.melotti | 2010-02-17 01:26:09 +0200 (Wed, 17 Feb 2010) | 1 line
#7930: fix stripid
........
| author | Ezio Melotti <ezio.melotti@gmail.com> |
|---|---|
| date | Tue, 16 Feb 2010 23:29:44 +0000 |
| parents | 00c02c4488ce |
| children | fd25030223b0 |
| rev | line source |
|---|---|
|
30747
77d5308bedae
This commit was manufactured by cvs2svn to create branch
cvs2svn <tools@python.org>
parents:
diff
changeset
|
1 #include <stdio.h> |
|
77d5308bedae
This commit was manufactured by cvs2svn to create branch
cvs2svn <tools@python.org>
parents:
diff
changeset
|
2 #include "patchlevel.h" |
|
77d5308bedae
This commit was manufactured by cvs2svn to create branch
cvs2svn <tools@python.org>
parents:
diff
changeset
|
3 /* |
|
77d5308bedae
This commit was manufactured by cvs2svn to create branch
cvs2svn <tools@python.org>
parents:
diff
changeset
|
4 * This program prints out an include file containing fields required to build |
|
77d5308bedae
This commit was manufactured by cvs2svn to create branch
cvs2svn <tools@python.org>
parents:
diff
changeset
|
5 * the version info resource of pythonxx.dll because the resource compiler |
|
77d5308bedae
This commit was manufactured by cvs2svn to create branch
cvs2svn <tools@python.org>
parents:
diff
changeset
|
6 * cannot do the arithmetic. |
|
77d5308bedae
This commit was manufactured by cvs2svn to create branch
cvs2svn <tools@python.org>
parents:
diff
changeset
|
7 */ |
|
77d5308bedae
This commit was manufactured by cvs2svn to create branch
cvs2svn <tools@python.org>
parents:
diff
changeset
|
8 /* |
|
77d5308bedae
This commit was manufactured by cvs2svn to create branch
cvs2svn <tools@python.org>
parents:
diff
changeset
|
9 * FIELD3 is the third field of the version number. |
|
77d5308bedae
This commit was manufactured by cvs2svn to create branch
cvs2svn <tools@python.org>
parents:
diff
changeset
|
10 * This is what we'd like FIELD3 to be: |
|
77d5308bedae
This commit was manufactured by cvs2svn to create branch
cvs2svn <tools@python.org>
parents:
diff
changeset
|
11 * |
|
77d5308bedae
This commit was manufactured by cvs2svn to create branch
cvs2svn <tools@python.org>
parents:
diff
changeset
|
12 * #define FIELD3 (PY_MICRO_VERSION*1000 + PY_RELEASE_LEVEL*10 + PY_RELEASE_SERIAL) |
|
77d5308bedae
This commit was manufactured by cvs2svn to create branch
cvs2svn <tools@python.org>
parents:
diff
changeset
|
13 * |
|
77d5308bedae
This commit was manufactured by cvs2svn to create branch
cvs2svn <tools@python.org>
parents:
diff
changeset
|
14 * but that neither gives an error nor comes anywhere close to working. |
|
77d5308bedae
This commit was manufactured by cvs2svn to create branch
cvs2svn <tools@python.org>
parents:
diff
changeset
|
15 * |
|
77d5308bedae
This commit was manufactured by cvs2svn to create branch
cvs2svn <tools@python.org>
parents:
diff
changeset
|
16 * For 2.4a0, |
|
77d5308bedae
This commit was manufactured by cvs2svn to create branch
cvs2svn <tools@python.org>
parents:
diff
changeset
|
17 * PY_MICRO_VERSION = 0 |
|
77d5308bedae
This commit was manufactured by cvs2svn to create branch
cvs2svn <tools@python.org>
parents:
diff
changeset
|
18 * PY_RELEASE_LEVEL = 'alpha' = 0xa |
|
77d5308bedae
This commit was manufactured by cvs2svn to create branch
cvs2svn <tools@python.org>
parents:
diff
changeset
|
19 * PY_RELEASE_SERIAL = 0 |
|
77d5308bedae
This commit was manufactured by cvs2svn to create branch
cvs2svn <tools@python.org>
parents:
diff
changeset
|
20 * |
|
77d5308bedae
This commit was manufactured by cvs2svn to create branch
cvs2svn <tools@python.org>
parents:
diff
changeset
|
21 * gives FIELD3 = 0*1000 + 10*10 + 0 = 100 |
|
77d5308bedae
This commit was manufactured by cvs2svn to create branch
cvs2svn <tools@python.org>
parents:
diff
changeset
|
22 */ |
|
77d5308bedae
This commit was manufactured by cvs2svn to create branch
cvs2svn <tools@python.org>
parents:
diff
changeset
|
23 int main(int argc, char **argv) |
|
77d5308bedae
This commit was manufactured by cvs2svn to create branch
cvs2svn <tools@python.org>
parents:
diff
changeset
|
24 { |
|
77d5308bedae
This commit was manufactured by cvs2svn to create branch
cvs2svn <tools@python.org>
parents:
diff
changeset
|
25 printf("/* This file created by make_versioninfo.exe */\n"); |
|
77d5308bedae
This commit was manufactured by cvs2svn to create branch
cvs2svn <tools@python.org>
parents:
diff
changeset
|
26 printf("#define FIELD3 %d\n", |
|
77d5308bedae
This commit was manufactured by cvs2svn to create branch
cvs2svn <tools@python.org>
parents:
diff
changeset
|
27 PY_MICRO_VERSION*1000 + PY_RELEASE_LEVEL*10 + PY_RELEASE_SERIAL); |
|
77d5308bedae
This commit was manufactured by cvs2svn to create branch
cvs2svn <tools@python.org>
parents:
diff
changeset
|
28 printf("#define MS_DLL_ID \"%d.%d\"\n", |
|
77d5308bedae
This commit was manufactured by cvs2svn to create branch
cvs2svn <tools@python.org>
parents:
diff
changeset
|
29 PY_MAJOR_VERSION, PY_MINOR_VERSION); |
|
41716
00c02c4488ce
Merged revisions 55325-55327 via svnmerge from
Guido van Rossum <guido@python.org>
parents:
30747
diff
changeset
|
30 printf("#ifndef _DEBUG\n"); |
|
30747
77d5308bedae
This commit was manufactured by cvs2svn to create branch
cvs2svn <tools@python.org>
parents:
diff
changeset
|
31 printf("#define PYTHON_DLL_NAME \"python%d%d.dll\"\n", |
|
77d5308bedae
This commit was manufactured by cvs2svn to create branch
cvs2svn <tools@python.org>
parents:
diff
changeset
|
32 PY_MAJOR_VERSION, PY_MINOR_VERSION); |
|
41716
00c02c4488ce
Merged revisions 55325-55327 via svnmerge from
Guido van Rossum <guido@python.org>
parents:
30747
diff
changeset
|
33 printf("#else\n"); |
|
00c02c4488ce
Merged revisions 55325-55327 via svnmerge from
Guido van Rossum <guido@python.org>
parents:
30747
diff
changeset
|
34 printf("#define PYTHON_DLL_NAME \"python%d%d_d.dll\"\n", |
|
00c02c4488ce
Merged revisions 55325-55327 via svnmerge from
Guido van Rossum <guido@python.org>
parents:
30747
diff
changeset
|
35 PY_MAJOR_VERSION, PY_MINOR_VERSION); |
|
00c02c4488ce
Merged revisions 55325-55327 via svnmerge from
Guido van Rossum <guido@python.org>
parents:
30747
diff
changeset
|
36 printf("#endif\n"); |
|
30747
77d5308bedae
This commit was manufactured by cvs2svn to create branch
cvs2svn <tools@python.org>
parents:
diff
changeset
|
37 return 0; |
|
77d5308bedae
This commit was manufactured by cvs2svn to create branch
cvs2svn <tools@python.org>
parents:
diff
changeset
|
38 } |
