The CMakeFiles have become a bit messy and seem overcomplicated. I think a modern CMake makeover would help a lot. Things like FFTW_LINK_FLAGS, for instance, should not be used as such, since linker flags and linking targets are two things that are defined separately, so combining them in one variable is not CMake-ish. Other things like set for custom variables are also code smells.
The CMakeFiles have become a bit messy and seem overcomplicated. I think a modern CMake makeover would help a lot. Things like
FFTW_LINK_FLAGS, for instance, should not be used as such, since linker flags and linking targets are two things that are defined separately, so combining them in one variable is not CMake-ish. Other things likesetfor custom variables are also code smells.