[LLVMdev] llvm-ranlib: Bus Error in regressions + fix

Jeff Cohen jeffc at jolt-lang.org
Thu Nov 24 05:32:54 PST 2005


Evan Jones wrote:

> On Nov 23, 2005, at 22:49, Jeff Cohen wrote:
>
>> News to me.  I do it all the time.  Notice the "win32" directory 
>> under the root :)
>
>
> Okay, so I spoke about something that I don't really know about, since 
> I don't use Windows. But what was the whole "Still can't compile 
> backend of frontend on Windows" discussion about? My impression is 
> that LLVM only builds under Cygwin. This doesn't really count (IMO) 
> since it makes Windows look like Unix anyway, from an API perspective.

No, it builds using Microsoft's Visual C++.  In fact, there have been 
more problems building it with cygwin than with Visual Studio.  The 
project and solution files for Visual Studio are all under the win32 
directory.  It uses the native Win32 API (see lib/System/Win32).  The 
entire backend, except for a (very) few tools, builds natively.  The 
front end cannot build this way because it's a hacked-up GCC, which is 
well known for being unbuildable with VC++.  But that isn't really 
LLVM's problem; we can just distribute a pre-built llvm-gcc binary 
compiled with cygwin or mingw.  Anyway, the usefulness of LLVM is not 
limited to compiling C/C++ code.

> In fact, with regards to the specific "cannot unlink while open" 
> issue, Cygwin works around it (partially) by removing the file as soon 
> as the file is closed. I'm not sure that would be sufficient in this 
> case, but it might be.

Cygwin isn't involved, so this is irrelevant.  Windows does permit a 
file to be deleted while it is still open, but only when it was opened 
with delete share permission.  This requires that the file be opened 
with the CreateFile API, which LLVM cannot do in a portable fashion.  
This functionality cannot be accessed via fopen.

>
> Evan Jones
>
> -- 
> Evan Jones
> http://evanjones.ca/
>
> _______________________________________________
> LLVM Developers mailing list
> LLVMdev at cs.uiuc.edu         http://llvm.cs.uiuc.edu
> http://lists.cs.uiuc.edu/mailman/listinfo/llvmdev
>
>
>




More information about the llvm-dev mailing list