Fixed a bug where the scope statement was accessing a variable before it was declared.

This showed up under Linux with DMD 2.066.0 - not sure what caused the difference, as it was fine under Windows and DMD 2.065.
Either way, the code was technically incorrect, so now better.
Added example database connection string.

Also removed the temp folder overide as it causes issues under linux, being a Windows path!
Fixed Issue #8: Linux build script does not account for ImageMagick or DMagick

That was a bear - mostly in the linker commands.  Everything else was pretty straighforward.  Gotta love BASH.