Ubuntu :relocation R_X86_64_32 against `.rodata‘ can not be used when making a PIE object;

简介: Ubuntu :relocation R_X86_64_32 against `.rodata‘ can not be used when making a PIE object;

relocation R_X86_64_32 against `.rodata’ can not be used when making a PIE object; recompile with -fPIE


今天用Makefile make几个可执行文件:


报了这么个错



意思是在编译成可执行程序时候(pie就是生成可执行程序,与pic有区别),.dodata不能用,让你重新编译。


但是再编译就会发现还是这个错误,其实是项目编译之前没有清理,直接


sudo make clean
sudo make


就OK了

相关文章
|
5月前
|
Ubuntu
Ubuntu22.04,AOSP编译报错: libncurses.so.5: cannot open shared object file: No such file
本文描述了在Ubuntu 22.04系统上编译AOSP时遇到的`libncurses.so.5`缺失错误,并提供了通过安装相应库解决该问题的步骤。
773 0
|
8月前
|
Ubuntu Linux
Ubuntu 报错:System has not been booted with systemd as init system (PID 1). Can‘t operate.
系统未使用 `systemd` 初始化导致错误。解决方法是通过 `apt` 安装。首先备份并更换`sources.list`,添加阿里云镜像源,然后更新源并以管理员权限运行 `apt-get install systemd -y` 和 `apt-get install systemctl -y` 安装所需组件。
3657 3
relocation R_X86_64_PC32 against symbol can not be used when making a shared object recompile with
relocation R_X86_64_PC32 against symbol can not be used when making a shared object recompile with
750 0
relocation R_X86_64_PC32 against symbol lua_newstate can not be used when making a shared object
relocation R_X86_64_PC32 against symbol lua_newstate can not be used when making a shared object
297 0
relocation R_X86_64_PC32 against symbol ff_pw_9 can not be used when making a shared object
relocation R_X86_64_PC32 against symbol ff_pw_9 can not be used when making a shared object
298 0
relocation R_X86_64_PC32 against symbol ff_pw_9 can not be used when making a shared object
relocation R_X86_64_PC32 against symbol ff_pw_9 can not be used when making a shared object
168 0
libgsm.a relocation R_X86_64_PC32 can not be used when making a shared object; recompile with -fPIC
libgsm.a relocation R_X86_64_PC32 can not be used when making a shared object; recompile with -fPIC
245 0
can not be used when making a shared object; recompile with -fPIC
can not be used when making a shared object; recompile with -fPIC
337 0
|
30天前
|
JSON Java Apache
Java基础-常用API-Object类
继承是面向对象编程的重要特性,允许从已有类派生新类。Java采用单继承机制,默认所有类继承自Object类。Object类提供了多个常用方法,如`clone()`用于复制对象,`equals()`判断对象是否相等,`hashCode()`计算哈希码,`toString()`返回对象的字符串表示,`wait()`、`notify()`和`notifyAll()`用于线程同步,`finalize()`在对象被垃圾回收时调用。掌握这些方法有助于更好地理解和使用Java中的对象行为。

热门文章

最新文章