473,387 Members | 1,579 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,387 software developers and data experts.

Library path question

Group,

I'm setting up Perl 5.8 on a Sun solaris 5.6 machine and have a question
about the $PATH variable.

My installation is in /usr/local with subdirs:
perl is in bin
libraries are in lib/perl5

lib/perl5 has 4 subdirs and these have subdirs, and some of these have
subdirs. In all I have about 1200 modules in more than 20 directories.

Do I have to include all these directories in my path for perl to find
them? Is there a $LIB var for perl like with C? Will perl parse dir trees
for modules?

If it isn't obvious, I have about 3 days experience with perl, so be
gentle.

Any help appreciated,
Julie
Apr 21 '06 #1
2 9558
Well there is the $PERL5LIB variable which you can set in your
environment, but Perl has its own internal library path which you can
manipulate in your scripts: @INC. From your script you can add to this
array by using the command: 'use lib '<path to modules>'

You can see which paths it traverses by doing:

perl -e 'join "\n", @INC'

Hope this gets you going..

-- Aukjan

Julie Warden wrote:
Group,

I'm setting up Perl 5.8 on a Sun solaris 5.6 machine and have a question
about the $PATH variable.

My installation is in /usr/local with subdirs:
perl is in bin
libraries are in lib/perl5

lib/perl5 has 4 subdirs and these have subdirs, and some of these have
subdirs. In all I have about 1200 modules in more than 20 directories.

Do I have to include all these directories in my path for perl to find
them? Is there a $LIB var for perl like with C? Will perl parse dir trees
for modules?

If it isn't obvious, I have about 3 days experience with perl, so be
gentle.

Any help appreciated,
Julie

Apr 21 '06 #2
Aukjan van Belkum <au****@gmail.com> wrote in
news:2c***************************@news2.tudelft.n l:
Well there is the $PERL5LIB variable which you can set in your
environment, but Perl has its own internal library path which you can
manipulate in your scripts: @INC. From your script you can add to this
array by using the command: 'use lib '<path to modules>'

You can see which paths it traverses by doing:

perl -e 'join "\n", @INC'

Hope this gets you going..

-- Aukjan

Julie Warden wrote:
Group,

I'm setting up Perl 5.8 on a Sun solaris 5.6 machine and have a
question about the $PATH variable.

My installation is in /usr/local with subdirs:
perl is in bin
libraries are in lib/perl5

lib/perl5 has 4 subdirs and these have subdirs, and some of these
have subdirs. In all I have about 1200 modules in more than 20
directories.

Do I have to include all these directories in my path for perl to
find them? Is there a $LIB var for perl like with C? Will perl parse
dir trees for modules?

If it isn't obvious, I have about 3 days experience with perl, so be
gentle.

Any help appreciated,
Julie


Aukjan,

Thanks! I also got some good info at the SunFreeWare site. This is a
good tip, and I'm anxious to use it.

Julie
Apr 21 '06 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

70
by: Michael Hoffman | last post by:
Many of you are familiar with Jason Orendorff's path module <http://www.jorendorff.com/articles/python/path/>, which is frequently recommended here on c.l.p. I submitted an RFE to add it to the...
3
by: Michele Petrazzo | last post by:
I want to redistribute the library that I create. I create a project, its setup.py that when launched copy all files into the "site-packages/library" directory. And here it's all ok. When I call...
2
by: Richard Weigel | last post by:
Hello, I have the problem, to protect a library against unauthorized usage. For realizing this, I want to identify the calling program (path+filename) to check if it has a digital signature....
5
by: Tony Johansson | last post by:
Hello! I have one solution file that consist of three project. One project that build the exe file called A One project that build a user control dll. Here we have a class called B One project...
0
by: tony | last post by:
Hello! I'm not sure if this is the right group to send my question in. I have one solution file that consist of three project. One project that build the exe file called A One project that...
18
by: happyvalley | last post by:
a silly question. when linking a program, the path to include files and library files are given already (-I, -L), why still need to give the names of some library by -l , say -lm for math...
3
by: Martyn Fewtrell | last post by:
Hi there. First of all let me apologise for this is a somewhat general question to which I would be interested in any opinions. As far as I can see when I create a web application the...
3
by: Martin Evans | last post by:
I have converted a Python script using py2exe and have it set to not bundle or compress. The result is my exe and all the support files including library.zip (exactly as planned - nice job py2exe)....
6
by: =?Utf-8?B?WW9naSBXYXRjaGVy?= | last post by:
Hello, I am using Visual Studio-2003. I created a project to build my library. Since I am using third party libraries as well, I have specified those additional library dependencies in project...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.