m7wls: split extract script into extracter, makefile writer

Change-Id: I64cb6c95dd27e7f1c088eea3ad4a943436a6ae02