Osgi导出的产品不能独立启动的问题之一的解决

现象:用eclipse的导出工具,生成一个产品目录,点击里面的执行文件,报错:

The xx executable launcher was unable to locate its companion shared library

国内网上搜了一下,都是eclipse自己启动时报这个错,基本上的解决方案如下:

修改Myeclipse.ini文件

1-startup 2../Common/plugins/org.eclipse.equinox.launcher_1.0.201.R35x_v20090715.jar 3--launcher.library 4../Common/plugins/org.eclipse.equinox.launcher.win32.win32.x86_1.0.200.v20090519 5-install 6D:/Program Files/Genuitec/MyEclipse-8.6 7-vm 8D:/ProgramFiles/Genuitec/Common/binary/com.sun.java.jdk.win32.x86_1.6.0.013/jre/bin/client/jvm.dll 9-configuration 10configuration 11-vmargs 12-Xmx512m 13-XX:MaxPermSize=256m 14-XX:ReservedCodeCacheSize=64m

不能解决独立osgi产品的运行问题,但是eclipse也是osgi框架,对比ini后发现,产品ini里没有“startup”的描述,判断是自动产生的配置里缺少一块儿,最后在一个老外的网页上看到一些解释,网址如下:

http://devblog.virtage.com/2012/09/equinox-launcher-error-the-xy-executable-launcher-was-unable-to-locate-its-companion-shared-library/

转帖文字如下:

Sometimes in your Eclipse RCP/Equinox based development you may encounter this error. In this short tip I will explain the reason of this error and it can be fixed.

equinox-launcher-unable-to-locate-its-companion-shared-library.png

Replace name of “plexflow-server” with “your-app”.

Small recap

Launcher is platform-specific part of Eclipse Equinox that eases launching OSGi Framework and provides more native feeling from starting Eclipse RCP or OSGi based applications to the end users.

Launching in native way is composed of three parts: native exacutable itself, platform specific library and Java launcher JAR.

You can read more about Equinox launcher in my previous post.

Why?

Native launcher cannot locate shared library. It is missing inplugins/folder or is not in folder (exploded) form so native launcher cannot load load it.

Make sure that your build app has this layout:

1+ your-app/ 2+--- your-app.exe 3+--+ plugins/ 4 +---- prg.eclipse.equinox.launcher_<os>.<ws>.<arch>_<version>/ 5 +--- eclipse_1502.so (Linux) OR 6 +--- eclipse_1503.dll (Win) OR 7 +--- eclipse_1503.so (Mac)

==========最终解决方案=======

把eclipse的plugins目录下的

org.eclipse.equinox.launcher.win32.win32.x86_64_1.1.200.v20130807-1835目录

和org.eclipse.equinox.launcher_1.3.0.v20130327-1440.jar包

copy到产品plugins目录下,

在产品ini文件中添加-startup这段配置,

再次执行启动脚本,成功通过。

点赞
收藏

评论区

加载中...

相关推荐

MySQL:[Err] 1292 - Incorrect datetime value: ‘0000-00-00 00:00:00‘ for column ‘CREATE_TIME‘ at row 1

文章目录问题用navicat导入数据时,报错:原因这是因为当前的MySQL不支持datetime为0的情况。解决修改sql\mode:sql\mode:SQLMode定义了MySQL应支持的SQL语法、数据校验等,这样可以更容易地在不同的环境中使用MySQL。全局s

Oracle 分组与拼接字符串同时使用

SELECTT.,ROWNUMIDFROM(SELECTT.EMPLID,T.NAME,T.BU,T.REALDEPART,T.FORMATDATE,SUM(T.S0)S0,MAX(UPDATETIME)CREATETIME,LISTAGG(TOCHAR(

MySQL部分从库上面因为大量的临时表tmp_table造成慢查询

背景描述Time:20190124T00:08:14.70572408:00User@Host:@Id:Schema:sentrymetaLast_errno:0Killed:0Query_time:0.315758Lock_

皕杰报表之UUID

​在我们用皕杰报表工具设计填报报表时,如何在新增行里自动增加id呢?能新增整数排序id吗?目前可以在新增行里自动增加id,但只能用uuid函数增加UUID编码,不能新增整数排序id。uuid函数说明:获取一个UUID,可以在填报表中用来创建数据ID语法:uuid()或uuid(sep)参数说明:sep布尔值,生成的uuid中是否包含分隔符'',缺省为

2020年前端实用代码段,为你的工作保驾护航

有空的时候,自己总结了几个代码段,在开发中也经常使用,谢谢。1、使用解构获取json数据let jsonData  id: 1,status: "OK",data: 'a', 'b';let  id, status, data: number   jsonData;console.log(id, status, number )

Java日期时间API系列36

  十二时辰,古代劳动人民把一昼夜划分成十二个时段,每一个时段叫一个时辰。二十四小时和十二时辰对照表:时辰时间24时制子时深夜11:00凌晨01:0023:0001:00丑时上午01:00上午03:0001:0003:00寅时上午03:00上午0