Page 1 of 1

Get error building on Windows XP

Posted: Tue Nov 13, 2018 7:55 pm
by linush100
I'm attempting to build from the latest source, 9669 but get an error. I have MS Visual Studio 2008 Pro trial version with SP1 and x64 support as specified in the BUILD_WINDOWS.TXT file. I think it is most of the way done and failing on the GenerateVersionResource command - Generate a Version Information Resource File. The following is from the build log html file:

---------------------------------------------------------------------------
Build Log

Rebuild started: Project: vpncmdsys, Configuration: Release|Win32

Command Lines

Creating temporary file "c:\VC2008Proj\v4.28-9669\src\vpncmdsys\Win32_Release\RSP00000125642644.rsp" with contents
[
/Ox /I "C:\VC2008Proj\v4.28-9669\src\Mayaqua\win32_inc" /I "." /I "C:\VC2008Proj\v4.28-9669\src\\" /D "WIN32" /D "NDEBUG" /D "_CONSOLE" /D "VPN_SPEED" /D "_MBCS" /FD /MT /Zp8 /GS- /Fo"Win32_Release\\" /Fd"Win32_Release\vc90.pdb" /W3 /c /Zi /TC /wd4996 ".\vpncmdsys.c"
]
Creating command line "cl.exe @"c:\VC2008Proj\v4.28-9669\src\vpncmdsys\Win32_Release\RSP00000125642644.rsp" /nologo /errorReport:queue"
Creating command line "rc.exe /fo"Win32_Release/vpncmdsys.res" ".\vpncmdsys.rc""
Creating temporary file "c:\VC2008Proj\v4.28-9669\src\vpncmdsys\Win32_Release\BAT00000225642644.bat" with contents
[
@echo off

C:\VC2008Proj\v4.28-9669\src\bin\BuildUtil.exe /CMD:GenerateVersionResource "C:\VC2008Proj\v4.28-9669\src\bin\hamcore\vpncmdsys.exe" /OUT:"C:\VC2008Proj\v4.28-9669\src\tmp\VersionResources\vpncmdsys_Win32.res"

if errorlevel 1 goto VCReportError

goto VCEnd

:VCReportError

echo Project : error PRJ0019: A tool returned an error code from "Performing Pre-Link Event..."

exit 1

:VCEnd
]
Creating command line """c:\VC2008Proj\v4.28-9669\src\vpncmdsys\Win32_Release\BAT00000225642644.bat"""

Output Window

Compiling...
vpncmdsys.c
Compiling resources...
Microsoft (R) Windows (R) Resource Compiler Version 6.1.6723.1
Copyright (C) Microsoft Corporation. All rights reserved.
Performing Pre-Link Event...
BuildUtil command - VPN Build Utility
Copyright (c) SoftEther VPN Project. All Rights Reserved.
GenerateVersionResource command - Generate a Version Information Resource File.
Executing 'bin\rc.exe "C:\Documents and Settings\Linus Hicks\Local Settings\Temp\NET_6B2F\__A84E4D5EB44B5C8368496F20AE508CFAC61AD407.rc"'...
System.ComponentModel.Win32Exception: The system cannot find the file specified
at System.Diagnostics.Process.StartWithCreateProcess(ProcessStartInfo startInfo)
at System.Diagnostics.Process.Start()
at BuildUtil.Win32BuildUtil.ExecCommand(String exe, String arg, Boolean shell_execute)
at BuildUtil.Win32BuildUtil.ExecCommand(String exe, String arg)
at BuildUtil.Win32BuildUtil.GenerateVersionInfoResource(String targetExeName, String outName, String rc_name, String product_name)
at BuildUtil.BuildUtilCommands.GenerateVersionResource(ConsoleService c, String cmdName, String str)
BuildUtil: fatal error C0001: The system cannot find the file specified
Project : error PRJ0019: A tool returned an error code from "Performing Pre-Link Event..."

Results

Build log was saved at "file://c:\VC2008Proj\v4.28-9669\src\vpncmdsys\Win32_Release\BuildLog.htm"
vpncmdsys - 2 error(s), 0 warning(s)
---------------------------------------------------------------------------

The folder: C:\Documents and Settings\Linus Hicks\Local Settings\Temp\NET_6B2F
does not exist.

How do I resolve this error?
Thanks for your help.
Linus

Re: Get error building on Windows XP

Posted: Wed Nov 14, 2018 9:59 pm
by linush100
This code appears to be wrong:

In src\BuildUtil\VpnBuilder.cs
---------------------------------------------------------------
// Get Microsoft SDK 6.0a directory
if (IntPtr.Size == 4)
{
Paths.MicrosoftSDKDir = IO.RemoteLastEnMark(Reg.ReadStr(RegRoot.LocalMachine, @"SOFTWARE\Wow6432Node\Microsoft\Microsoft SDKs\Windows\v6.0A", "InstallationFolder"));
}
else
{
Paths.MicrosoftSDKDir = IO.RemoteLastEnMark(Reg.ReadStr(RegRoot.LocalMachine, @"SOFTWARE\Microsoft\Microsoft SDKs\Windows\v6.0A", "InstallationFolder"));
}
---------------------------------------------------------------

I am running the build on 32-bit Windows XP and the value returned by IntPtr.Size is 4 but the registry path where the installation directory is HKLM\SOFTWARE\Microsoft, not Wow6432Node.

Re: Get error building on Windows XP

Posted: Thu Nov 15, 2018 5:29 am
by fenice
You should file a bug report in github.

Re: Get error building on Windows XP

Posted: Tue Dec 11, 2018 1:42 am
by thisjun
I suspect a cause is 'bin' of the following message.
Executing 'bin\rc.exe "C:\Documents and Settings\Linus Hicks\Local
But I didn't ensure it.