Attempt at making the code crossplatform

Signed-off-by: lg188 <lander.ghekiere@gmail.com>