[M3devel] $ORIGIN?

Jay K jay.krell at cornell.edu
Fri Jul 16 15:47:46 CEST 2010


> We should document that as a workaround.


It sort of is, but it is a bit vague.
We can fill in specifics:
  FreeBSD < 8.0 
  NetBSD < 5.0 (but we don't have NetBSD distributions so..) 
  no problem on Linux, Solaris, MacOSX, NT.


Basically, I have to say..I think we might have zero NetBSD users
so I thought we were well covered. I didn't realize FreeBSD was late here.
That was surprising.


 > But lots of people complained
 > and wanted more flexibility, or rather their platform-specific different
 > standard setups.

This is a critical distinction of course.
Using /opt/cm3 on Solaris.
  /usr/pkg on NetBSD.
  etc. is trivial.


I'm guessing $HOME and $HOME/cm3 are common though too.
   I keep getting non-root access to machines and using that. :)


As well, for a long time, the answer was LD_LIBRARY_PATH, which despite
going by a few different names, does seem common. But I'm not sure I prefer it.
Obviously you can read all the distaste for it on the web.


I'm *guessing* that non-NT users are mostly Linux users, and I'm *guessing* that
$ORIGIN has been there a while. Solaris has also had it a while. FreeBSD as I said, not.
NetBSD since 5.0 (current). OpenBSD I don't know.


Building "static" -- "partly static" also evades this.
Except for OpenBSD, "static" is only relative to Modula-3 libraries.
But it is overkill, wasteful, bigger, slower.


And lots of people don't build the system themselves, right?


> We haven't got the resources to fulfill all wishes currently.


Hehe. I want world peace and a few million dollars. :)


> I'd vote to keep the status quo until someone either has a great idea
> or implements something better, or we'll keep changing solutions back
> and forth.


Ok.
I think all the ideas are known here. :)


Ultimately I like the idea of generating C, and then using autoconf and libtool to
fill in some cracks. But the C backend is a big missing in action piece. I'm largely talk, less action.


Time passing helps, people will converge more on systems having $ORIGIN support.


  - Jay

----------------------------------------
> Date: Fri, 16 Jul 2010 15:10:02 +0200
> From: wagner at elegosoft.com
> To: m3devel at elegosoft.com
> Subject: Re: [M3devel] $ORIGIN?
>
> Quoting Jay K :
>
> > So I can build a distribution FreeBSD 4.11...
> >
> > But it looks like FreeBSD didn't support $ORIGIN until very recently: 8.0.
> >
> > This is evidenced from two places:
> >
> > http://www.freebsd.org/releases/8.0R/relnotes-detailed.html
> >   indicates it is new
> >
> > and http://www.freebsd.org/cgi/man.cgi lets you specify version.
> > The ld-elf.so manpage doesn't mention it until 8.0.
>
> That's correct.
>
> Alas, there's no common standard shared by all the systems we support.
>
> > This means, something like:
> >   FreeBSD users using < 8.0 will need/want to set LD_LIBRARY_PATH.
>
> We should document that as a workaround.
>
> >   I don't think the distributed binaries have any hardcoded paths in
> > them, except for the $ORIGIN stuff,
> >    which I think will just be ignored. "Normally" they do, but the
> > distribution build specifically
> >    tries to omit them.
>
> > This "puts pressure" on considering "this problem" more/again?
> >   NetBSD < 5.0, FreeBSD < 8.0 ... enough to do something about?
> >   I've been looking into autoconf and libtool some, but i haven't yet, like..
> >   what I'd like to see very clearly is them do the "relink before
> > install" behavior.
> >   Once confirmed to be there.. maybe our "binary" packages are a
> > bunch of .o files?
> >   Interesting compromise?
> >   Or, really, maybe we somewhat give up on "relocatability" and
> > hardcode /usr/local/cm3?
> >      I realize, official Debian packages need to be at /usr.
> >   Anyone building from source, can put the files anywhere.
> >   We can also only "give up" on FreeBSD and/or NetBSD -- where
> > $ORIGIN is more recent introduction.
>
> We should keep that for the time being.
>
> > I also seem to recall OSF/1 supports arbitrary environment
> > variables, but doesn't define anything for you like $ORIGIN.
> > Some system is that way.
> > For that can invent custom names and wrapper scripts perhaps.
> >
> > I know, a likely question, it has been asked for, "what is common?"
> > i.e. portable, works the same "everywhere"?
> >   That would be hardcoded paths, no relocatability.
> > $ORIGIN is very common, but less so.
> >
> > I'm the one who opened this can of worms here.
> >  The previous -rpath was a mess with lots of directories. That could
> > at least be changed to something short.
> >   $ORIGIN is indeed very promising and fairly portable, but not
> > perfectly portable nor perfectly "behaved".
> >   I don't think any solution is perfectly "behaved", there are
> > contradictory goals.
>
> /usr/local/cm3 was the original one standard location when we first
> published the sources from Critical Mass. But lots of people complained
> and wanted more flexibility, or rather their platform-specific different
> standard setups.
>
> We haven't got the ressources to fulfill all wishes currently.
>
> I'd vote to keep the status quo until someone either has a great idea
> or implements something better, or we'll keep changing solutions back
> and forth.
>
> Olaf
> --
> Olaf Wagner -- elego Software Solutions GmbH
> Gustav-Meyer-Allee 25 / Gebäude 12, 13355 Berlin, Germany
> phone: +49 30 23 45 86 96 mobile: +49 177 2345 869 fax: +49 30 23 45 86 95
> http://www.elegosoft.com | Geschäftsführer: Olaf Wagner | Sitz: Berlin
> Handelregister: Amtsgericht Charlottenburg HRB 77719 | USt-IdNr: DE163214194
>
 		 	   		  


More information about the M3devel mailing list