marekjm / viuavm

Parallel virtual machine designed to reliably run massively concurrent programs
https://viuavm.org/
GNU General Public License v3.0
71 stars 11 forks source link

Library hierachy #86

Closed marekjm closed 9 years ago

marekjm commented 9 years ago

Library hierarchy should be designed for Viua. It would contain guidelines for:

marekjm commented 9 years ago

Viua libraries are by default looked for in the following directories:

  1. . - first search current working directory,
  2. ~/.local/lib/viua,
  3. ~/.local/lib/viua/site
  4. /usr/local/lib/viua,
  5. /usr/local/lib/viua/site
  6. /usr/lib/viua,
  7. /usr/lib/viua/site
  8. <empty> - to allow specifying imports by absolute path (e.g link ::foo::bar::baz),

Duplicated paths (e.g. ~/.local/lib/viua and ~/.local/lib/viua/site) are present because apart from site subdirectory, there is also the std directory for standard libraries. Using std::string will find ~/.local/lib/viua/std/string.vlib.