User Tools

Site Tools


design:filesystem_hierarchy

File system hierarchy

The Wonderful toolchain lives in /opt/wonderful. Tools should avoid hardcoding that path, instead relying on the WONDERFUL_TOOLCHAIN environment variable.

The hierarchy of folders in the toolchain's directory is arranged as follows:

  • bin - Toolchain-wide binaries; most of them are prefixed with wf-, so this directory should be safe to add to PATH without conflict.
  • doc - Per-package documentation.
    • <package name>
  • etc - Toolchain-wide configuration.
  • lib - Toolchain-wide libraries.
  • pacman - wf-pacman package manager state (cache, database, et cetera).
  • share - Only used by wf-pacman's makepkg. (TODO: This is probably a good idea to merge with lib)
  • tmp - Temporary files.

There are also per-target/per-toolchain folders:

  • examples - Target-specific examples.
    • <target>
  • target - Target-specific library and include files.
    • <target>
      • include
      • lib
  • templates - Target-specific project templates.
    • <target>
      • <template>
  • toolchain - Toolchain-specific binary and library files.
    • <toolchain>

Third-party projects packaged within wf-pacman (say, by using their own repository) should use their own subdirectory:

  • thirdparty

Third-party code packaged outside of wf-pacman (say, provided by the user) should use the local subdirectory:

  • local
design/filesystem_hierarchy.txt · Last modified: 2025/05/03 07:22 by asie