Thanks for the reply. Rob

You are right that it is not a inline-specific problem. When I install other
modules from CPAN (like Math::FFT), it reported the missing of file
sys/types.h.

Actually I tried to get these headers files by installing Microsoft SDKs. I
installed a windows SDK which put the file windows.h in C:/program
files/Microsoft SDK/windows/v7.0/include, and I installed the visual studio
2010 express kit, which put the file types.h in C:/program files/microsoft
visual studio 9.0/VC/include/sys. 

So the problem is that compile couldn't find the files. How to set it up? I
tried to run vcvars32.bat (from C:/program files/microsoft visual studio
9.0/VC/bin). It added the corresponding /bin folder in PATH,which fixed the
an earlier error that "cl.exe"/"nmake.exe" couldn't be found. But the
problem of missing header files persisted. 

How to make the compiler to recognize the header file paths? 

Bilogical 

-----邮件原件-----
发件人: Sisyphus [mailto:sisyph...@optusnet.com.au] 
发送时间: 2011年1月12日 19:05
收件人: Guohong Hu; inline@perl.org
主题: Re: running inline in win7


----- Original Message ----- 
From: "Guohong Hu" <hu.guoh...@gmail.com>
To: <inline@perl.org>
Sent: Wednesday, January 12, 2011 9:41 PM
Subject: running inline in win7


> Hi, recently I re-installed my system and switched to win7, so had to
> re-install many of the perl modules, including inline. The installation 
> went
> fine,

Given that windows.h cannot be found, I would expect that the 'make test' 
step would have produced numerous failures (for precisely that reason).

> but when I ran scripts with inline, it always returned an error saying
> "c:\programs\perl\lib\core\win32.h(61) : fatal error C1083: Cannot open
> include file: 'windows.h': No such file or directory".

You're missing 'windows.h'. With later Microsoft Compilers, I think this 
file is included in the SDK which, I think, might be an additional download 
that you have to do if you're using a freely available version of MSVC++.

I'm not really up to speed with Microsoft Compilers - all I know is that, 
with my MSVC++ 7.0, 'windows.h' is in the Vc7\PlatformSDK\Include folder. 
Search your entire Visual Studio for the file 'windows.h' - if it's not 
there then you certainly need to download the SDK for that particular 
compiler.

You should also strike a similar error whenever you currently build *any* 
perl extension - eg try Math::FFT from CPAN. That is, it's not only 
Inline::C that suffers from this missing file.

Cheers,
Rob 

Reply via email to