depends libx11 &&

if list_find $XLOCKMORE_OPTS "--disable-blank-only"; then
  optional_depends MESA \
                   "--with-mesa" \
                   "--without-mesa" \
                   "for Mesa 3D modes" &&

  optional_depends OPENGL \
                   "--with-opengl" \
                   "--without-opengl" \
                   "for 3D OpenGL modes" &&

  optional_depends freetype2 \
                   "--with-freetype" \
                   "--without-freetype" \
                   "for FreeType mode(s)" &&

  optional_depends libxpm \
                   "--with-xpm" \
                   "--without-xpm" \
                   "for color pixmap XPM mode(s)"
else
  list_add XLOCKMORE_OPTS "--without-mesa" &&
  list_add XLOCKMORE_OPTS "--without-opengl" &&
  list_add XLOCKMORE_OPTS "--without-freetype" &&
  list_add XLOCKMORE_OPTS "--without-xpm"
fi &&

optional_depends libxinerama \
                 "--with-xinerama" \
                 "--without-xinerama" \
                 "for Xinerama support" &&

optional_depends gltt \
                 "--with-gltt" \
                 "--without-gltt" \
                 "for GL True Text" &&

optional_depends ftgl \
                 "--with-ftgl" \
                 "--without-ftgl" \
                 "for GL font rendering" &&

optional_depends esound \
                 "--with-esound" \
                 "--without-esound" \
                 "for Enlightenment Sound Daemon sounds" &&

optional_depends nas \
                 "--with-nas" \
                 "--without-nas" \
                 "for NAS sounds" &&

optional_depends rplay \
                 "--with-rplay" \
                 "--without-rplay" \
                 "for RPLAY sounds" &&

optional_depends openmotif \
                 "--with-motif" \
                 "--without-motif" \
                 "for Motif support (xmlock build)" &&

optional_depends gtk+2 \
                 "--with-gtk2" \
                 "--without-gtk2" \
                 "for GTK+2 support (xglock build)" &&

if is_depends_enabled $SPELL gtk+2; then
  list_add XLOCKMORE_OPTS "--without-gtk"
else
  optional_depends gtk+ \
                   "--with-gtk" \
                   "--without-gtk" \
                   "for GTK+ support (xglock build)"
fi &&

optional_depends imagemagick \
                 "--with-magick" \
                 "--without-magick" \
                 "for ImageMagick support" &&

optional_depends SYSTEM-LOGGER \
                 "--enable-syslog" \
                 "--disable-syslog" \
                 "for syslog logging" &&

optional_depends krb5 \
                 "--enable-kerberos5" \
                 "--disable-kerberos5" \
                 "for Kerberos 5 support" &&

optional_depends linux-pam \
                 "--enable-pam" \
                 "--disable-pam" \
                 "for PAM authentication"
