If you followed my previous post http://linuxtortures.blogspot.com/2012/02/shared-libraries-with-eclipse.html
where I explained how to develop shared shared libraries there are a couple of extra steps that you must follow if you want to do the same onto a 84_64 system.

A. Download the appropriated version of eclipse from the official download page.

The package deployed for debian amd64 (Eclipse-CDT) does not work very well, so in this case the trick of adding the backports repository will not be useful.

B. Eclipse is java-based so you can just untar the file and execute the 'eclipse' file inside:

If you find difficulties when executing eclipse, or eclipse environment generates errors most probably there are dependencies that are not fulfilled. A non very elegant solution could be install the eclipse-cdt from the backports (It will automatically install all the needed dependencies) and then uninstall it. Then you can should be able to execute your 'manually' downloaded eclipse without issues.

C. Making and compiling Shared libraries:

Here there is a slight difference regarding the previous post. If you want to make a shared library compile within a 64 bits system you will need the 'Position Independent Code' (basically it will add the options '-fPIC'  to g++, otherwise you will receive a nice error like the following:

/usr/bin/ld: ./MyClass.o: relocation R_X86_64_32S against `vtable for MyClass' can not be used when making a shared object; recompile with -fPIC

Fortunately Eclipse allows us  to make this in a graphical way (Right click on the shared library --> Properties) and check the following check-box:

That should make the work. If you are very interested on this option you can find more information here:

http://www.technovelty.org/code/c/amd64-pic.html
Posted by Javier at 1:15 PM

Shared Libraries with Eclipse on 86_64 (64 bits) systems[z]的更多相关文章

  1. Ubuntu12.04安装64位系统出现编译错误error while loading shared libraries: libz.so.1: cannot open shared object file: No such file or dir

    问题: Ubuntu12.04安装64位系统出现编译错误error while loading shared libraries: libz.so.1: cannot open shared obje ...

  2. Position Independent Code (PIC) in shared libraries on x64

    E原文地址:http://eli.thegreenplace.net/2011/11/11/position-independent-code-pic-in-shared-libraries-on-x ...

  3. 让32位Eclipse和64位Eclipse同时在64的Windows7上运行

    转自让32位Eclipse和64位Eclipse同时在64的Windows7上运行 参考这篇文章:http://wenku.baidu.com/view/57994c270066f5335a81214 ...

  4. error while loading shared libraries: libevent-1.x.so.1

    安装完memcache后启动报错(error while loading shared libraries: libevent-1.x.so.1) 这是由于64位linux会去/usr/lib64目录 ...

  5. aapt: error while loading shared libraries: libstdc++.so.6: wrong ELF class: ELFCLASS64

    前阵子在ubuntu上搭载安卓的开发环境(Eclipse+Sdk+Adt),搭载是完成了,但是却出现了该问题: aapt: error while loading shared libraries: ...

  6. 编译Uboot时提示error while loading shared libraries: libz.so.1: cannot open shared object file: No such file or directory

    在Ubuntu14.04 64位系统中已经安装了libc6:i386的库,编译Uboot时提示error while loading shared libraries: libz.so.1: cann ...

  7. 解决 Linux error while loading shared libraries: cannot open shared object file: No such file or directory

    安装最新版本Emqtt,参照官方文档安装后,执行报错: Linux error while loading shared libraries libsctp.so.1: cannot open sha ...

  8. Nginx启动错误:error while loading shared libraries: libpcre.so.1

    1 # /usr/local/nginx/sbin/nginx 2 /usr/local/nginx/sbin/nginx: error while loading shared libraries: ...

  9. 【转】linux中执行外部命令提示" error while loading shared libraries"时的解决办法

    今天在Centos下编译kapar 后执行时出错,老说: [root@dc01 ~]# kapar kapar: error while loading shared libraries: libsc ...

随机推荐

  1. 6款实用的硬盘、SSD固态硬盘、U盘、储存卡磁盘性能测试工具

    一.检测工具名称汇总 HDTune ATTO Disk Benchmark CrystalDiskMark AS SSD Benchmark Parkdale CrystalDiskInfo 二.各项 ...

  2. UVAlive5713 Qin Shi Huang's National Road System【次小生成树】【DP】

    LINK1 LINK2 题目大意 给你平面上的n个点 每个点有一个权值 让你求出一个生成树 可以选择一条边不花费代价 要最大化这条边两边端点的权值/剩下n-2条边的长度之和 思路 发现发现其实端点权值 ...

  3. windows server 2012 AD 域和站点部署系列

    http://blog.csdn.net/ronsarah/article/category/1495599 http://blog.csdn.net/david_520042/article/cat ...

  4. linux(centOs)下memcached安装

    1.libevent安装.为啥先安装它?因为不先装,memcached这座房子就没打地基: yum install libevent-devel 敲回车后出现: Loaded plugins: fas ...

  5. [转]Web前端浏览器兼容

    转自: http://www.admin10000.com/document/1900.html 前言 浏览器兼容是前端开发人员必须掌握的一个技能,但是初入前端的同学或者其他后台web开发同学往往容易 ...

  6. MU-MIMO学习

    设备的认证查询 https://www.wi-fi.org/product-finder 1. MU-MIMO不会增大无线的最大速度 2. MU-MIMO需要路由器和客户端同时支持 3. 当你没有或者 ...

  7. 十二.jQuery源码解析之.eq().first().last().slice()

    eq(index):将集合中的索引为index的元素提取出来. first():返回集合中的第一个元素. .last():防护集合中的最后一个元素. .slice(start[,end]):返回集合中 ...

  8. 九jQuery源码解析之.each()

    jQuery中存在两个each方法都是用于遍历的, 一个是对jQuery对象集合使用.each(),用于遍历这个集合; .each(function(index,element)) 还有一个是扩展jQ ...

  9. 6.1课堂笔记—DML(数据操作语言),DQL查询语句

    一.DML(数据操作语言) InnoDB MyISAM 支持事务 不支持事务 不支持全文索引 支持全文索引 支持外键约束 不支持 命令查看默认存储引擎 show variables like '%st ...

  10. [POJ] Financial Management

    Financial Management Time Limit: 1000MS   Memory Limit: 10000K Total Submissions: 182193   Accepted: ...