Check for GNOME before setting GNOME-specific properties

Previously, the app crashed when launched in OS X because
of the absence of certain specific properties pertaining
to the GNOME environment.

Untested.