[Aldor-l] different libraries that contain files with same name
Gabriel Dos Reis
gdr at cs.tamu.edu
Sat Dec 1 17:22:56 EST 2007
Ralf Hemmecke <ralf at hemmecke.de> writes:
| Hello,
|
| maybe all of you know, but I would really like to know why there is this
| restriction that I cannot have two libraries that contain the same
| filename. Why does the file name in different object libraries matter at
| all?
|
| This problem does not occur for pure C code see below.
Not commenting on whether this issue should be fixed or not: I would
like to point out that it is a common implementation trick in the Lisp
world. Other languages have solved similar issues by either
(1) totally ignoring it (C, C++)
(2) introducing elaborate forms of packaging, versioning,
etc. (Perl, Java, etc.)
None seems to have a perfect simple answer.
As for the C world, you probably heard of `DLL hell', or
LD_LIBRARY_PATH or RPATH (and why they are all considered hamrful).
| Any suggestion for a workaround?
Obvious free advice: give unique names to your files. Yes, it can lead
to non-obvious situations. Pick your poison.
-- Gaby
More information about the Aldor-l
mailing list