Accelerating build processes with multithreading

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

gnuplot revisited

Here is a more sophisticated example of using gnuplot: set terminal png size 1920, 1080 enhanced font ‘Verdana,15’ # Different log scales set logscale x 2 set logscale y 10 # %L is the exponent of the current log scale set format y “%g” set format x “2e%L” # Move the legend to the top

Cmake basics

We already know make, a powerful tool to automate all kinds of building sequences. But if you are using it to compile large C++ projects, you will quickly find that it’s tedious to maintain, and that you’re often repeating the same commands over and over again. This, of course, opens up the door to mistakes

A simple gnuplot example

gnuplot is a very easy-to-use tool allowing us to quickly plot data we generated with, for instance, a C++ program. Here is a sample gnuplot script – see a brief explanation of the commands below: set terminal png size 900,675 enhanced font ‘Verdana,9’; set output ‘error_plot.png’; set logscale xy; show logscale; set format xy “%g”;

Compiling C++ libraries

If you use C++, you’ve almost certainly already used a library of some kind. Even the classic “Hello world” program requires one: #include <iostream> // include the iostream library int main() { std::cout << “Hello world!”; return 0; } But what if we wanted to write our own? This has several advantages. First off, if

Automating builds with Make

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

Git cheat sheet

Here are the git commands I most frequently use, along with a brief description of what they are used for. Setting up git init: create a new repository of the current directory. Creating commits git status: show the current status of the git repository, along with staged and untracked files. git add <filename>: add <filename>

Enabling “reading mode” on your website

Many modern browsers nowadays have a sort of “reading mode”, which, when activated, will attempt to automatically extract content from a page and present it to the user in a more reader-friendly environment. In Firefox, this is called “Reader View”, and can be found as a little book icon in the URL bar or under