[cmake,release] Corrects setting of HAVE_* variables.

For generating the config.h file we use the HAVE_* variables instead
of the CMake ones *_FOUND, Unfortunately, we sometines to not set
HAVE_* to the value of the *_FOUND vriable but to its name. Usually
we only query whether these variable are set at all. While
this often (except for psurface) does not pose a problem, it is semantically
wrong. Therfore this patch fixes this.

Kudos to Ansgar for pointing to this problem.
(cherry picked from commit 64c80e41acd637a1bba64888b1128be8de6dcd8e)

Signed-off-by: Markus Blatt <markus@dr-blatt.de>