Updated to use CMake's improved target commands.
Removed unneeded flag.