Closed Ron2014 closed 4 years ago
Hmm, not sure what the cmake warning is about, this shouldn't be fips-specific though.
I'm not sure if exec_command
is the right way to do this though, AFAIK this runs an executable while cmake processes the CMakeLists.txt files, not during the build (see here: https://cmake.org/cmake/help/v3.17/command/exec_program.html).
Since the the executable is only created during a build there would be a chicken-egg-problem
I would probably use cmake's add_custom_command
or add_custom_target
in this situation:
https://cmake.org/cmake/help/latest/command/add_custom_command.html
https://cmake.org/cmake/help/latest/command/add_custom_target.html
These allow to run executables during the build process, the only thing you'd need to make sure is that the dependencies are set up properly, so that those custom commands are only running after the executable is built. These are all cmake features though, and should work the same with or without fips.
When I want to build MSVC project of LuaJIT, I found the guide in msvcbuild.bat is
which means
fips_begin_app(minilua cmdline)
first and then execute itIn cmake,
exec_program
can do this, but I get this problem in FIPSbuild & execute, maybe FIPS doesn't support this?