From: | Robert Haas <robertmhaas(at)gmail(dot)com> |
---|---|
To: | Brar Piening <brar(at)gmx(dot)de> |
Cc: | Abhijit Menon-Sen <ams(at)2ndquadrant(dot)com>, Peter Eisentraut <peter_e(at)gmx(dot)net>, pgsql-hackers <pgsql-hackers(at)postgresql(dot)org> |
Subject: | Re: Perl coding error in msvc build system? |
Date: | 2015-02-02 14:02:18 |
Message-ID: | CA+TgmoYE4ND8m4j9a=dpKdq4xytXUQDAw4ncSKjHrYkj+P8Fgw@mail.gmail.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
On Fri, Jan 23, 2015 at 4:17 PM, Brar Piening <brar(at)gmx(dot)de> wrote:
> Am 23.01.2015 um 09:17 schrieb Abhijit Menon-Sen:
>> At 2014-06-03 22:30:50 -0400, peter_e(at)gmx(dot)net wrote:
>>> I'm not sure whether the following coding actually detects any errors:
>>>
>>> Solution.pm:
>>>
>>> open(P, "cl /? 2>&1 |") || die "cl command not found";
>>
>> Since nobody with a Windows system has commented, I'm just writing to
>> say that from a Perl perspective, I agree with your analysis and the
>> patch looks perfectly sensible.
>>
>>
> I can confirm it on my Windows system.
>
> Calling build from a console without nmake in the path I always get:
> Unable to determine Visual Studio version: The nmake version could not be
> determined. at src/tools/msvc/Mkvcbuild.pm line 63.
>
> This means that the following construct in VSObjectFactory.pm doesn't have
> the desired effect.
> open(P, "nmake /? 2>&1 |")
> || croak
> "Unable to determine Visual Studio version: The nmake command wasn't
> found.";
>
> On the other hand complicacy is in the eye of the beholder.
> Perl constructs like the following get quite a few wtf's
> (http://www.osnews.com/story/19266/WTFs_m) from a simple-minded person like
> me.
> $? >> 8 == 0 or die "cl command not found";
>
> However as it fixes a confirmed problem and as maintainance of perl code is
> an issue of its own, please go ahead.
This patch been reviewed by 4 people, resulting in 2 minor suggestions
for changes (adding an m modifier, and removing a bogus last).
It has 2 clear upvotes and 0 downvotes.
I think it should be revised along the lines suggested and committed
without further ado.
--
Robert Haas
EnterpriseDB: http://www.enterprisedb.com
The Enterprise PostgreSQL Company
From | Date | Subject | |
---|---|---|---|
Next Message | Atri Sharma | 2015-02-02 14:02:20 | Re: Implementation of global temporary tables? |
Previous Message | Robert Haas | 2015-02-02 13:58:03 | Re: pg_basebackup fails with long tablespace paths |