#!/bin/sh
#item   ####description                                      ###on off ###
TMP=/var/log/setup/tmp
if [ ! -d $TMP ]; then
  mkdir -p $TMP
fi
cat /dev/null > $TMP/SeTnewtag
dialog --title "SELECTING PACKAGES FROM SERIES X (X Window System)" \
       --checklist "Please confirm the packages you wish to install \
from series X.  Use the UP/DOWN keys to scroll through the list, and \
the SPACE key to deselect any items you don't want to install.  \
Press ENTER when you are done." \
21 76 11 \
"PyQt" "Python bindings for Qt" "on" \
"fontconfig" "Font configuration library" "on" \
"font-bitstream-type1" "font package for X" "on" \
"libdmx" "libICE is a library for X" "on" \
"libICE" "libICE is a library for X" "on" \
"libSM" "libSM is a library for X" "on" \
"libX11" "libX11 is a library for X" "on" \
"libXau" "libXau is a library for X" "on" \
"libXdmcp" "libXdmcp is a library for X" "on" \
"libXext" "libXext is a library for X" "on" \
"libXpm" "libXpm is a library for X" "on" \
"libXrender" "libXrender is a library for X" "on" \
"libXt" "libXt is a library for X" "on" \
"libxcb" "libxcb is a library for X" "on" \
"libXcomposite" "libXcomposite is a library for X" "on" \
"libXcursor" "libXcursor is a library for X" "on" \
"libXdamage" "libXdamage is a library for X" "on" \
"libXfixes" "libXfixes is a library for X" "on" \
"libXft" "libXft is a library for X" "on" \
"libXi" "libXi is a library for X" "on" \
"libXinerama" "libXinerama is a library for X" "on" \
"libXrandr" "libXrandr is a library for X" "on" \
"pixman" "Low-level pixel manipulation library" "on" \
"sip" "Tool for generating Python bindings" "on" \
"xhost" "server access control program for X" "on" \
"x-kde-addon" "Xorg Server and KDE Desktop enviroment" "off" \
"fluxbox" "Window manager based on blackbox" "off" \
2> $TMP/SeTpkgs
if [ $? = 1 -o $? = 255 ]; then
 rm -f $TMP/SeTpkgs
 > $TMP/SeTnewtag
 for pkg in \
PyQt fontconfig font-bitstream-type1 libdmx libICE libSM libX11 libXau libXdmcp libXext libXpm libXrender libXt libxcb libXcomposite libXcursor libXdamage libXfixes libXft libXi libXinerama libXrandr pixman sip xhost x-kde-addon fluxbox \
  ; do
  echo "$pkg: SKP" >> $TMP/SeTnewtag
 done
 exit
fi
cat /dev/null > $TMP/SeTnewtag
for PACKAGE in \
PyQt fontconfig font-bitstream-type1 libdmx libICE libSM libX11 libXau libXdmcp libXext libXpm libXrender libXt libxcb libXcomposite libXcursor libXdamage libXfixes libXft libXi libXinerama libXrandr pixman sip xhost x-kde-addon fluxbox \
 ; do
 if fgrep \"$PACKAGE\" $TMP/SeTpkgs 1> /dev/null 2> /dev/null ; then
  echo "$PACKAGE: ADD" >> $TMP/SeTnewtag
 else
  echo "$PACKAGE: SKP" >> $TMP/SeTnewtag
 fi
done
rm -f $TMP/SeTpkgs
