Exporting a site template from a Publishing site is not supported by Microsoft (for more information about this, Stefan Gossner has a solid answer here). This is why the "Save site as template" option is not present in publishing sites. You can export the pages anyhow by tacking on a "_layouts/savetmpl.aspx" to the site, but you will get really odd behavior. I've tried to do this before, but every time I've tried to import it, Visual Studio crashes. You can rename the WSP as a CAB file and pull individual files out and try to use code from them in a fresh solution, but you shouldn't use site templates on the publishing infrastructure. Site definitions are your answer here unfortunately.
Regarding deactivating publishing and saving as a template, Gossner also addresses that:
"Also be aware that deactivating the publishing feature and creating a
template of the site will not lead to a supported template! The
problem is that the template would still contain all the
artefacts[sic] of a publishing site like Pages library and various
different properties. Creating a template of a site which previously
had the publishing feature activated is unsupported in the same way as
creating a template from a site which has the publishing feature
activated."