[cfarm-users] gcc230: Unable to use GDB on 64-bit mips executable
Pierre Muller
pierre at freepascal.org
Fri Jun 20 07:01:46 CEST 2025
Hi,
Le 17/06/2025 à 23:06, Andreas Schwab via cfarm-users a écrit :
> On Jun 17 2025, Paul H. Hargrove via cfarm-users wrote:
>
>> I've symlinked from my GDB install to /opt/cfarm/gdb-8.0.1.
>> However, Pierre reported that the symlink gave permission denied errors,
>> while direct access to the symlink target worked fine.
>> No clue what's up with that.
>
> It's a security feature (fs.protected_symlinks).
How is it then possible to share the newly generated gdb 16.3 64-bit binary
in /opt/cfarm if symbolic links are protected?
I did:
muller at cfarm230:/opt/cfarm$ ln -sf /home/muller/gnu-mips64
muller at cfarm230:/opt/cfarm$ ls -l ./gnu-mips64/bin/gdb
-rwxr-xr-x 1 muller muller 211647592 Jun 17 16:16 ./gnu-mips64/bin/gdb
muller at cfarm230:/opt/cfarm$ ./gnu-mips64/bin/gdb --version
GNU gdb (GDB) 16.3
Copyright (C) 2024 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.
muller at cfarm230:/opt/cfarm$ file ./gnu-mips64/bin/gdb
./gnu-mips64/bin/gdb: ELF 64-bit MSB pie executable, MIPS, MIPS64 rel2 version 1 (SYSV), dynamically linked, interpreter /lib64/ld.so.1, BuildID[sha1]=6d4c1a55ba943ea14da9eb300f2bd7b1327aa74c, for GNU/Linux 3.2.0, with debug_info, not stripped
But this will probably not work for others either because of this security feature.
Furthermore:
muller at cfarm230:/opt/cfarm$ ldd ./gnu-mips64/bin/gdb
linux-vdso.so.1 (0x000000fff52e0000)
libmpfr.so.6 => /home/muller/gnu-mips64/lib/libmpfr.so.6 (0x000000fff3153000)
libgmp.so.10 => /home/muller/gnu-mips64/lib/libgmp.so.10 (0x000000fff30c1000)
libdl.so.2 => /lib64/libdl.so.2 (0x000000fff309c000)
libstdc++.so.6 => /lib64/libstdc++.so.6 (0x000000fff2ebf000)
libm.so.6 => /lib64/libm.so.6 (0x000000fff2ddc000)
libgcc_s.so.1 => /lib64/libgcc_s.so.1 (0x000000fff2d79000)
libpthread.so.0 => /lib64/libpthread.so.0 (0x000000fff2d45000)
libc.so.6 => /lib64/libc.so.6 (0x000000fff2b7a000)
/lib64/ld.so.1 (0x000000fff52ab000)
I had to generate a 64-bit version of gmp and mpfr packages,
and if I try to install them into /opt/cfarm prefix,
they will be placed in /opt/cfarm/lib
which is wrong because this directory should problably only contain o32 ABI libraries...
Is there a 'proper' way to install a 64-bit n64 ABI library into /opt/cfarm?
Pierre
More information about the cfarm-users
mailing list