Обсуждение: Build errors in VS

Поиск
Список
Период
Сортировка

Build errors in VS

От
"Lin, Cuiping"
Дата:
Hi all

I build postgers with VS in windows, and the following message output

“ Unable to determine Visual Studio version: The nmake version could not be determined.”

I investigated the VSObjectFactory.pm, and found the match string “if ($output =~ /(\d+)\.(\d+)\.\d+(\.\d+)?$/m)”

It works fine when no characters after version number, but if there are characters after the version number, it can not
matchthe VS version. 

For example ,  VS in Chinese , nmake /?  output  “ 14.00.24210.0 版”


May be we can remove the ‘$’  ($output =~ /(\d+)\.(\d+)\.\d+(\.\d+)?$/m)”  => ($output =~
/(\d+)\.(\d+)\.\d+(\.\d+)?/m)”


Best regards







Re: Build errors in VS

От
Andrew Dunstan
Дата:
On 4/17/20 5:18 AM, Lin, Cuiping wrote:
> Hi all
>
> I build postgers with VS in windows, and the following message output
>
> “ Unable to determine Visual Studio version: The nmake version could not be determined.”
>
> I investigated the VSObjectFactory.pm, and found the match string “if ($output =~ /(\d+)\.(\d+)\.\d+(\.\d+)?$/m)”
>
> It works fine when no characters after version number, but if there are characters after the version number, it can
notmatch the VS version.
 
>
> For example ,  VS in Chinese , nmake /?  output  “ 14.00.24210.0 版”


Hmm, odd, but I guess we need to cater for it.


>
>
> May be we can remove the ‘$’  ($output =~ /(\d+)\.(\d+)\.\d+(\.\d+)?$/m)”  => ($output =~
/(\d+)\.(\d+)\.\d+(\.\d+)?/m)”
>
>

That will probably be ok. If we do that we should remove the 'm'
qualifier on the regex too, it would serve no purpose any more.


cheers


andrew


-- 
Andrew Dunstan                https://www.2ndQuadrant.com
PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services




Re: Build errors in VS

От
Andrew Dunstan
Дата:
On 4/17/20 9:56 AM, Andrew Dunstan wrote:
> On 4/17/20 5:18 AM, Lin, Cuiping wrote:
>> Hi all
>>
>> I build postgers with VS in windows, and the following message output
>>
>> “ Unable to determine Visual Studio version: The nmake version could not be determined.”
>>
>> I investigated the VSObjectFactory.pm, and found the match string “if ($output =~ /(\d+)\.(\d+)\.\d+(\.\d+)?$/m)”
>>
>> It works fine when no characters after version number, but if there are characters after the version number, it can
notmatch the VS version.
 
>>
>> For example ,  VS in Chinese , nmake /?  output  “ 14.00.24210.0 版”
>
> Hmm, odd, but I guess we need to cater for it.
>
>
>>
>> May be we can remove the ‘$’  ($output =~ /(\d+)\.(\d+)\.\d+(\.\d+)?$/m)”  => ($output =~
/(\d+)\.(\d+)\.\d+(\.\d+)?/m)”
>>
>>
> That will probably be ok. If we do that we should remove the 'm'
> qualifier on the regex too, it would serve no purpose any more.
>
>

Done


cheers


andrew

-- 
Andrew Dunstan                https://www.2ndQuadrant.com
PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services