makefiles: update memory config inheritance