Which Perl files (other than modules) are used by a script?

Ask a Question related to PERL Miscellaneous, Design and Development.

  1. #1

    Default Which Perl files (other than modules) are used by a script?

    I'm writing a software installer (in Perl, of course) which is
    intended to run from a CD. Because it may be used on customer systems
    where they don't have Perl installed (shame on them, I know, but they
    pay the bills), I need to put enough of the Perl runtime environment
    on the CD to allow the installer program to run. And because the
    installer program is likely to be enhanced in future, with the use of
    extra modules, I want to be able to generate the list of supporting
    files (.pm files, shared libraries, etc.) automatically. Although I
    can test (and have tested) things by temporarily renaming the
    directory holding the system's Perl libraries, we support around six
    different UNIX and Linux systems, so I'm after a method that can tell
    me what needs to go onto the CD before I test it.

    Using %INC, I can determine the list of module files nicely. To find
    out which shared libraries are needed, I thought I could use
    @DynaLoader::dl_modules, but on some platforms (e.g. Linux with Perl
    5.6.1) this array is empty. (Any ideas?) So as a fallback, I look
    under $Config{archlibexp} for any shared libraries whose name matches
    a module in %INC. This seems to work for all platforms except one.
    On Solaris 7 with Perl 5.005_03, when I run using the cut-down
    environment, I get:

    Can't locate auto/DynaLoader/dl_findfile.al in @INC (@INC contains
    ...

    So is there a better way to determine which shared library and other
    non-module files are needed by a script?

    Jonathan Gowland Guest

  2. Similar Questions and Discussions

    1. Loading Perl Modules from same directory as script
      Well, after only 6 hours of hacking around trying to do something that should be obvious in perl - but isn't - i seem to have found two solutions :...
    2. Newbie: Bundling Perl script and modules in a Mac OS X app?
      Is it possible to bundle a Mac OS X application with a Perl script and a number of required modules, stored in the application package (folder...
    3. Perl modules on Mac OS X
      Hi fellows, I have a funny problem: When installing my OS (Mac OS 10.3), I did not realize that the 'make' utility was part of the developer tools...
    4. Re : Installing CPAN Perl Modules with Activestate Perl 5. v5.8
      Hi, In the process of trying to get perl modules installed, I downloaded over 300 Activestate specific perl modules and they work fine (of the ones...
    5. How Can I Install PERL Modules w/o Upgrading PERL?
      Shalom! I absolutely hate it when I install a required module for one piece of software or another, and suddenly it begins installing the...
  3. #2

    Default Re: Which Perl files (other than modules) are used by a script?

    Jonathan Gowland wrote:
    > I'm writing a software installer (in Perl, of course) which is
    > intended to run from a CD. Because it may be used on customer systems
    > where they don't have Perl installed (shame on them, I know, but they
    > pay the bills), I need to put enough of the Perl runtime environment
    > on the CD to allow the installer program to run.
    you might want to have a look at the PAR-module (available on
    CPAN). it packs your program and all needed files into an
    executable (or in an extra .par-file).

    hth, tina
    --
    [url]http://www.tinita.de/[/url] \ enter__| |__the___ _ _ ___
    [url]http://Movies.tinita.de/[/url] \ / _` / _ \/ _ \ '_(_-< of
    [url]http://www.perlquotes.de/[/url] \ \ _,_\ __/\ __/_| /__/ perception
    - the above mail address expires end of december 2003 -
    Tina Mueller Guest

Posting Permissions

  • You may not post new threads
  • You may post replies
  • You may not post attachments
  • You may not edit your posts

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139