Ben Engbers
Ben Engbers

Reputation: 453

Eclipse CMake gives different result depending on generator that is used

In Eclipse I have developed a c++ client for the Basex XML-database.
The default generator when starting a new CMake project is cmake -G "Eclipse CDT4 - Unix Makefiles" -DCMAKE_ECLIPSE_VERSION=4.18 -DCMAKE_BUILD_TYPE=Debug. Using this generator, the client executes a test-file without errors.
Outside the Eclipse development environment I created a new CMake project but his time I used the following generator cmake -S . -B Build/Debug --fresh --preset=dev-linux -DCMAKE_BUILD_TYPE=Debug -G Ninja. The same code compiles without errors but when executing the test, execution is aborted with this message: double free or corruption (out).
valgrind reports dozens of errors. I inspected the code but I can't find any errors.

What could be the cause of the different results? Could it still be programming errors or could it also be related to other compiler settings?

Ben

Upvotes: 0

Views: 22

Answers (0)

Related Questions