GNU bug report logs - #57954
[PATCH] gnu: clapack: Use position-independent code for use as a library.

Previous Next

Package: guix-patches;

Reported by: Nicolas Graves <ngraves <at> ngraves.fr>

Date: Tue, 20 Sep 2022 12:42:02 UTC

Severity: normal

Tags: patch

Done: Nicolas Graves <ngraves <at> ngraves.fr>

Bug is archived. No further changes may be made.

Full log


Message #17 received at 57954 <at> debbugs.gnu.org (full text, mbox):

From: Maxime Devos <maximedevos <at> telenet.be>
To: Nicolas Graves <ngraves <at> ngraves.fr>, 57954 <at> debbugs.gnu.org
Subject: Re: [bug#57954] Some details about why and see if there is no other
 solution.
Date: Sat, 24 Sep 2022 11:46:36 +0200
[Message part 1 (text/plain, inline)]

On 24-09-2022 10:37, Nicolas Graves wrote:
> 
>>     * compile the static library as -fPIC (your patch)
>>     * let kaldi link to a shared clapack (which is -fPIC by default)
> 
>> Hence, my proposed (and untested) solution is to make 'kaldi' link to a
>> shared clapack.
> 
> Thanks Maxime for your quick answer.
> 
> Just to be sure of what that would imply (using the second answer here:
> https://stackoverflow.com/questions/2649735/how-to-link-static-library-into-dynamic-library-in-gcc):
> 
> 1) We keep the version of clapack patched for -fPIC.
> 2) I need to make a package providing a shared version of clapack based
> on this version of clapack compiled with -fPIC.
> 
> Also, my original patch is wrong, I'll send a corrected one once I
> understand the process.

That should do it AFAIK.

However, going by 
https://cmake.org/cmake/help/latest/variable/BUILD_SHARED_LIBS.html#variable:BUILD_SHARED_LIBS 
, you can ask CMake to do these steps instead.

Also, going by the descriptio of 'clapack': ‘"The CLAPACK library was 
built using a Fortran to C conversion utility
called f2c.  The entire Fortran 77 LAPACK library is run through f2c to 
obtain C code, and then modified to improve readability.  CLAPACK's goal 
is to provide LAPACK for someone who does not have access to a Fortran 
compiler.’

... it sounds like clapack could be replaced with lapack without any 
problems (and even removed), and our 'lapack' package already makes 
shared libraries, which seems like a simpler course of action.

Greetings,
Maxime
[OpenPGP_0x49E3EE22191725EE.asc (application/pgp-keys, attachment)]
[OpenPGP_signature (application/pgp-signature, attachment)]

This bug report was last modified 2 years and 237 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.