digitalmars.D.learn - Why do the WindowsAPI bindings have pragma calls?
- Andrej Mitrovic (4/4) Apr 08 2011 E.g. the WindowsAPI bindings have the wingdi.d file, which has this call...
- Andrej Mitrovic (6/6) Apr 08 2011 Ok so if I compile the Winapi .d modules with my main file, the pragma
- Jacob Carlborg (4/10) Apr 10 2011 http://d.puremagic.com/issues/show_bug.cgi?id=2776
- Andrej Mitrovic (2/2) Apr 10 2011 Damn, a two year old patch. Why wasn't this included already?
- Jacob Carlborg (4/6) Apr 10 2011 There are a lot of those in bugzilla.
E.g. the WindowsAPI bindings have the wingdi.d file, which has this call at the very top of the module: pragma(lib, "gdi32.lib"); This doesn't seem to put any gdi32.lib symbol references to the final winapi library file, and if I try to use a function from wingdi.d from a main file, I still have to manually link to the gdi32.lib file (or use a pragma), otherwise I get undefined symbol errors. So what are those pragmas for?
Apr 08 2011
Ok so if I compile the Winapi .d modules with my main file, the pragma statement is taken into account and I don't have to manually add the pragma again. But If I use an import switch (dmd -Iwin32\) and a precompiled library, then the pragma statement is skipped. Could this be considered a bug?
Apr 08 2011
On 2011-04-08 21:18, Andrej Mitrovic wrote:Ok so if I compile the Winapi .d modules with my main file, the pragma statement is taken into account and I don't have to manually add the pragma again. But If I use an import switch (dmd -Iwin32\) and a precompiled library, then the pragma statement is skipped. Could this be considered a bug?http://d.puremagic.com/issues/show_bug.cgi?id=2776 -- /Jacob Carlborg
Apr 10 2011
Damn, a two year old patch. Why wasn't this included already? Thanks for letting me know.
Apr 10 2011
On 2011-04-10 20:24, Andrej Mitrovic wrote:Damn, a two year old patch. Why wasn't this included already? Thanks for letting me know.There are a lot of those in bugzilla. -- /Jacob Carlborg
Apr 10 2011