I think that is fine for the structure of the build directories,
however I feel strongly that they should not be installed in such a
structure.
To take your example:
druntime
|-core
|---atomic.d (generic files)
|---bitop.d
|---[...]
|-gc
|-gcstub
|-rt
For the file structure below - when building for glibc, the make file
would have -I libdc/glibc in it's DFLAGS (or compile all relevant
sources in one go) - so libdc/glibc/core/stdc/stdio.d would still be
declared as 'module core.stdc.stdio;'
When running 'make install' - the build gets the correct sources and
puts them in their true locations.
|-libdc
|---glibc
|-----core // Installed in /usr/include/d2/core
|-------sys // Installed in /usr/include/d2/core/sys
|-------stdc // Installed in /usr/include/d2/core/stdc
|---bionic
|-----core // Installed in /usr/include/d2/core
|-------sys // Installed in /usr/include/d2/core/sys
|-------stdc // Installed in /usr/include/d2/core/stdc
|---newlib
|-----core // Installed in /usr/include/d2/core
|-------sys // Installed in /usr/include/d2/core/sys
|-------stdc // Installed in /usr/include/d2/core/stdc
The idea being that bionic/newlib packages are not shipped with glibc releases.
The complexity here would be a minor alternation to the way the
current build process is done, and will require *no change* in either
existing user code or how the druntime library is written.
Regards
That's what I meant when I wrote "compile in the correct directory".
Sorry, I should have explained that better.