add_compile_options not having an effect

My linux bin build and runs ok.
I needed to have compiler options specified and I can see it is set in the build.cmake file after cmake … .
But now if I compile it, it has no effect on make stage. What could be wrong?

add_compile_options(-c -fPIC)
MakeFiles/lib3.dir/flags.make:9:C_FLAGS = -c -fPIC
CMakeFiles/lib2.dir/flags.make:9:C_FLAGS = -c -fPIC
CMakeFiles/lib1.dir/flags.make:9:C_FLAGS = -c -fPIC
CMakeFiles/test.dir/flags.make:9:C_FLAGS = -c -fPIC
Those should generate *.o files but I instead see *.a files consistent with static build instead meaning -c and -fPIC no having an effeect on make stage.

-fPIC is handled by the POSITION_INDEPENDENT_CODE target property, so that shouldn’t be specified manually. -c must be handled by CMake so that the compiler does what CMake expects it to.

What are you trying to accomplish here?