warning: shared library text segment is not shareable
error: treating warnings as errors

近期在调试一个Gsensor, 代码是从android4.2上直接移植过来的。但却一直编译只是, 纳闷了。。。
 baidu不行
 google 又訪问不了,真是操蛋

可是终究还是找到了点实用的信息,说是编译器的选项要加上 --no-fatal-warnings
  可无论怎么加, 加到那儿都变成了g++的选项,可g++不认得它。郁闷 了一会
  看了看链接器的链接选项中看到了例如以下两个选项
 --warn-shared-textrel       Warn if text segment is not shareable
 --no-warn-shared-textrel    Do not warn if text segment is not shareable (default)
由此猜測一空是默认加入了 --warn-shared-textrel

所以打一此处直接去掉就OK了, 详细例如以下:
diff --git a/android/build/core/combo/TARGET_linux-arm.mk b/android/build/core/combo/TARGET_linux-arm.mk
index 5ff30fa..accc3ff 100755
--- a/android/build/core/combo/TARGET_linux-arm.mk
+++ b/android/build/core/combo/TARGET_linux-arm.mk
@@ -132,7 +132,6 @@ TARGET_GLOBAL_LDFLAGS += \
    -Wl,-z,noexecstack \
    -Wl,-z,relro \
    -Wl,-z,now \
-   -Wl,--warn-shared-textrel \
    -Wl,--fatal-warnings \
    -Wl,--icf=safe \
    $(arch_variant_ldflags)

warning: shared library text segment is not shareable的更多相关文章

  1. Linux Programe/Dynamic Shared Library Entry/Exit Point && Glibc Entry Point/Function

    目录 . 引言 . C/C++运行库 . 静态Glibc && 可执行文件 入口/终止函数 . 动态Glibc && 可执行文件 入口/终止函数 . 静态Glibc & ...

  2. eclipse报错:Failed to load the JNI shared library

    Eclipse运行时提示“Failed to load the JNI shared library /Java/jre6/bin/client/jvm.dll”的一个解决方案 因为 Eclipse ...

  3. Eclipse - Failed to load the JNI shared Library (JDK)

    When I try opening Eclipse, a pop-up dialog states: Failed to load the JNI shared library "C:/J ...

  4. 启动Eclipse 弹出"Failed to load the JNI shared library jvm.dll"错误

    启动Eclipse 弹出"Failed to load the JNI shared library jvm.dll"错误,如下 原因:eclipse的版本与jre或者jdk版本不 ...

  5. dynamic-link library shared library of functions and resources

    https://msdn.microsoft.com/en-us/library/1ez7dh12.aspx A dynamic-link library (DLL) is an executable ...

  6. Eclipse:启动时提示"Failed to load the JNI shared library"的解决方案

    今天打开Eclipse,弹出提示框"Failed to load the JNI shared library" 原因1:给定目录下jvm.dll不存在. 对策:(1)重新安装jr ...

  7. 64位操作系统弹出"Failed to load the JNI shared library “E:/2000/Java/JDK6/bin/..jre/bin/client/jvm.dll”

    64位操作系统弹出"Failed to load the JNI shared library /..jre/bin/client/jvm.dll”,最大的可能就是jdk的版本问题.去你的C ...

  8. Eclipse之Failed to load the JNI shared library”……\jvm.dll”的解决方案

    问题描述:java环境变量配置完全正确,但是运行eclipse时提示:Failed to load the JNI shared library " xxx\jva.dll" 原因 ...

  9. 启动 Eclipse 弹出“Failed to load the JNI shared library jvm.dll”错误的解决方法!&&在eclipse.ini中为eclipse指定jdk启动

    参考:http://blog.csdn.net/zyz511919766/article/details/7442633 http://blog.sina.com.cn/s/blog_028f0c1c ...

随机推荐

  1. Android Framework 其中A记录

    一个简短的引论 以往的研究太偏应用层的功能,实现了,原则上不进入非常理解,现在,研究人员framework该框架层. 创纪录的 1.下载源代码,文件夹例如以下: 2.Android系统的层次例如以下: ...

  2. 利用hibernate的session查询数据库,而且在jsp页面显示表内容的方法

    试过了非常多种方法都没有成功,最终让我找到了这样的方法! 首先在后台写代码: Transaction tx = session.beginTransaction(); List list = sess ...

  3. ECharts SSH+JQueryAjax+Json+JSP在数据库中的数据来填充ECharts在

    1导入包.设定SSH框架. 进口JQuery的JS包.<script src="JS/jquery-1.7.1.js"></script> 导入EChart ...

  4. ExtJS学习-----------Ext.Number,ExtJS对javascript中的Number的扩展

    关于ExtJS对javascript中的Number的扩展,能够參考其帮助文档,文档下载地址:http://download.csdn.net/detail/z1137730824/7748893 以 ...

  5. memcached 实验论文

    虽然在这个年龄段谈话memcached 它可能是一个有点晚,最为cached 在应用程序中redis 在之上,下面将谈谈自己的一些看法, 这个文件是不是memcached 理论描述,只写的实验数据和结 ...

  6. webpack打包avalon

    webpack打包avalon+oniui+jquery 随着avalon的发展壮大,我根据CSDN的统计数字,中国前端大概有1%的人在使用avalon了. avalon的最大优势是能兼容IE6,并且 ...

  7. RPG游戏学习——1.任务脚本系统

    [前言] 近期准备做个rpg小游戏,所以開始研究rpg的一些系统.rpg最核心的应该是任务脚本系统(其它脚本系统类似),在參考了非常多网上的资料后,简要总结例如以下. [脚本的触发运行] 一个脚本须要 ...

  8. j经常使用ava应用server

    什么是应用server它?它主要提供的执行环境的应用程序,为组件提供服务. 要了解更多关于,您可以查看我的博客:何为容器? Java 的应用server非常多,从功能上分为两类:WEB 应用serve ...

  9. 人活系列Streetlights (秩)

    人活着系列之Streetlights Time Limit: 1000MS Memory limit: 65536K 题目描写叙述 人活着假设是为了家庭,亲情----能够说是在这个世界上最温暖人心的, ...

  10. hdu1115(重力算法的多边形中心)

    标题的含义: 给定一个n刚n顶点.这是获得n分众协调多边形. http://acm.hdu.edu.cn/showproblem.php? pid=1115 题目分析: /** *出处:http:// ...