DUB / compiling same source and config to different windows subsystems in 32/64 bit
Mike Parker
aldacron at gmail.com
Tue Mar 5 03:40:46 UTC 2019
On Tuesday, 5 March 2019 at 02:13:30 UTC, evilrat wrote:
> This should do for MS linker
>
> "lflags-windows-x86_64": ["/SUBSYSTEM:CONSOLE"],
> "lflags-windows-x86_mscoff": ["/SUBSYSTEM:WINDOWS"]
>
> For old optlink x86 it is a bit harder, you need to include
> special .def file that has instruction for linker, here is an
> example from dlangui[2], adding it with linker libs should
> work, probably, or maybe, or...
>
No, you don't need a def file. OPTLINK understands the same
option:
hello.d
```
void main() {
import std.stdio;
writeln("Hello");
```
`dmd hello` outputs "hello"
`dmd -L/SUBSYSTEM:windows hello` outputs nothing.
More information about the Digitalmars-d-learn
mailing list