X-Recipient: archive-cygwin AT delorie DOT com DomainKey-Signature: a=rsa-sha1; c=nofws; d=sourceware.org; h=list-id :list-unsubscribe:list-subscribe:list-archive:list-post :list-help:sender:message-id:date:from:mime-version:to:subject :references:in-reply-to:content-type:content-transfer-encoding; q=dns; s=default; b=wfj911dtii4/kDRk5abDktQGilkD1jyS5/K1UKthWAG 4OrdwQN1e6eG5E33N6LhVGZEjSdE8Tbarq/Y0bLaG8wEql7Pjp4SjLUlU08W9pni VTFIYKkOavDfVswjtDHqVcNGEa0V+MAaVsHwd0FTXJ3a0E3g5vTZT4XUZ8zxraJ0 = DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=sourceware.org; h=list-id :list-unsubscribe:list-subscribe:list-archive:list-post :list-help:sender:message-id:date:from:mime-version:to:subject :references:in-reply-to:content-type:content-transfer-encoding; s=default; bh=IlZkfqO3sl/l+n5JcnXZC2hBPSU=; b=xg5BnKLZZcK4D2lZd E2bMv3959GcwEbPAF7chQmm8rz1p/cLi81kNhX8bH4QUDM6yZfK+z9JHIqu1Ysbc HQ+uDHRjMWwj6y8M/fSd1nVxv+E5beKdIKSupnTjteqrQFs63jQXGDxlWD5JeCYR RMcbwihk6W0yeCuoomuC2ef+1g= Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: cygwin-owner AT cygwin DOT com Mail-Followup-To: cygwin AT cygwin DOT com Delivered-To: mailing list cygwin AT cygwin DOT com Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-2.6 required=5.0 tests=BAYES_00,FREEMAIL_FROM,RCVD_IN_DNSWL_LOW,SPF_PASS autolearn=ham version=3.3.2 X-HELO: mail-oa0-f49.google.com X-Received: by 10.182.44.167 with SMTP id f7mr17063570obm.3.1382044746820; Thu, 17 Oct 2013 14:19:06 -0700 (PDT) Message-ID: <52605448.4040601@gmail.com> Date: Thu, 17 Oct 2013 23:19:04 +0200 From: marco atzeri User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:24.0) Gecko/20100101 Thunderbird/24.0.1 MIME-Version: 1.0 To: cygwin AT cygwin DOT com Subject: Re: Linking to static libraries, e.g. gsl and hdf5 References: <20131018000238 DOT Horde DOT UZElabVgHsspuAWl7bQU_w7 DOT jzlehtol AT webmail DOT helsinki DOT fi> In-Reply-To: <20131018000238.Horde.UZElabVgHsspuAWl7bQU_w7.jzlehtol@webmail.helsinki.fi> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-IsSubscribed: yes Il 10/17/2013 11:02 PM, Susi Lehtola ha scritto: > Hi, > > > it seems that linking to some static libraries has broken down since the > last time I tried to recompile my project (in April). Now the linking > commands fail, e.g. > > /usr/bin/g++.exe -Wall -O2 -funroll-loops -mtune=generic -msse2 -static > -fopenmp program.cpp -lgsl -lgslcblas -llapack -lblas -lgfortran > > results in > > /usr/lib/gcc/i686-pc-cygwin/4.7.3/../../../../i686-pc-cygwin/bin/ld: > cannot find -lgsl > /usr/lib/gcc/i686-pc-cygwin/4.7.3/../../../../i686-pc-cygwin/bin/ld: > cannot find -lgslcblas > > I also get the same error when linking to -lhdf5. > > Having had a look at /usr/lib, I noticed that a lot of the libraries > follow the *nix convention > of the static libraries being named libfoo.a, while others have names of > the type libfoo.dll.a. > Indeed, the latter was true for the GSL and the HDF5 libraries, and > symlinking > > /usr/lib/libgsl.a -> /usr/lib/libgsl.dll.a > /usr/lib/libgslcblas.a -> /usr/lib/libgslcblas.dll.a > /usr/lib/libhdf5.a -> /usr/lib/libhdf5.dll.a > > solved the problem. > > Why is this not done in the gsl and hdf5 packages? Other packages might > also be affected. /usr/lib/libhdf5.dll.a is the dynamic library so the workaround is a contradiction of your target " Linking to static libraries" -- Problem reports: http://cygwin.com/problems.html FAQ: http://cygwin.com/faq/ Documentation: http://cygwin.com/docs.html Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple