Re: suchpfad fü r libraries

[email protected]
Newsgroups gmane.comp.lang.ruby.german
Message-ID <[email protected]>
Hello --

On Tue, 13 Aug 2002, Felix von Delius wrote:

> Mit "strings libruby.so.1.6" hab ich gesehen, dass das von mir
> gewählte Verzeichnis gar nicht im Suchpfad ist. Aber es gibt doch
> bestimmt eine globale Variable o.ä. in der der Suchprad steht, oder?
>
> -Felix

Ja, der Suchpfad steckt in der Variable '$:'

  $ ruby -e 'puts $:'
  /usr/lib/ruby/site_ruby/1.6
  /usr/lib/ruby/site_ruby/1.6/i686-linux-gnu
  /usr/lib/ruby/site_ruby
  /usr/lib/ruby/1.6
  /usr/lib/ruby/1.6/i686-linux-gnu
  .

und laesst sich dynamisch veraendern:

  $:.unshift("/home/ich/irgendein/verzeichnis")  # u.s.w.

"site_ruby" ist aber normalerweise schon da.  Wie sieht der Inhalt
deiner "$:" aus?


David

-- 
David Alan Black
home: [email protected]
work: [email protected]
Web:  http://pirate.shu.edu/~blackdav
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.