Restructure and convert to gradle

Signed-off-by: Jonas Kalderstam <jonas@kalderstam.se>