Commit 3883be3
committed
Absorb -D_USE_32BIT_TIME_T switch from Perl, if relevant.
Commit 3c163a7's original choice to ignore all #define symbols whose
names begin with underscore turns out to be too simplistic. On Windows,
some Perl installations are built with -D_USE_32BIT_TIME_T, and we must
absorb that or we get the wrong result for sizeof(PerlInterpreter).
This effectively re-reverts commit ef58b87, which injected that symbol
in a hacky way, making it apply to all of Postgres not just PL/Perl.
More significantly, it did so on *all* 32-bit Windows builds, even when
the Perl build to be used did not select this option; so that it fails
to work properly with some newer Perl builds.
By making this change, we would be introducing an ABI break in 32-bit
Windows builds; but fortunately we have not used type time_t in any
exported Postgres APIs in a long time. So it should be OK, both for
PL/Perl itself and for third-party extensions, if an extension library
is built with a different _USE_32BIT_TIME_T setting than the core code.
Patch by me, based on research by Ashutosh Sharma and Robert Haas.
Back-patch to all supported branches, as commit 3c163a7 was.
Discussion: https://postgr.es/m/CANFyU97OVQ3+Mzfmt3MhuUm5NwPU=-FtbNH5Eb7nZL9ua8=rcA@mail.gmail.com1 parent a64b5a9 commit 3883be3
File tree
5 files changed
+12
-20
lines changed- config
- src/tools/msvc
5 files changed
+12
-20
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
59 | 59 | | |
60 | 60 | | |
61 | 61 | | |
62 | | - | |
| 62 | + | |
| 63 | + | |
| 64 | + | |
63 | 65 | | |
64 | 66 | | |
65 | 67 | | |
| |||
68 | 70 | | |
69 | 71 | | |
70 | 72 | | |
71 | | - | |
| 73 | + | |
72 | 74 | | |
73 | 75 | | |
74 | 76 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
7519 | 7519 | | |
7520 | 7520 | | |
7521 | 7521 | | |
7522 | | - | |
| 7522 | + | |
7523 | 7523 | | |
7524 | 7524 | | |
7525 | 7525 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
63 | 63 | | |
64 | 64 | | |
65 | 65 | | |
66 | | - | |
67 | | - | |
68 | | - | |
69 | | - | |
70 | | - | |
71 | 66 | | |
72 | 67 | | |
73 | | - | |
| 68 | + | |
74 | 69 | | |
75 | 70 | | |
76 | 71 | | |
77 | 72 | | |
78 | 73 | | |
79 | 74 | | |
80 | | - | |
| 75 | + | |
81 | 76 | | |
82 | 77 | | |
83 | 78 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
521 | 521 | | |
522 | 522 | | |
523 | 523 | | |
524 | | - | |
| 524 | + | |
| 525 | + | |
525 | 526 | | |
526 | 527 | | |
527 | 528 | | |
528 | 529 | | |
529 | 530 | | |
530 | 531 | | |
531 | | - | |
| 532 | + | |
532 | 533 | | |
533 | 534 | | |
534 | 535 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
33 | 33 | | |
34 | 34 | | |
35 | 35 | | |
36 | | - | |
37 | | - | |
38 | | - | |
39 | | - | |
40 | | - | |
41 | | - | |
42 | 36 | | |
43 | 37 | | |
44 | | - | |
| 38 | + | |
45 | 39 | | |
46 | 40 | | |
47 | 41 | | |
48 | 42 | | |
49 | 43 | | |
50 | 44 | | |
51 | 45 | | |
52 | | - | |
| 46 | + | |
53 | 47 | | |
54 | 48 | | |
55 | 49 | | |
| |||
0 commit comments