#!/bin/sh
cat /dev/null > /tmp/SeTnewtag
dialog --title "select pkgs from ext(Extra packages)" \
  --checklist "select packages from ext series. \
You can move cursor with UP/DOWN key and push space \
key to select pkgs. After finish selecting, \
push Enter to start installation. " 24 72 15 \
"AV" "Audio/Video related tools" "off" \
"CD_DVDtools" "" "on" \
"Clearlooks" "" "on" \
"Inputmethods" "" "on" \
"Python" "" "on" \
"Qt4" "" "on" \
"apr" "Apache Portable Runtime library" "on" \
"apr_iconv" "APR Iconv" "on" \
"apr_util" "APR Utils" "on" \
"avahi" "avahi, A mDNS/DNS-SD Server" "off" \
"bluez" "" "on" \
"c++_bindings" "C++ bindings" "off" \
"colord" "" "on" \
"dconf" "" "on" \
"desktop_file_utils" "Desktop file utilities for desktop-entry spec" "off" \
"devel2" "" "on" \
"diffstat" "produces graph of changes introduced by a diff file" "on" \
"dmidecode" "" "on" \
"docbook" "" "off" \
"doxygen" "source code documentation generating tool" "on" \
"enchant" "Enchant spell check library" "on" \
"exiv2" "exiv2" "on" \
"ftgl" "" "on" \
"fuse" "Filesystem in User space" "on" \
"glew" "GLEW : OpenGL Extension Wrangler" "on" \
"gnome_parts" "common parts for GNOME/KDE" "off" \
"gparted" "" "on" \
"graphviz" "Graph Visualization Software" "on" \
"gtk+" "GTK+ Toolkit Library 3.x" "off" \
"ifuse" "" "on" \
"jemalloc" "" "on" \
"lcms2" "" "on" \
"libarchive" "libarchive" "on" \
"libatasmart" "" "on" \
"libcanberra" "libcanberra" "on" \
"libdaemon" "library for daemon software" "on" \
"libgphoto2" "libgphoto2: library for digital photography" "on" \
"libgsf" "" "on" \
"libical" "libical: schedule management library" "on" \
"libiodbc" "" "on" \
"libmng" "" "on" \
"libmspack" "" "on" \
"libnotify" "libnotify: event notification library" "on" \
"liboauth" "" "on" \
"libproxy" "libproxy" "on" \
"libspectre" "libsprectre: Postscript rendering library" "on" \
"libunique" "libunique" "on" \
"libunique1" "" "on" \
"libupnp" "" "on" \
"libwnck" "libwnck" "off" \
"loudmouth" "" "on" \
"lua_append" "" "on" \
"lzop" "" "on" \
"mariadb" "" "on" \
"meanwhile" "meanwhile: OSS implementation of Lotus Sametime protocol" "on" \
"mplayer" "" "on" \
"network2" "" "on" \
"ntfs_3g_ntfsprogs" "NTTFS-3g: Tuxera's NTFS implementation" "on" \
"openjpeg" "OpenJpeg: Jpeg2000 library" "on" \
"p11_kit" "" "on" \
"parted" "GNU parted" "on" \
"perl_append" "add-on modules for perl" "off" \
"plamo_desktop_policy" "" "on" \
"python_append" "add-on modules for python" "off" \
"qdbm" "QDBM" "off" \
"qrencode" "" "on" \
"smplayer" "Qt based MPlayer frontend" "on" \
"smplayer_skins" "" "on" \
"smplayer_themes" "" "on" \
"smtube" "" "on" \
"startup_notification" "startup notification library" "on" \
"taglib" "ID3 tag library" "on" \
"tk" "Tk" "on" \
"udisks" "" "on" \
"udisks2" "" "on" \
"unrar" "RAR decompressor" "on" \
"upower" "" "on" \
"usbredir" "USB device redirector" "on" \
"vte" "Virtual Terminal Emulator" "off" \
"vte3" "" "on" \
"x11vnc" "" "on" \
"xapian_core" "" "on" \
"xarchiver" "" "on" \
"xdg_utils" "xdg desktop utility" "on" \
"xine_lib" "xine-lib-1.1.0" "on" \
"xine_ui" "xine-ui-0.99.4" "on" \
"youtube_dl" "Download videos from YouTube.com" "on" \
"zeitgeist" "" "on" \
2> /tmp/SeTpkgs
if [ $? = 1 -o $? = 255 ]; then
  rm -f /tmp/SeTpkgs
  > /tmp/SeTnewtag
  for pkg in AV CD_DVDtools Clearlooks Inputmethods Python Qt4 apr apr_iconv apr_util avahi bluez c++_bindings colord dconf desktop_file_utils devel2 diffstat dmidecode docbook doxygen enchant exiv2 ftgl fuse glew gnome_parts gparted graphviz gtk+ ifuse jemalloc lcms2 libarchive libatasmart libcanberra libdaemon libgphoto2 libgsf libical libiodbc libmng libmspack libnotify liboauth libproxy libspectre libunique libunique1 libupnp libwnck loudmouth lua_append lzop mariadb meanwhile mplayer network2 ntfs_3g_ntfsprogs openjpeg p11_kit parted perl_append plamo_desktop_policy python_append qdbm qrencode smplayer smplayer_skins smplayer_themes smtube startup_notification taglib tk udisks udisks2 unrar upower usbredir vte vte3 x11vnc xapian_core xarchiver xdg_utils xine_lib xine_ui youtube_dl zeitgeist  ; do 
  echo "$pkg: SKP" >> /tmp/SeTnewtag
  done
  exit
fi
cat /dev/null > /tmp/SeTnewtag
for PACKAGE in AV CD_DVDtools Clearlooks Inputmethods Python Qt4 apr apr_iconv apr_util avahi bluez c++_bindings colord dconf desktop_file_utils devel2 diffstat dmidecode docbook doxygen enchant exiv2 ftgl fuse glew gnome_parts gparted graphviz gtk+ ifuse jemalloc lcms2 libarchive libatasmart libcanberra libdaemon libgphoto2 libgsf libical libiodbc libmng libmspack libnotify liboauth libproxy libspectre libunique libunique1 libupnp libwnck loudmouth lua_append lzop mariadb meanwhile mplayer network2 ntfs_3g_ntfsprogs openjpeg p11_kit parted perl_append plamo_desktop_policy python_append qdbm qrencode smplayer smplayer_skins smplayer_themes smtube startup_notification taglib tk udisks udisks2 unrar upower usbredir vte vte3 x11vnc xapian_core xarchiver xdg_utils xine_lib xine_ui youtube_dl zeitgeist  ; do
    if grep "$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
