Portability fix in model_legos/Makefile