Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

SetProcessDpiAwareness in ui/hi_dpi_procs.odin links with invalid .lib #3

Open
thePHTest opened this issue Feb 11, 2022 · 0 comments
Open

Comments

@thePHTest
Copy link

Trying to link to this proc or any of the other ones in

@(default_calling_convention="stdcall")
foreign api_ms_win_shcore_scaling_l1_1_1 {
	SetProcessDpiAwareness :: proc(value: _types.PROCESS_DPI_AWARENESS) -> _types.HRESULT ---
	GetProcessDpiAwareness :: proc(hprocess: _types.HANDLE, value: ^_types.PROCESS_DPI_AWARENESS) -> _types.HRESULT ---
	GetDpiForMonitor :: proc(hmonitor: _types.HMONITOR, dpiType: _types.MONITOR_DPI_TYPE, dpiX: ^u32, dpiY: ^u32) -> _types.HRESULT ---
}

results in LINK : fatal error LNK1181: cannot open input file 'api-ms-win-shcore-scaling-l1-1-1.lib'

Swapping it out to use shcore.lib fixes the linker error.
i.e. https://docs.microsoft.com/en-us/windows/win32/api/shellscalingapi/nf-shellscalingapi-setprocessdpiawareness

Must be an issue with the provided metadata?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant