Update and rename mtype.h to memlib.h