Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Suppress link warnings with CMake

I am aware of how to suppress compile warnings with CMake by doing (suppose I want to disable compile warning C4819):

set_target_properties(${PROJECT_NAME} PROPERTIES COMPILE_FLAGS "/wd4819")

So how to suppress link warnings with CMake (say LNK4099)?

like image 930
herohuyongtao Avatar asked Jan 22 '16 06:01

herohuyongtao


1 Answers

Try this:

set_target_properties(${PROJECT_NAME} PROPERTIES LINK_FLAGS "/ignore:4099")

It worked perfectly for me with Visual Studio 2015.

like image 57
jpo38 Avatar answered Sep 26 '22 06:09

jpo38