VS: Trouble with /MANIFESTUAC:\"level='requireAdministrator'\" in LINK_FLAGS
Previously, when using the `"Visual Studio 14 2015" generator this line from CMakeLists.txt worked:
set_property(TARGET j-bin APPEND_STRING PROPERTY LINK_FLAGS " /level='requireAdministrator'")
I switched to the Ninja generator and /level
was no longer working as expected. As a test, I changed that line of code to this:
set_property(TARGET j-bin APPEND_STRING PROPERTY LINK_FLAGS " /MANIFESTUAC:\"level='requireAdministrator'\" /level='requireAdministrator'")
That fixed the problem. I think there is a bug in the Ninja generator that is causing it to ignore /level
in LINK_FLAGS
.