[Cmake] Problem discovering kernel32.lib
William A. Hoffman
billlist at nycap.rr.com
Thu, 08 Apr 2004 11:49:53 -0400
If you are using the nmake generator, it looks like you have not
set all the variables required to run cl from the command line.
There is a script called vcvars32.bat that must be run, or
at least examined to see the variables required.
This posting may help:
http://www.cmake.org/pipermail/cmake/2004-January/004687.html
Most likely you set the path, but did not set the LIB variable.
If you use the IDE generator you should not have this problem.
-Bill
At 11:35 AM 4/8/2004, ibiris at genius.org.br wrote:
>Hi,
>
>I am trying CMake in a newly built machine, properly populated with Visual
>Studio and with all paths set to contain bin and lib directories for Visual
>Studio development. I am still picking up the following error when trying
>to run cmake
>
>----------------------------------------------------------------------------------------------
>Determining if the C compiler works failed with the following output:
>Building object file testCCompiler.obj...
>
> cl at C:\DOCUME~1\ibiris\CONFIG~1\Temp\nma01436.
>
>testCCompiler.c
>
>Building executable
>C:\Projects\PROJECT-TEST\build\CMakeTmp\cmTryCompileExec.exe...
>
> cl /nologo at C:\DOCUME~1\ibiris\CONFIG~1\Temp\nmb01436.
>
>LINK : fatal error LNK1104: cannot open file "kernel32.lib"
>
>NMAKE : fatal error U1077: 'cl' : return code '0x2'
>
>Stop.
>
>----------------------------------------------------------------------------------------------
>
>I am not sure why it cannot find kernel32, once the path for this lib is
>included in the %PATH% variable, and the machine has been tested with
>Visual Studio compilation. The only thing different is that kernel32.lib
>appears under windows explorer as KERNEL32.LIB
>
>Same error appears when running the cmake GUI on windows. This is CMake
>1.8.3
>
>Has anyone come across this problem before? All help will be greatfully
>appreciated.
>
>----
>Ilias Biris, Ph.D.
>Senior Researcher
>Genius Instituto de Tecnologia
>TEL: +55 (0)92 6146503
>FAX: +55 (0)92 6133144
>http://www.genius.org.br/
>**************************************************************************************************
>
>O conteúdo desse e-mail ou de seus anexos são confidenciais e restritos ao
>destinatário da mensagem.
>Se você recebeu esse e-mail por engano, por favor notifique o remetente
>imediatamente e não faça cópias ou distribua seu conteúdo para ninguém.
>
>**************************************************************************************************
>
>The contents of this email and any attachments are confidential.
>They are intended for the named recipient(s) only.
>If you have received this email in error please notify the system manager or the
>sender immediately and do not disclose the contents to anyone or make copies.
>
>**************************************************************************************************
>_______________________________________________
>Cmake mailing list
>Cmake at www.cmake.org
>http://www.cmake.org/mailman/listinfo/cmake