lmi
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [lmi] Locating gcc runtime dlls


From: Vadim Zeitlin
Subject: Re: [lmi] Locating gcc runtime dlls
Date: Tue, 30 May 2017 18:58:12 +0200

On Tue, 30 May 2017 16:08:10 +0000 Greg Chicares <address@hidden> wrote:

GC> Vadim--To distribute lmi to msw end users, we must include the compiler's
GC> runtime DLLs. Shouldn't there be a convenient and robust way to find them
GC> in a gcc installation, so that they can be copied for redistribution?

 Sorry, I don't know of any such way if it exists.

GC> AFAICT, the best I can do is to use '-print-libgcc-file-name' with debian,
GC> and look in /path/to/gcc/bin for the dlls with cygwin.

 Indeed, I don't see anything better. I had an idea of using cygcheck to
retrieve the path to the DLL after compiling a simple program using it, but
this looks quite fragile and is almost certainly not worth the trouble.


GC> 
---------8<--------8<--------8<--------8<--------8<--------8<--------8<-------
GC> diff --git a/msw_cygwin.make b/msw_cygwin.make
GC> index 052e143..aab2db0 100644
GC> --- a/msw_cygwin.make
GC> +++ b/msw_cygwin.make
GC> @@ -71,11 +71,11 @@ CXX     := $(gcc_bin_dir)$(host_prefix)g++
GC>  LD      := $(gcc_bin_dir)$(host_prefix)g++
GC>  RC      := $(gcc_bin_dir)$(host_prefix)windres
GC>  
GC> -# Identify run-time libraries for redistribution. See:
GC> -#   https://cygwin.com/ml/cygwin/2010-09/msg00553.html
GC> -# Of course manipulating an lmi user's $PATH is out of the question.
GC> +# Identify run-time libraries for redistribution. Perhaps gcc's
GC> +# '-print-sysroot' would be more suitable, but that option returns
GC> +# an empty string with mingw-w64 gcc-4.9.1 .
GC>  
GC> -compiler_sysroot := /MinGW_/i686-w64-mingw32/lib
GC> +compiler_sysroot := $(dir $(shell $(CXX) -print-libgcc-file-name))

 This isn't directly related to your question, but is it really correct to
call this directory "sysroot"? I could easily be wrong, but for me sysroot
would be the parent directory.

 Regards,
VZ


reply via email to

[Prev in Thread] Current Thread [Next in Thread]