cli add option

https://stackoverflow.com/questions/44284275/passing-compiler-options-in-cmake-command-line

Command line options like CMAKE_C_FLAGS and CMAKE_CXX_FLAGS always append and never overwrite.

-DCMAKE_C_FLAGS

-DCMAKE_CXX_FLAGS="-Wno-dev -Wl,-rpath=/home/abcd/libs/"

-DCMAKE_CXX_FLAGS=-Wno-error=incompatible-function-pointer-types

-Wno-error=incompatible-function-pointer-types
-Wno-incompatible-function-pointer-types
posted @ 2023-05-13 10:58  fndefbwefsowpvqfx  阅读(9)  评论(0编辑  收藏  举报