Cygwin patches for 2.7

Hi,

Here are two patches to allow Cygwin to build. ‘edis’ is disabled as it will not build with dynamic libraries, and libprofile also does not build on Cygwin. If anyone using Cygwin wants there functionality they will have to fix them :slight_smile:

Aaron

Index: tools/Makefile

Cygwin-2.7.patch (818 Bytes)

Here are two patches to allow Cygwin to build. 'edis' is disabled as it will
not build with dynamic libraries, and libprofile also does not build on
Cygwin. If anyone using Cygwin wants there functionality they will have to
fix them :slight_smile:

I think, it will be much better to have something like
"have_dynamic_linking" variable inside make harness and use it
accordingly....

Hi,

Here are two patches to allow Cygwin to build. 'edis' is disabled as it will not build with dynamic libraries, and libprofile also does not build on Cygwin. If anyone using Cygwin wants there functionality they will have to fix them :slight_smile:

I applied your patch for runtime, and applied a different patch to tools. Thanks.

-Chris

LLVM-GGC builds and installs okay using gcc-4.2.4 minimum. ‘make check’ runs okay too.

clang fails with a dynamic linking problem.

Aaron

What's the problem? and if you would please file a bug that would be awesome :slight_smile:

thanks!

-eric

Eric,

Neither Cygwin nor MinGW support Dynamic Linking. I am getting the following :-

llvm[4]: Compiling CIndexer.cpp for Debug build (PIC)
/home/ang/svn/llvm-clang/tools/clang/tools/CIndex/CIndexer.cpp: In member functi
on ‘const llvm::sys::Path& CIndexer::getClangPath()’:
/home/ang/svn/llvm-clang/tools/clang/tools/CIndex/CIndexer.cpp:64: error: ‘Dl_in
fo’ was not declared in this scope
/home/ang/svn/llvm-clang/tools/clang/tools/CIndex/CIndexer.cpp:64: error: expect
ed ;' before 'info' /home/ang/svn/llvm-clang/tools/clang/tools/CIndex/CIndexer.cpp:65: error: 'info' was not declared in this scope /home/ang/svn/llvm-clang/tools/clang/tools/CIndex/CIndexer.cpp:65: error: 'dladd r' was not declared in this scope /home/ang/svn/llvm-clang/tools/clang/tools/CIndex/CIndexer.cpp:68: error: 'info' was not declared in this scope make[4]: *** [/home/ang/build/llvm-clang/tools/clang/tools/CIndex/Debug/CIndexer .o] Error 1 make[4]: Leaving directory /home/ang/build/llvm-clang/tools/clang/tools/CIndex’

I am hoping I can just not build the indexer and will see if I can get a patch together first for 2.7 before submitting a bug report if I have to.

Aaron

Okay here’s a patch to no build the CIndexer on Cygwin and MinGW :-

Index: tools/Makefile

CygMinGW.patch (399 Bytes)

Hi Aaron, did you actually test that this patch fixes the problem you’re seeing?

-Chris

Yes, its been tested on Cygwin, and disables CIndex and its test on Cygwin and MinGW. CIndex makes programatic usage of DL_open so cannot be used on either platform. There maybe a better solution as I just hacked this to get Clang to build on Cygwin…

Aaron

I committed a fixed patch as r97892

-Chris