I've created a patch in master but it will help only in similar cases for >5.1 upgrade tarballs, to solve the problem with 5.0.1 tarball we need to backport it.
I've created a patch in master but it will help only in similar cases for >5.1 upgrade tarballs, to solve the problem with 5.0.1 tarball we need to backport it.