Re: Static library linking error

2022-05-10 Thread John Reiser
* Florian Weimer: * Richard Shaw: I added the following to the libmqttc library and verified -fPIC -pie is in the build flags[1] per the recommendation from the hardening page[2] but the error remains. Code that is linked into a shared object (with -shared) must be compiled as PIC, not PIE.

Re: Static library linking error

2022-05-10 Thread Florian Weimer
* Richard Shaw: > I added the following to the libmqttc library and verified -fPIC -pie > is in the build flags[1] per the recommendation from the hardening > page[2] but the error remains. Code that is linked into a shared object (with -shared) must be compiled as PIC, not PIE. Thanks, Florian

Re: Static library linking error

2022-05-10 Thread John Reiser
On 5/10/22 06:21 UTC, Mamoru TASAKA wrote: Richard Shaw wrote on 2022/05/10 12:07: I'm working on some IIoT related packages in my COPR where I have a dynamic library linking to a static library and getting the following error: /usr/bin/ld: /usr/lib/gcc/x86_64-redhat-linux/12/../../../../lib6

Re: Static library linking error

2022-05-09 Thread Mamoru TASAKA
Richard Shaw wrote on 2022/05/10 12:07: I'm working on some IIoT related packages in my COPR where I have a dynamic library linking to a static library and getting the following error: /usr/bin/ld: /usr/lib/gcc/x86_64-redhat-linux/12/../../../../lib64/libmqttc.a(mqtt.c.o): warning: relocation