Added pugixml, reorganized common code into a static lib