maedoc / libtvb

TVB C library
6 stars 8 forks source link

Replace makefile #149

Closed maedoc closed 8 years ago

maedoc commented 8 years ago

The basic makefile approach has become a headache due to different build configurations, compiler variations (and this, for a no-dep pure C99 lib). I don't expect this to get easier. Usually, this is divided into a configure & build step, like in CMake or autocont. CMake is great for cross-platform builds if your CMakeLists.txt is written correctly. Autoconf is not portable. Both require non-standard dependency to be installed.

Projects like MRtrix have gone with entirely custom Python based configure & build scripts, and this is worth looking at in this project.

Current configurations

profiling instrumentation flags are set to one of

Sanitizers These are only available starting with arbitrary versions of GCC/Clang of course.

The address sanitizer does similar work to valgrind for invalid read/writes but seems to be much faster. Not sure if it catches all the same things, and it does not catch memory leaks (I think).

Targets / actions

maedoc commented 8 years ago

Let's suck it up and use CMake, I guess all this can be figured out.