It is strongly recommend to run a pre-migration check on the SharePoint content database before attaching it to trigger the migration process.
Assumptions:
You have already installed the customized wsp package you know
You have restored the content database to SQL server
You haven't attach the content database yet
Steps:
Run SharePoint PowerShell Console as administrator
Run the command below
Test-SPContentDatabase - name WSS_Content_DB - webapplication http://sitename
Check the output log, ensure there isn't any errors