Jump to content











Photo
- - - - -

devio.exe build error

devio.exe build error

  • Please log in to reply
4 replies to this topic

#1 527104427

527104427
  • Members
  • 3 posts
  •  
    China

Posted 04 June 2016 - 12:57 PM

WARNING: x64 Native compiling isn't supported. Using cross compilers.
OACR monitor running already

D:\WinDDK\7600.16385.1>cd /d F:\doc\desktop\imdisk\devio

F:\doc\desktop\imdisk\devio>nmake /f makefile.win64

Microsoft ® Program Maintenance Utility Version 9.00.30729.207
Copyright © Microsoft Corporation.  All rights reserved.

        cl /c /WX /W4 /wd4201 /wd4204 /wd4996 /Ox /GR- /MD /Fox64\devio.obj /nol
ogo devio.c
devio.c
devio.c(40) : fatal error C1083: Cannot open include file: 'stdio.h': No such fi
le or directory
NMAKE : fatal error U1077: 'D:\WinDDK\7600.16385.1\bin\x86\amd64\cl.EXE' : retur
n code '0x2'
Stop.

F:\doc\desktop\imdisk\devio>



#2 Olof Lagerkvist

Olof Lagerkvist

    Gold Member

  • Developer
  • 1338 posts
  • Location:Borås, Sweden
  •  
    Sweden

Posted 04 June 2016 - 02:53 PM

Unfortunately WDK build environments are not supported for building devio.exe.

 

Install any Visual Studio 2008-2015 edition with VC++ compilers and open Visual Studio Command Prompt for x64 compilations. Windows 7: Start menu > Visual Studio ... > Visual Studio ... x64 Command Prompt. Windows 8/8.1/10: Start screen > All apps > Under Visual Studio ... > Visual Studio ... x64 Command Prompt.

 

Navigate to devio source directory. Type nmake /f Makefile.win64

 

Hope that helps!



#3 527104427

527104427
  • Members
  • 3 posts
  •  
    China

Posted 04 June 2016 - 05:37 PM

Unfortunately WDK build environments are not supported for building devio.exe.

 

Install any Visual Studio 2008-2015 edition with VC++ compilers and open Visual Studio Command Prompt for x64 compilations. Windows 7: Start menu > Visual Studio ... > Visual Studio ... x64 Command Prompt. Windows 8/8.1/10: Start screen > All apps > Under Visual Studio ... > Visual Studio ... x64 Command Prompt.

 

Navigate to devio source directory. Type nmake /f Makefile.win64

 

Hope that helps!

 

 

Still unable to compile,Maybe I need more help:

 

Setting environment for using Microsoft Visual Studio 2010 x64 tools.

D:\Microsoft Visual Studio 10.0\VC>cd /d F:\doc\desktop\imdisk\devio

F:\doc\desktop\imdisk\devio>nmake /f makefile.win64

Microsoft ® 程序维护实用工具 10.00.30319.01 版
版权所有© Microsoft Corporation。保留所有权利。

        cl /c /WX /W4 /wd4201 /wd4204 /wd4996 /Ox /GR- /MD /Fox64\devio.obj /nol
ogo devio.c
devio.c
        cl /c /WX /W4 /wd4201 /wd4204 /wd4996 /Ox /GR- /MD /Fox64\safeio_win32.o
bj /nologo safeio_win32.cpp
safeio_win32.cpp
        link /opt:nowin98,ref,icf=10 /largeaddressaware /defaultlib:bufferoverfl
owU.lib /release /nologo /out:x64\devio.exe x64\devio.obj x64\safeio_win32.obj
LINK : fatal error LNK1117: 选项“opt:nowin98,ref,icf=10”中的语法错误
NMAKE : fatal error U1077: “"D:\Microsoft Visual Studio 10.0\VC\BIN\amd64\link.
EXE"”: 返回代码“0x45d”
Stop.

F:\doc\desktop\imdisk\devio>



#4 Olof Lagerkvist

Olof Lagerkvist

    Gold Member

  • Developer
  • 1338 posts
  • Location:Borås, Sweden
  •  
    Sweden

Posted 04 June 2016 - 05:57 PM

Ah, I guess there might be some compatibility problems with later versions of VC++ with this Makefile. You could try to build from inside Visual Studio as well if you like. There is a devio.vcxproj file that you could open in Visual Studio.

 

Otherwise to build from command line anyway you could try this and see if that helps:

 

Edit Makefile.win64 in Notepad or similar. Remove nowin98, and /defaultlib:bufferoverflowU.lib from the last line. That is, change the last line:

        link /opt:nowin98,ref,icf=10 /largeaddressaware /defaultlib:bufferoverflowU.lib /release /debug /nologo /out:x64\devio.exe x64\devio.obj x64\safeio_win32.obj

to

       link /opt:ref,icf=10 /largeaddressaware /release /debug /nologo /out:x64\devio.exe x64\devio.obj x64\safeio_win32.obj

 

(Notice that there should be a tab character at the beginning of the line, not spaces. Otherwise nmake would not accept it as a command line.)



#5 527104427

527104427
  • Members
  • 3 posts
  •  
    China

Posted 04 June 2016 - 11:17 PM

Ah, I guess there might be some compatibility problems with later versions of VC++ with this Makefile. You could try to build from inside Visual Studio as well if you like. There is a devio.vcxproj file that you could open in Visual Studio.

 

Otherwise to build from command line anyway you could try this and see if that helps:

 

Edit Makefile.win64 in Notepad or similar. Remove nowin98, and /defaultlib:bufferoverflowU.lib from the last line. That is, change the last line:

        link /opt:nowin98,ref,icf=10 /largeaddressaware /defaultlib:bufferoverflowU.lib /release /debug /nologo /out:x64\devio.exe x64\devio.obj x64\safeio_win32.obj

to

       link /opt:ref,icf=10 /largeaddressaware /release /debug /nologo /out:x64\devio.exe x64\devio.obj x64\safeio_win32.obj

(Notice that there should be a tab character at the beginning of the line, not spaces. Otherwise nmake would not accept it as a command line.)

 

 

Thank you so much.  compiled successfully


  • Olof Lagerkvist likes this




0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users