Re: _USE_32BIT_TIME_T Patch - Mailing list pgsql-hackers

From Andrew Dunstan
Subject Re: _USE_32BIT_TIME_T Patch
Date
Msg-id 50410120.8010005@dunslane.net
Whole thread Raw
In response to Re: _USE_32BIT_TIME_T Patch  (Dave Page <dpage@pgadmin.org>)
List pgsql-hackers
On 08/31/2012 01:10 PM, Dave Page wrote:
> On Fri, Aug 31, 2012 at 5:51 PM, Andrew Dunstan <andrew@dunslane.net> wrote:
>> On 08/31/2012 12:41 PM, Dave Page wrote:
>>> On Fri, Aug 31, 2012 at 5:37 PM, Andrew Dunstan <andrew@dunslane.net>
>>> wrote:
>>>> On 08/31/2012 12:18 PM, Dave Page wrote:
>>>>> On Fri, Aug 31, 2012 at 4:57 PM, Andrew Dunstan <andrew@dunslane.net>
>>>>> wrote:
>>>>>> On 08/31/2012 11:14 AM, Dave Page wrote:
>>>>>>> On Fri, Aug 31, 2012 at 4:10 PM, Andrew Dunstan <andrew@dunslane.net>
>>>>>>> wrote:
>>>>>>>> On 08/31/2012 11:05 AM, Dave Page wrote:
>>>>>>>>> I've added this to the release blockers section for 9.2 on the wiki,
>>>>>>>>> as without it, pl/perl is unusable on Win32.
>>>>>>>>
>>>>>>>>
>>>>>>>> I'll have a look at it today.
>>>>>>> Thanks Andrew - minor clarification; unusable on MSVC/Win32. I suspect
>>>>>>> Mingw builds may be fine, as they use a much older runtime. Of course,
>>>>>>> we've used MSVC++ for the installer builds for years now.
>>>>>>
>>>>>>
>>>>>> What exactly is the known combination of things that don't work, and
>>>>>> things
>>>>>> that do work? My only 32 bit test environment for this (ASPerl 5.12.2
>>>>>> build
>>>>>> 1202 [293621], built Sep 6, 2010, Visual C++ Express 2008, Windows XP
>>>>>> SP3)
>>>>>> doesn't seem to have any problem building and running plperl. That
>>>>>> makes
>>>>>> it
>>>>>> tough to test if I don't know what exactly needs to change to break
>>>>>> things.
>>>>> We're using VC++ 2010 Pro with ASPerl 5.14.2.1402 for 9.2, and VC++
>>>>> 2008 Pro with ASPerl 5.14.1.1401 at present. Our CM team have tried
>>>>> multiple versions of Perl though, and seen the issue with 5.10 and
>>>>> 5.12 as well though. 5.8 seemed to be OK.
>>>>
>>>> OK so from that I'm guessing the issue is probably VC++ 2010, which I
>>>> don't
>>>> have at all, let alone on a 32-bit machine :-(
>>>>
>>>> Oh, well, I'll look and see if I feel comfortable about the patch anyway.
>>> It's only 2010 for 9.2. We're using 2008 with 9.1, which also exhibits
>>> the problem (see the bug report linked in my first post on this
>>> thread).
>>
>>
>> Well, that makes things harder to diagnose. Why isn't my 2008 / ASPerl
>> 5.12.2 setup exhibiting the problem?
> No idea. Differences in the SDK perhaps? You're using VC++ Express
> which (if memory serves) you have to download the SDK independently,
> whereas we get a bundled, and possibly slightly different version with
> the Pro edition.
>
> As a side note - I'm not sure why _USE_32BIT_TIME_T was removed in the
> first place; it was added specifically to avoid this sort of problem,
> though iirc at the time we were thinking of extensions like Slony and
> PostGIS being built with Mingw for use with the VC++ built server.



OK. Well, I didn't quite like the submitted patch for a couple of
reasons. First, it only affected VC2010 builds, and you said these
weren't the only ones affected. And second it didn't really highlight
what was being done.

So here are two patches, one for HEAD/9.2 and one for earlier releases,
that do this in a different way that is more obvious, and for all
versions of VC.

Please test. I will also test these.

cheers

andrew






Attachment

pgsql-hackers by date:

Previous
From: Dimitri Fontaine
Date:
Subject: Re: patch: shared session variables
Next
From: Pavel Stehule
Date:
Subject: Re: patch: shared session variables