This is the mail archive of the gdb-patches@sourceware.org mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [rfc] testsuite/lib/gdb.exp: Enable additional linker flags in gdb_compile_shlib


Pedro Alves wrote:
On 5/16/07, Markus Deuling <deuling@xxx> wrote:
I try to build a shared library using gdb_compile_shlib. The build is done in two steps (compile and link).

The testcase I work on adds
  set lib_flags "$lib_flags additional_flags=-Wl,-Bsymbolic"
as an option to gdb_compile_shlib. The compile run quits with
  gcc: -Bsymbolic: linker input file unused because linking not done
because the linker option is given to the compile run, too.


I've seen something similar before. Did you try using ldflags instead? I think those will only be used when linking.

set lib_flags "$lib_flags ldflags=-Wl,-Bsymbolic"

Cheers,
Pedro Alves

Hi Pedro,

yes, it works with ldflags :-) Thank you very much. I withdraw the Patch.

Have a nice day!


-- Markus Deuling GNU Toolchain for Linux on Cell BE deuling@de.ibm.com


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]