"Andrei Alexandrescu" <seewebsiteforem...@erdani.org> wrote in message news:i4emnt$bc...@digitalmars.com... > > I saw the q, and was still mulling for an answer. I the join > intentionally, and now I think I remembered why. > > The join is needed in the probably rare case when you're running rdmd from > a different directory from the root module, e.g: > > $ pwd > ~/foo/bar > $ rdmd ../baz/main.d > > In this case, if there's no join with the rootDir, modules will be looked > up in ~/foo/bar/, which is probably not the right thing. > > What is your use case? >
That's what I was starting to suspect. My case (writing this from memory, if this doesn't behave like I describe, then it's something along these lines): $ cat src/app/main.d module app.main; import foo; void main(){} $ cat src/lib/foo.d module lib.foo; $ xfbuild -Isrc src/app/main.d Works ok $ rdmd -Isrc src/app/main.d dmd craps out because rdmd told it to compile "src/app/src/lib/foo.d"