--- dictem-1.0.2.orig/debian/dotemacs.el
+++ dictem-1.0.2/debian/dotemacs.el
@@ -0,0 +1,9 @@
+(require 'dictem)
+(setq dictem-server "pc233")
+(dictem-initialize)
+(global-set-key "\C-cs" 'dictem-run-search)
+(global-set-key "\C-cm" 'dictem-run-match)
+(global-set-key "\C-cd" 'dictem-run-define)
+(global-set-key "\C-c\M-r" 'dictem-run-show-server)
+(global-set-key "\C-c\M-i" 'dictem-run-show-info)
+(global-set-key "\C-c\M-b" 'dictem-run-show-databases)
--- dictem-1.0.2.orig/debian/docs
+++ dictem-1.0.2/debian/docs
@@ -0,0 +1,4 @@
+README
+NEWS
+AUTHORS
+
--- dictem-1.0.2.orig/debian/control
+++ dictem-1.0.2/debian/control
@@ -0,0 +1,24 @@
+Source: dictem
+Section: text
+Priority: optional
+Maintainer: Yauheni Kaliuta <y.kaliuta@gmail.com>
+Build-Depends: debhelper (>= 5.0.0)
+Uploaders: Igor Stroh <jenner@debian.org>
+Standards-Version: 3.8.3
+Homepage: http://www.mova.org/~cheusov/pub/dictem
+
+Package: dictem
+Architecture: all
+Depends: dict (>> 1.9.14), emacs23 | emacsen
+Provides: dict-client
+Description: Dict client for emacs
+ DictEm implements all functions of the client part of Dictionary
+ Server Protocol(DICT) protocol (RFC-2229, www.dict.org), i.e looking
+ up words and definitions, obtaining information about available
+ strategies, provided databases, information about DICT server etc.
+ .
+ It uses autocompletion that is used for selecting dictionary and 
+ search strategy.  Moreover, DictEm provides several hooks which 
+ may be used for buffer postprocessing.
+ .
+
--- dictem-1.0.2.orig/debian/rules
+++ dictem-1.0.2/debian/rules
@@ -0,0 +1,41 @@
+#!/usr/bin/make -f
+# -*- makefile -*-
+#export DH_VERBOSE=1
+
+build: build-stamp
+
+build-stamp:
+	dh_testdir
+	touch build-stamp
+
+clean:
+	dh_testdir
+	dh_testroot
+	rm -f build-stamp 
+	dh_clean 
+
+install: build
+	dh_testdir
+	dh_testroot
+	dh_clean -k 
+	dh_installdirs
+	install -m644 dictem.el \
+		$(CURDIR)/debian/dictem/usr/share/emacs/site-lisp/dictem/
+
+binary-indep: build install
+	dh_testdir
+	dh_testroot
+	dh_installchangelogs ChangeLog
+	dh_installdocs
+	dh_installemacsen
+	dh_link
+	dh_compress
+	dh_fixperms
+	dh_installdeb
+	dh_gencontrol
+	dh_md5sums
+	dh_builddeb
+
+binary-arch: build install
+binary: binary-indep binary-arch
+.PHONY: build clean binary-indep binary-arch binary install 
--- dictem-1.0.2.orig/debian/dirs
+++ dictem-1.0.2/debian/dirs
@@ -0,0 +1,2 @@
+usr/share/emacs/site-lisp/dictem
+
--- dictem-1.0.2.orig/debian/emacsen-remove
+++ dictem-1.0.2/debian/emacsen-remove
@@ -0,0 +1,15 @@
+#!/bin/sh -e
+# /usr/lib/emacsen-common/packages/remove/dictem
+
+FLAVOR=$1
+PACKAGE=dictem
+
+if [ ${FLAVOR} != emacs ]; then
+    if test -x /usr/sbin/install-info-altdir; then
+        echo remove/${PACKAGE}: removing Info links for ${FLAVOR}
+        install-info-altdir --quiet --remove --dirname=${FLAVOR} /usr/info/dictem.info.gz
+    fi
+
+    echo remove/${PACKAGE}: purging byte-compiled files for ${FLAVOR}
+    rm -rf /usr/share/${FLAVOR}/site-lisp/${PACKAGE}
+fi
--- dictem-1.0.2.orig/debian/changelog
+++ dictem-1.0.2/debian/changelog
@@ -0,0 +1,97 @@
+dictem (1.0.2-1) unstable; urgency=low
+
+  * New upstream release, see NEWS. Closes: #541281
+  * Install symlink in the flavour directory. Closes: #541287
+  * Update packaging:
+    - Homepage is a regular field;
+    - depends on current emacs23 first;
+    - copyright points to GPL-2.
+    - Standards-Version: 3.8.3
+
+ -- Yauheni Kaliuta <y.kaliuta@gmail.com>  Sun, 16 Aug 2009 14:16:41 +0300
+
+dictem (0.8-1) unstable; urgency=low
+
+  * New upstream release, see NEWS.
+  * Fixed maintainer's name.
+  * Updated Standards-Version to 3.7.2 -- no changes to package.
+  * Updated debhelper dependency to version 5.
+
+ -- Yauheni Kaliuta <y.kaliuta@gmail.com>  Tue,  7 Nov 2006 23:07:07 +0200
+
+dictem (0.0.5-3) unstable; urgency=low
+
+  * Added debian-pkg-add-load-path-item check
+    to startup file to conform to emacs-policy (point 9).
+
+ -- Zhenja Kaluta <y.kaliuta@gmail.com>  Sat, 24 Sep 2005 00:27:10 +0300
+
+dictem (0.0.5-2) unstable; urgency=low
+
+  * Fixed startup file to use debian-pkg-add-load-path-item. 
+    Closes: #328714
+  * Fixed FSF address in the debian/copyright.
+
+ -- Zhenja Kaluta <y.kaliuta@gmail.com>  Thu, 22 Sep 2005 19:26:23 +0300
+
+dictem (0.0.5-1) unstable; urgency=low
+
+  * New upstream release (0.0.5).
+  * Updated Standards-Version to 3.6.2 - no changes to package.
+
+ -- Zhenja Kaluta <y.kaliuta@gmail.com>  Tue,  9 Aug 2005 17:36:20 +0300
+
+dictem (0.0.4-1) unstable; urgency=low
+
+  * New upstream release (0.0.4).
+
+ -- Zhenja Kaluta <y.kaliuta@gmail.com>  Mon, 25 Apr 2005 17:06:49 +0300
+
+dictem (0.0.3-1) unstable; urgency=low
+
+  * New upstream release (0.0.3). Closes: #285704
+  * Added NEWS and AUTHORS files to documentation.
+
+ -- Zhenja Kaluta <y.kaliuta@gmail.com>  Wed, 15 Dec 2004 18:20:41 +0200
+
+dictem (0.0.2-1) unstable; urgency=low
+
+  * New upstream release (0.0.2).
+    Closes: #283897
+
+ -- Zhenja Kaluta <y.kaliuta@gmail.com>  Wed,  1 Dec 2004 14:34:29 +0200
+
+dictem (0.0.1-4) unstable; urgency=low
+
+  * Fixed description.
+  * Removed maintainer's scripts.
+  * Upload sponsored by Dmitry Borodaenko <angdraug@debian.org>.
+    Closes: #275149 (ITP)
+
+ -- Zhenja Kaluta <y.kaliuta@gmail.com>  Fri,  8 Oct 2004 18:51:08 +0300
+
+dictem (0.0.1-3) unstable; urgency=low
+
+  * Fixed upstream's e-mail and url.
+  * Removed README.Debian.
+  * Minor fixes in debian/rules.
+  * Fixed dependences.
+  * Fixed lintian warnings.
+  * Fixed description.
+
+ -- Zhenja Kaluta <y.kaliuta@gmail.com>  Thu, 30 Sep 2004 12:35:27 +0300
+
+dictem (0.0.1-2) unstable; urgency=low
+
+  * Fixed architecture.
+  * Updated description.
+  * Removed executable from dictem.el.
+
+ -- Zhenja Kaluta <y.kaliuta@gmail.com>  Tue, 28 Sep 2004 17:00:47 +0300
+
+dictem (0.0.1-1) unstable; urgency=low
+
+  * Initial Release.
+
+ -- Zhenja Kaluta <y.kaliuta@gmail.com>  Fri, 24 Sep 2004 12:38:21 +0300
+
--- dictem-1.0.2.orig/debian/emacsen-install
+++ dictem-1.0.2/debian/emacsen-install
@@ -0,0 +1,51 @@
+#! /bin/sh -e
+# /usr/lib/emacsen-common/packages/install/dictem
+
+# Written by Jim Van Zandt <jrv@vanzandt.mv.com>, borrowing heavily
+# from the install scripts for gettext by Santiago Vila
+# <sanvila@ctv.es> and octave by Dirk Eddelbuettel <edd@debian.org>.
+
+FLAVOR=$1
+PACKAGE=dictem
+
+if [ ${FLAVOR} = emacs ]; then exit 0; fi
+
+#FLAVORTEST=`echo $FLAVOR | cut -c-6`
+#if [ ${FLAVORTEST} = xemacs ] ; then
+#    SITEFLAG="-no-site-file"
+#else
+#    SITEFLAG="--no-site-file"
+#fi
+FLAGS="${SITEFLAG} -q -batch -l path.el -f batch-byte-compile"
+
+LOG=`tempfile -pelc_ -s.log -m644`
+ELDIR=/usr/share/emacs/site-lisp/${PACKAGE}
+ELCDIR=/usr/share/${FLAVOR}/site-lisp/${PACKAGE}
+
+echo install/${PACKAGE}: Handling ${FLAVOR}, logged in ${LOG}
+
+# Install-info-altdir does not actually exist. 
+# Maybe somebody will write it.
+if test -x /usr/sbin/install-info-altdir; then
+    echo install/${PACKAGE}: install Info links for ${FLAVOR}
+    install-info-altdir --quiet --section "" "" --dirname=${FLAVOR} /usr/info/${PACKAGE}.info.gz
+fi
+
+install -m 755 -d ${ELCDIR}
+cd ${ELDIR}
+FILES=`echo *.el`
+cd ${ELCDIR}
+for i in $FILES; do
+    ln -fs /usr/share/emacs/site-lisp/${PACKAGE}/$i
+done
+
+cat << EOF > path.el
+(setq load-path (cons "." load-path) byte-compile-warnings nil)
+EOF
+echo ${FLAVOR} ${FLAGS} ${FILES} >> ${LOG}
+${FLAVOR} ${FLAGS} ${FILES} >> ${LOG} 2>&1
+egrep -s -e "While compiling|\*\*" ${LOG} || /bin/true
+echo install/${PACKAGE}: Deleting ${LOG}
+rm -f path.el ${LOG}
+
+exit 0
--- dictem-1.0.2.orig/debian/emacsen-startup
+++ dictem-1.0.2/debian/emacsen-startup
@@ -0,0 +1,10 @@
+;; -*-emacs-lisp-*-
+;;
+;; Emacs startup file for the Debian dictem package
+;;
+
+(when (fboundp 'debian-pkg-add-load-path-item)
+  (debian-pkg-add-load-path-item
+   (concat "/usr/share/"
+	   (symbol-name debian-emacs-flavor)
+	   "/site-lisp/dictem")))
--- dictem-1.0.2.orig/debian/compat
+++ dictem-1.0.2/debian/compat
@@ -0,0 +1,2 @@
+5
+
--- dictem-1.0.2.orig/debian/copyright
+++ dictem-1.0.2/debian/copyright
@@ -0,0 +1,27 @@
+This package was debianized by Zhenja Kaluta <y.kaliuta@gmail.com> on
+Fri, 24 Sep 2004 12:38:21 +0300.
+
+Downloaded From: http://www.mova.org/~cheusov/pub/dictem/
+
+Upstream Author: Aleksey Cheusov <vle@gmx.net>
+
+Copyright (c) 2003, 2004 Aleksey Cheusov <vle@gmx.net>
+
+   DictEm is free software; you can redistribute it and/or modify
+   it under the terms of the GNU General Public License as published by
+   the Free Software Foundation; either version 2 of the License, or
+   (at your option) any later version.
+
+   DictEm is distributed in the hope that it will be useful,
+   but WITHOUT ANY WARRANTY; without even the implied warranty of
+   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+   GNU General Public License for more details.
+
+   You should have received a copy of the GNU General Public License
+   along with this program; if not, write to the Free Software
+   Foundation, 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, 
+   USA
+
+On Debian systems, the complete text of the GNU General
+Public License can be found in `/usr/share/common-licenses/GPL-2'.
+
