what you wish for can be done, it's just not easy to do nor to explain.
the basic idea goes like this.
- build on a development machine. you need to match architecture and OS.
- build the needed libraries. static is best unless you want real pain.
- build the perl module so that it uses the static library and installs
in it's own directory.
- copy your directory of perl modules up to your web space and use them
from your scripts.
sounds easy, and sometimes it is.
$ cd /tmp/libfoo-0.0.1
$ ./configure --prefix=/tmp/support
$ make
$ make install
$ ls /tmp/support/lib
libfoo.a libfoo.so libfoo.so.1
$ rm /tmp/support/libfoo.so*
$ cd /tmp/Foo-0.0.1
$ perl Makefile.PL PREFIX=/tmp/support
$ make
$ make test
$ make install
$ scp -r /tmp/support/lib/perl5 me@provider:public_html/
$ cat >/tmp/test.pl
#!/path/to/providers/perl
use lib '/path/to/me/public_html/perl5';
use Foo;
print "Content-type: text/plain\r\n\r\nWoot!";
^D
$ chmod ugo+rx /tmp/test.pl
$ scp /tmp/test.pl me@provider:cgi-bin/
cross fingers and try it out. be warned, it can be much harder than this would suggest and it's better to try it local first to make sure it works. be prepared for pain.
Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
Read Where should I post X? if you're not absolutely sure you're posting in the right place.
Please read these before you post! —
Posts may use any of the Perl Monks Approved HTML tags:
- a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
| |
For: |
|
Use: |
| & | | & |
| < | | < |
| > | | > |
| [ | | [ |
| ] | | ] |
Link using PerlMonks shortcuts! What shortcuts can I use for linking?
See Writeup Formatting Tips and other pages linked from there for more info.