在linux下,如何改perl的环境变量

在linux下,如何改perl的环境变量,第1张

export LD_LIBRARY_PATH=变量lib路径:$LD_LIBRARY_PATH

这是更改系统变量的,如果改perl5的变量,则在perl脚本里面 使用 use lib "变量路径"

把脚本放到/usr/lib/cgi-bin/里面. 并且给执行权限.

然后http://localhost/cgi-bin/test.pl

具体路径参数一下/etc/apache2/sites-enabled/里面的路径配置.

连到Unix系统后,输入命令 which perl ,然后回车。

如果装了perl,就能知道在什么路径下安装的,如果显示找不到,就没装。

已经安装:

[host@host]~% which perl

/usr/bin/perl

[host@host]~%

未安装:

[host@host]~% which perl

perl not found

[host@host]~%

显示版本:

[host@host]~% perl -v

This is perl, v5.8.8 built for i386-linux-thread-multi

Copyright 1987-2006, Larry Wall

Perl may be copied only under the terms of either the Artistic License or the

GNU General Public License, which may be found in the Perl 5 source kit.

Complete documentation for Perl, including FAQ lists, should be found on

this system using "man perl" or "perldoc perl". If you have access to the

Internet, point your browser at http://www.perl.org/, the Perl Home Page.

[host@host]~%


欢迎分享,转载请注明来源:内存溢出

原文地址:https://54852.com/yw/6162226.html

(0)
打赏 微信扫一扫微信扫一扫 支付宝扫一扫支付宝扫一扫
上一篇 2023-03-16
下一篇2023-03-16

发表评论

登录后才能评论

评论列表(0条)

    保存