Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Export Perl script with modules

Tags:

perl

I have a perl script which is deleting Logs files for me. Now I want to use this script on multiple other computers and on one server. The problem is, that I use some manual downloaded modules.

My question is, how can I export a perl script into a .zip with all used modules in the script?

What I'm trying to reach is, that I can put the .zip file on a different computer and run the script without any error caused by the manual imported modules.

like image 482
poisn Avatar asked Jan 26 '23 18:01

poisn


1 Answers

Distribute as one program containing everything:

  • fatpack
  • pp
  • staticperl

Alternatively, install the dependencies into a local subdirectory and add the subdirectory to the include path.

  • cpanm -L extlib Some::Module Yet::Another::Module More::Modules
like image 131
daxim Avatar answered Feb 05 '23 16:02

daxim