Improves documentation of -op switch in dcompiler.dd
text/plain
1806
Comments
Comment #0 by renezwanenburg — 2012-02-29T07:59:18Z
When using DMD to generate interface files for it's input, the generated interfaces are all put directly in the directory specified by -Hd. If the original source files are in a package hierarchy, for example
source/package1/module1.d
source/package2/module2.d
and we output the interfaces to headers/, the output will be
headers/module1.di
headers/module2.di
When adding headers/ to the include path of the compiler and we want to import the modules, we'd first have to recreate the package hierarchy which is less than ideal. It would be better if DMD could output the interfaces to
headers/package1/module1.di
headers/package2/module2.di
Comment #1 by code — 2012-02-29T10:12:41Z
You can use the -op option.
dmd -o- -op -Hdheaders pkg1/mod1.d pkg2/mod2.d
Comment #2 by renezwanenburg — 2012-03-01T05:48:50Z
Created attachment 1079
Improves documentation of -op switch in dcompiler.dd
Created patch for the compiler documentation in dcompiler.dd, the documentation now states the -op switch also keeps file paths for interface and Ddoc files. The -Dd, -Hd, and -od switches now mention the -op switch.