[Issue 4095] compiling with -op -od and using absolute paths for source files make dmd write object files anywhere
d-bugmail at puremagic.com
d-bugmail at puremagic.com
Thu Apr 15 18:00:38 PDT 2010
http://d.puremagic.com/issues/show_bug.cgi?id=4095
--- Comment #1 from nfxjfg at gmail.com 2010-04-15 18:00:36 PDT ---
Note that ldc supports the -oq switch, which is much more friendlier to build
scripts. Bug 3541 has a patch to enhance dmd with -oq. In combination with
-deps, -oq uses object filenames that can be easily known by build script,
instead of having to emulate dmd's path handling to find out the final object
filename.
E.g. in the example above, where should foo.o really be written? The
filename/path must not clash with other modules named "foo", and using the
package name seems the simplest solution. Which is exactly what -oq does.
Further note that the only properly working build tool for D, xfbuild, uses
incredible kludges to work this around. When there are modules with the same
name/different packages, it does several compile runs to avoid dmd overwriting
the object files it just created in the same run.
I hope this is motivation enough to solve this problem "upstream".
--
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
More information about the Digitalmars-d-bugs
mailing list