BUILD: Added an utility function to set linker flags

Signed-off-by: Gama <misept.dieseneuf@gmail.com>
BUILD: Now using our own wrapper variables for system detection

Signed-off-by: Gama <misept.dieseneuf@gmail.com>
BUILD: Minor style fix

Variable reordering.

Signed-off-by: Gama <misept.dieseneuf@gmail.com>