Fixing bug for embedded image corruption

Hi,
I fixed a bug where and image was corrupted when using the image-inlinemacro for xhmtl11.
The issue was present on both cygwin and Ubuntu using python 2.7

I also fixed the makefile since the latex2png was renamed to latex2img.
With these changes I was able to install and build my documents.

Thanks,
Peter Bruin