用lylix写的程序,调试时(F9)没有什么错误,但是怎么正常启动? ( 积分: 50 )

  • 主题发起人 minxinliu
  • 开始时间
M

minxinliu

Unregistered / Unconfirmed
GUEST, unregistred user!
[oracle@localhost ser]$ ./services
./services: relocation error: ./services: undefined symbol: initPAnsiStrings
怎么解决?
谢谢!
 
[oracle@localhost ser]$ ./services
./services: relocation error: ./services: undefined symbol: initPAnsiStrings
怎么解决?
谢谢!
 
不好意思 ,应该是 Kylix
 
由于Kylix编译后的可执行文件要能正常运行,必须正确地用到共享库文件(大都在Installed Path下的bin目录里,一般以.so做后缀),
所以要在/etc/ld.so.conf里添加共享库所在路径或指定LD_LIBRARY_PATH环境变量去到相应共享库所在路径加载所需程序,
LD_LIBRARY_PATH可在/etc目录下的bashrc或profile文件里设置。
ld.so.conf、bashrc和profile这三个文件都在/etc目录下,需要有root权限的用户才能修改它们,所以用如下命令转到root:
# su
然后分别用vi或其他文本编辑器去编辑这三个文件。
在/etc/ld.so.conf里加上一行,即Kylix共享库所在的路径:
/home/yourname/kylix3/pro/bin
然后存盘退出。
在/etc/bashrc和/etc/profile里都同样加上相同的三行:
export LD_LIBRARY_PATH=/home/yourname/kylix3/pro/bin:$LD_LIBRARY_PATH
export LC_ALL=zh_CN
export LANG=zh_CN
即指定LD_LIBRARY_PATH环境变量到共享库所在路径,
并使得以后编译出来的程序显示的界面支持中文。
然后存盘退出。
执行下面的命令,使设置生效:
# ldconfig
退出root:
# exit
 
接受答案了.
 

Similar threads

D
回复
0
查看
1K
DelphiTeacher的专栏
D
S
回复
0
查看
3K
SUNSTONE的Delphi笔记
S
S
回复
0
查看
2K
SUNSTONE的Delphi笔记
S
I
回复
0
查看
814
import
I
顶部