[PATCH v1] LoongArch: Fix ld FAIL test cases

Xi Ruoyao xry111@xry111.site
Thu Jul 18 06:17:38 GMT 2024


On Thu, 2024-07-18 at 14:07 +0800, Lulu Cai wrote:
> FAIL: nopic link test readelf -s/-r nopic-global-so
> FAIL: nopic link test readelf -s/-x nopic-weak-global-so
> FAIL: nopic link exec test  #nopic-global
> FAIL: nopic link exec test  #nopic-weak-global
> 
> These FAILs were all found on LoongArch debian 12. There are two reasons.
> 
> The path of the C library is /usr/lib/'Architecture-related directories'
> on debian, which is not in the standard search path, so using -lc in
> test cases will result in the C library not being found. We need to add
> a specific search path for this.
> 
> The gcc on this system added the --as-needed option early in the link,
> so the specified library was not linked in. We disabled this option
> for the last two tests.

IMO we shouldn't try to support random changes performed by downstream
distros.  If they must do some random changes they should patch the test
suite on their own too.

-- 
Xi Ruoyao <xry111@xry111.site>
School of Aerospace Science and Technology, Xidian University


More information about the Binutils mailing list