add Makefile for testing framework
[BUGFIX] incur writing header error when reconstructing header with -13