Fix architecture detection problem in makefile