Makefile hacks
I love GNU Make. The simplicity of Makefiles makes it an extremely versatile and powerful tool. Here is some Makefile-fu I learned over the years.
I love GNU Make. The simplicity of Makefiles makes it an extremely versatile and powerful tool. Here is some Makefile-fu I learned over the years.
During the autumn semester of 2017 I took the course “Programming Techniques for Scientific Simulations” as part of my BSc course in Computational Science and engineering at ETH Zürich. This is a summary of the course’s contents I wrote and used during the actual exam. Some things are missing, as it was an open-book exam
Building (compiling) large projects can take a long time. Build systems like Make and SCons do a really good job of reusing resources that don’t need recompiling because we didn’t change anything, but compiling a large project for the first time can still take a while. One solution to this issue, especially with multicore and
make is a very useful tool when working on large projects with many dependencies. A C++ project with many header includes, for instance, can quickly get tedious to compile, when at each compilation you must run several commands: g++ -c main.cpp -o lib/main.o g++ -c myfile.cpp -o lib/myfile.o g++ lib/main.o lib/myfile.o -o main What make