change flags to ldflags