patch was mostly straight forward, but someone who is better with C++ than i should probably take a look
Created attachment 263345 [details, diff] hugin-2010.4.0-libpng-1.5.patch
I pulled the latest changes from vigra upstream to fix building with libpng-1.5 for hugin-2011.0.0_rc1 in CVS since the attached patch didn't work properly with <libpng-1.5.