[Aldor-l] different libraries that contain files with same name

Gabriel Dos Reis gdr at cs.tamu.edu
Sat Dec 1 17:30:54 EST 2007


Laurentiu Dragan <ldragan at aldor.org> writes:

| Ralf Hemmecke wrote:
| > 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?
| 
| The restriction is in the way Aldor treats libraries. In Aldor, .al 
| files are collections of "libraries". For example, libaldor.al contains 
| sal_lang.ao library, sal_base.ao library, and others. Each such library 
| has an initialization function which is identified by name and the name 
| is built from the name of the file. So, you cannot have two "Aldor 
| libraries" with the same name and use them at the same time, even if 
| they are in different .al or .a file.

Instead of using only the basename of library file to name the
initialization function, why can't you use the full pathname
(i.e. name containing full parent directories)?  That way, you'd be
sure you don't confuse different libraries with same basenames but
living in different directories.

-- Gaby




More information about the Aldor-l mailing list