Java在AIX中不起作用 [英] Java Not working in AIX

查看:334
本文介绍了Java在AIX中不起作用的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我最近在我的AIX Server中安装了git,并且git可以正常工作。

I recently installed git in my AIX Server and git works fine.

但是Java现在无法正常工作。

But java is not working now.

如果我执行的是Java --version,则会得到foll输出。

If i do a java --version I'm getting the foll output.

admin:stud:/webapps/WEB-INF/classes> java --version
exec(): 0509-036 Cannot load program java because of the following errors:
        0509-150   Dependent module /opt/freeware/lib/libiconv.a(shr4_64.o) could not be loaded.
        0509-152   Member shr4_64.o is not found in archive

如何解决此问题

以前已安装以下Java版本。

Previouly the below java version was installed.

admin:stud:/demo> java -version
java version "1.5.0"
Java(TM) 2 Runtime Environment, Standard Edition (build pap64dev-20080315 (SR7))
IBM J9 VM (build 2.3, J2RE 1.5.0 IBM J9 2.3 AIX ppc64-64 j9vmap6423-20080315 (JIT enabled)
J9VM - 20080314_17962_BHdSMr
JIT  - 20080130_0718ifx2_r8
GC   - 200802_08)
JCL  - 20080314

这是我的质量检查服务器的输出,该服务器安装了与开发机相同的Java,目前正在向我提供错误信息。
我该怎么做才能解决此问题

This is a output from my QA server which has the same java installed as the dev machine which is currently giving me the error. What can i do to fix this

推荐答案

在AIX上进行编译很困难。我通常给ld通往libiconv的绝对路径,因为既有开源版本,也有AIX版本。

Compiling on AIX is hard. I generally give ld an absolute path to libiconv because there is the open source version as well as AIX's version.

一个想法是将git移到一边。我通常创建一个名为.real的目录,并将git从其开始位置移至.real子目录。即如果get为/ down / this / path / git,则将其移至/down/this/path/.real/git。

One thought would be to move git to the side. I usually make a directory called .real and move git from where it starts to the .real subdirectory. i.e. if get is /down/this/path/git then move it to /down/this/path/.real/git.

然后编写一个脚本/ down / this / path / git,它设置LIBPATH并执行到/down/this/path/.real/git

Then write a script /down/this/path/git which sets LIBPATH and does an exec to /down/this/path/.real/git

#!/bin/ksh
export LIBPATH=/blah/blah:/usr/lib
exec /down/this/path/.real/git "$@"

Java使其复杂化,因为它设置了LIBPATH(或

Java complicates this because it sets LIBPATH (or it use to) and ignores what LIBPATH was set to previously.

此外...您也不想混合使用两个libiconv。如果某人想要开放源代码版本,则需要使用它,而不是AIX版本,反之亦然。

Also... you don't want to mix and match the two libiconv's. If something wants the open source version, it needs to use it and not the AIX version and vice versa.

祝你好运

这篇关于Java在AIX中不起作用的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆