Ok, maybe I solved it.
I ran the script again from
The first time I got an error
`Copy custom header files
mkdir: cannot create directory
/var/www/max2play/public/addons/squeezeplug': File exists
Then I copied that directory in another location just for backup and ran the script again.
The second time the script ended without errors. I rebooted and everything was ok.
Hope that this helps someone else