I have successfully configured OpenSSL for building, but when I run nmake I get this:
c:\Development\Qt\5\OpenSSL>nmake -f ms\ntdll.mak test
Microsoft (R) Program Maintenance Utility Version 10.00.30319.01
Copyright (C) Microsoft Corporation. All rights reserved.
cl /Fotmp32dll\md4test.obj -Iinc32 -Itmp32dll /MD /Ox /O2 /Ob2 -DOPENSSL_THREADS -DDSO_WIN32
-W3 -Gs0 -GF -Gy -nologo -DOPENSSL_SYSNAME_WIN32 -DWIN32_LEAN_AND_MEAN -DL_ENDIAN -D_CRT_SECURE_NO_DEPRECATE
-DOPENSSL_USE_APPLINK -I. -DOPENSSL_NO_RC5 -DOPENSSL_NO_MD2 -DOPENSSL_NO_KRB5 -DOPENSSL_NO_JPAKE
-DOPENSSL_NO_STATIC_ENGINE /Zi /Fdtmp32dll/app -c .\crypto\md4\md4test.c
.\crypto\md4\md4test.c : fatal error C1033: cannot open program database 'c:\development\qt\5\openssl\tmp32dll\app.pdb'
NMAKE : fatal error U1077: '"c:\Program Files (x86)\Microsoft Visual Studio 10.0\VC\BIN\cl.EXE"' : return code '0x2'
Stop.
Advices appreciated.
This usually happens when some other application is trying access the file at the same time. For me, it was Dropbox. So, I had to disable the sync.
Another program which accesses the PDB files during compilation is mspdbsrv.exe. This program is started automatically by the build process. Kill it, and remove all the files in tmp32dll folder. It may have been left over from the previous build attempts.
Hope that helps!
I've had this error when I accidentally built with "ms\nt.mak", but then tried to test with "ms\ntdll.mak". Make sure you build and test with the same make file.
Related
I'm working with Intel Pin on a Windows 7 machine. As suggested on Pin user guide, I downloaded Cygwin with the packages I need, such as gcc, g++ and make, but when I try to execute the command "make" in order to build one tool (Insmix in this case, but it is the same with any other Pin tool) I get the following error:
make[1]: Entering directory '/cygdrive/c/Users/IEUser/Downloads/pin-3.2-81205-msvc-windows/source/tools/Insmix'
cl /MT /EHs- /EHa- /wd4530 /DTARGET_WINDOWS /DBIGARRAY_MULTIPLIER=1 /nologo /Gy /Oi- /GR- /GS- /D__PIN__=1 /DPIN_CRT=1 /D_WINDOWS_H_PATH_="" /D__i386__ /DTARGET_IA32 /DHOST_IA32 /I../../../source/include/pin /I../../../source/include/pin/gen -I../../../extras/stlport/include -I../../../extras -I../../../extras/libstdc++/include -I../../../extras/crt/include -I../../../extras/crt -I../../../extras/crt/include/arch-x86 -I../../../extras/crt/include/kernel/uapi -I../../../extras/crt/include/kernel/uapi/asm-x86 /FIinclude/msvc_compat.h /I../../../extras/components/include /I../../../extras/xed-ia32/include/xed /I../../../source/tools/InstLib /O2 /c /Foobj-ia32/insmix.obj insmix.cpp
**/bin/sh: cl: command not found**
make[1]: *** [../../../source/tools/Config/makefile.default.rules:192: obj-ia32/insmix.obj] Error 127
I tried to Google it with no success. Does anyone know how to fix this issue?
Thank you very much for you help
cl is prettymuch a Microsoft tool. Install some Visual Studio version, and you'll have that cl tool somewhere in the bin directory in C:\Program Files\Microsoft Visual Studio\...\bin\ Now you set that directory in the environment Path variable. Voila. That works.
I've used the answer here with success on previous installations but hitting a roadblock this time: How to install SIP & PyQT on windows 7
I get an error on the nmake step (see below):
C:\source>cd sip-4.19.9
C:\source\sip-4.19.9>python configure.py
This is SIP 4.19.9.dev1804161501 for Python 2.7.14 on win32.
The SIP code generator will be installed in c:\python27.
The sip module will be installed in c:\python27\Lib\site-packages.
The sip.pyi stub file will be installed in c:\python27\Lib\site-packages.
The sip.h header file will be installed in c:\python27\include.
The default directory to install .sip files in is c:\python27\sip.
Creating siplib\sip.h...
Creating siplib\siplib.c...
Creating siplib\siplib.sbf...
Creating sipconfig.py...
Creating top level Makefile...
Creating sip code generator Makefile...
Creating sip module Makefile...
C:\source\sip-4.19.9>"C:\Qt\5.10.0\msvc2015\bin\qtenv2.bat"
Setting up environment for Qt usage...
Remember to call vcvarsall.bat to complete environment setup!
C:\Qt\5.10.0\msvc2015>"C:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\vcvarsall.bat"
C:\Qt\5.10.0\msvc2015>cd \source\sip-4.19.9
C:\source\sip-4.19.9>nmake
Microsoft (R) Program Maintenance Utility Version 14.00.24234.1
Copyright (C) Microsoft Corporation. All rights reserved.
cd sipgen
"C:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\BIN\nmake.exe"
Microsoft (R) Program Maintenance Utility Version 14.00.24234.1
Copyright (C) Microsoft Corporation. All rights reserved.
cd siplib
"C:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\BIN\nmake.exe"
Microsoft (R) Program Maintenance Utility Version 14.00.24234.1
Copyright (C) Microsoft Corporation. All rights reserved.
cl -c -nologo -Zm200 -Zc:wchar_t- -O2 -MD -W3 -DNDEBUG -DUNICODE -DWIN32 -DQT_LARGEFILE_SUPPORT -I. -Ic:\python27\include -Fo #C:\Users\suzanne\AppData\Local\Temp\nmB36B.tmp
siplib.c
apiversions.c
descriptors.c
qtlib.c
threads.c
objmap.c
voidptr.c
array.c
int_convertors.c
Generating Code...
cl -c -nologo -Zm200 -Zc:wchar_t- -O2 -MD -W3 -w34100 -w34189 -DNDEBUG -DUNICODE -DWIN32 -DQT_LARGEFILE_SUPPORT -I. -Ic:\python27\include -Fo #C:\Users\suzanne\AppData\Local\Temp\nmB8AB.tmp
bool.cpp
link /NOLOGO /DYNAMICBASE /NXCOMPAT /DLL /MANIFEST /MANIFESTFILE:sip.pyd.manifest /SUBSYSTEM:CONSOLE /INCREMENTAL:NO /OUT:sip.pyd #C:\Users\suzanne\AppData\Local\Temp\nmB939.tmp
Creating library sip.lib and object sip.exp
mt -nologo -manifest sip.pyd.manifest -outputresource:sip.pyd;2
'mt' is not recognized as an internal or external command,
operable program or batch file.
NMAKE : fatal error U1077: 'mt' : return code '0x1'
Stop.
NMAKE : fatal error U1077: '"C:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\BIN\nmake.exe"' : return code '0x2'
Stop.
Figured it out...
mt.exe part of Visual Studio's Windows SDK, which wasn't installed. Went back and installed it through Get Tools and Features.
Then found \x86\mt.exe and added it to path.
I'm trying to install Google OR-Tools for Java in Visual Studio 2015. When I run make all in the OR-Tools directory, as required, I get
E:\My_files\VS\BC\or-tools_VisualStudio2015-64bit_v6.4.4495>make all
cl /EHsc /MD /nologo /D_SILENCE_STDEXT_HASH_DEPRECATION_WARNINGS -nologo /O2 -DN
DEBUG -DUSE_CBC -DUSE_CLP /D__WIN32__ /Iinclude\\src\\windows
/DGFLAGS_DLL_DECL=
/DGFLAGS_DLL_DECLARE_FLAG= /DGFLAGS_DLL_DEFINE_FLAG= /Iinclude /I. -
DUSE_GLOP -
DUSE_BOP -c examples\\cpp\\costas_array.cc /Foobjs\\costas_array.obj
make: cl: Command not found
make: *** [objs\\costas_array.obj] Error 127
I read somewhere to run vcvarsall.bat to set variables, but there is no such file on this path
C:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\vcvarsall.bat
Plus I'm supposed to run it in Native Tools Command Prompt, but I cannot find this for VS2015, only for VS2017, so I run it in Developer Command Prompt. Might this be the issue?
Apparently, I did not add C++ tools when installing Visual Studio.
File -> New -> Project -> Visual C++ and there's the install option. Maybe it will help someone.
I've trying to compile libSVM on W10 with Visual Studio 2015 Enterprise compiler and I get this error.
I type nmake -f makefile.win
Microsoft (R) Program Maintenance Utility Version 14.00.24210.0
Copyright (C) Microsoft Corporation. All rights reserved.
cl.exe -nologo -O2 -EHsc -I. -D __WIN32__ -D _CRT_SECURE_NO_DEPRECATE -c timer.cpp
timer.cpp
timer.cpp(26): fatal error C1083: Cannot open include file: 'limits': No such file or directory
NMAKE : fatal error U1077: '"c:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\bin\cl.exe"' : return code '0x2'
Stop.
It seems some problem with visual studio installation?
I've think that was something related to the C++ Compiler.
The end result is I am trying to compile something that requires the APR from Apache on Windows.
Edit: Tried Visual Studio command line tools for VS2013 & VS2014.
Link for SVN checkout shows 404: http://apr.apache.org/anonsvn.txt
so...
From this link http://apr.apache.org/compiling_win32.html I have downloaded the three files. I unzipped them and renames them as the directory structure suggested.
C:\work\apr\
C:\work\apr-iconv\
C:\work\apr-util\
Moved to the apr-util directory and ran the following make command and received the following errors.
Note there is the comment about "Current versions of APR do not need awk..." but the link does not work, does it matter?
Anybody have any luck compiling this, do I need other lib/include/objects?
nmake -f Makefile.win buildall checkall installall clean
Received the following errors:
<clip>
rc.exe /l 0x409 /fo".\Release\libapriconv.res" /i "./include" /i "../apr/include" /d "NDEBUG" /d "API_VERSION_ONLY" .\libapriconv.rc
Microsoft (R) Windows (R) Resource Compiler Version 6.3.9600.17336
Copyright (C) Microsoft Corporation. All rights reserved.
link.exe #C:\Users\JOHNAT~1\AppData\Local\Temp\nm390A.tmp
Creating library .\Release\libapriconv-1.lib and object .\Release\libapriconv-1.exp
if exist .\Release\libapriconv-1.dll.manifest mt.exe -manifest .\Release\libapriconv-1.dll.manifest -outputresource:.\Release\libapriconv-1.dll;2
echo Helper for Post-build step > ".\Release\postbld.dep"
cd ccs
"C:\Program Files (x86)\Microsoft Visual Studio 12.0\VC\BIN\nmake.exe" -nologo -f Makefile.win all BUILD_MODE="Win32 Release" BIND_MODE=shared adobe-stdenc.c
Creating library ..\Release\iconv\adobe-stdenc.lib and object ..\Release\iconv\adobe-stdenc.exp
adobe-stdenc.obj : error LNK2011: precompiled object not linked in; image may not run
..\Release\iconv\adobe-stdenc.so : fatal error LNK1120: 1 unresolved externals
NMAKE : fatal error U1077: '"C:\Program Files (x86)\Microsoft Visual Studio 12.0\VC\BIN\link.EXE"' : return code '0x460'
Stop.
NMAKE : fatal error U1077: '"C:\Program Files (x86)\Microsoft Visual Studio 12.0\VC\BIN\nmake.exe"' : return code '0x2'
Stop.
It's a little late, but here is how I fixed it.
In the build\modules.mk.win makefile change line 221 from
$(SILENT)link $(ALL_LDFLAGS) $*.obj $(API_LIBS) /out:$# \
To
$(SILENT)link $(ALL_LDFLAGS) $*.obj $(MODRES).obj $(API_LIBS) /out:$# \
The shared library target will now read:
.c{$(OUTPUT_DIR)}.so:
$(SILENT)cl $(ALL_CFLAGS) /Fo$*.obj /Yuiconv.h /c $<
$(SILENT)link $(ALL_LDFLAGS) $*.obj $(MODRES).obj $(API_LIBS) /out:$# \
/base:#"..\build\BaseAddr.ref",$(#F)
$(SILENT)if exist $#.manifest \
$(SILENT)mt -nologo -manifest $#.manifest -outputresource:$#;2 \
& del "$#.manifest"
$(SILENT)del "$*.exp" & del "$*.lib"
Source: https://gist.github.com/mkhon/01a1536b01e0065ae799
From the apache-apr project site under heading:
Developer Studio Workspace/Microsoft Development Environment IDE Build::
Open the apr-util/aprutil.dsw workspace, and choose either aprutil or libaprutil (for static or dynamic libraries) with the Release or Debug build as the Active Project. aprutil.dsw causes all related projects to be built.
Maybe you overlooked this statement : choose either aprutil or libaprutil as the Active Project...
Then build the active project.