Add -g to CFLAGS and create static library