Linker can't link functions from advapi

Mike Parker aldacron at gmail.com
Mon Apr 1 14:04:35 UTC 2019


On Monday, 1 April 2019 at 10:07:58 UTC, Deen O'Connor wrote:
> So i got this problem when i tried to compile my project in VS 
> 17 with VisualD plugin.
>
> It compiled just fine, i got no errors from DMD, but both 
> optlink and vs linker tell me that i have 3 unknown functions - 
> OpenProcessToken, LookupPrivilegeValue and 
> AdjustTokenPrivileges.
>
> I tried converting advapi32.dll to .lib, this did not solve the 
> problem, because with the necessary .lib file set in project 
> settings i get a message telling me that my advapi32.lib is 
> corrupt.
>
> Idk what to do, and i don't want to re-write everything with 
> another language.

You shouldn't need to convert it for the MS linker. The proper 
32- and 64-bit COFF format libs should have been installed with 
VS 17.


More information about the Digitalmars-d mailing list