[PerlChina] 请问有什么便捷的方法载入zip包里的库?

Luo Yong luo.yong.name at gmail.com
Wed Dec 24 21:05:47 PST 2008


多谢,

这个方法大概是最好的方法了,不过感觉Java的那种用JAR文件封装类库的方法很方便,但是在perl上暂时没办法实现,不知道perl6里有没有类似的功能。



2008/12/25 agentzh <agentzh at gmail.com>:
> 2008/12/25 Luo Yong <luo.yong.name at gmail.com>
>>
>> 大家好,
>>
>>
>> 我想在我的个人主页空间里加入一些CGI,一些pm是自己写的,服务器的FTP不是很好用,所以想把这些pm打成一个zip包上传上去,但是不知道如何配置才能在脚本里引用,谁有好的方法麻烦告知一下。
>
> use lib '/path/to/my/pm/directory';
> use MyModule;
>
> or
>
> BEGIN { unshift @INC, '/path/to/my/pm/direcotry' }
> use MyModule;
>
> or
>
> perl -I/path/to/my/pm/direcotry myscript.pl
>
> Good luck!
> -agentzh
>
>
> _______________________________________________
> China-pm mailing list
> China-pm at pm.org
> http://mail.pm.org/mailman/listinfo/china-pm
>


More information about the China-pm mailing list