[llvm-commits] Patch for compiling with Mingw/Cygwin

Alain Frisch alain at frisch.fr
Mon Jan 7 08:12:41 PST 2008


Hello,

The attached patch makes it possible to compile LLVM under Mingw/Cygwin 
(that is, with "gcc -mno-cygwin" under Cygwin). The only problem which I 
could not address with configure flags is that the tblgen tool expect 
Windows paths, whereas the build system uses Cygwin paths. The patch 
introduce a Gnu Make function SYSPATH which performs the translation if 
needed.

Ideally, the SYSPATH variable in Makefile.config should be set by the 
configure script when given a special option (the same option could also 
set the other needed options -- see below). As I didn't want to play 
with autoconf, the current solution requires an explicit argument to be 
passed to make for the compilation.

With the patch, I was able to compile with the following commands:

./configure --build=i686-pc-mingw32 CC="gcc -mno-cygwin" CXX="g++ 
-mno-cygwin" ac_cv_search_dlopen=no ac_cv_lib_dl_dlopen=no

make USE_CYGPATH=1


Alain
-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: diff
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20080107/0d7aff60/attachment.ksh>


More information about the llvm-commits mailing list