--- openoffice.org-thesaurus-pl-1.5.orig/debian/postinst
+++ openoffice.org-thesaurus-pl-1.5/debian/postinst
@@ -0,0 +1,13 @@
+#!/bin/sh
+
+set -e
+
+if [ "$1" = "configure" ]; then
+  if [ -x /usr/sbin/update-openoffice-dicts ]; then
+    update-openoffice-dicts
+  fi
+fi
+
+#DEBHELPER#
+
+exit 0
--- openoffice.org-thesaurus-pl-1.5.orig/debian/watch
+++ openoffice.org-thesaurus-pl-1.5/debian/watch
@@ -0,0 +1,2 @@
+version=3
+http://sf.net/synonimy/OOo2-Thesaurus-(.*)\.zip
--- openoffice.org-thesaurus-pl-1.5.orig/debian/postrm
+++ openoffice.org-thesaurus-pl-1.5/debian/postrm
@@ -0,0 +1,13 @@
+#!/bin/sh
+
+set -e
+
+if [ "$1" = "remove" ]; then
+  if [ -x /usr/sbin/update-openoffice-dicts ]; then
+    update-openoffice-dicts
+  fi
+fi
+
+#DEBHELPER#
+
+exit 0
--- openoffice.org-thesaurus-pl-1.5.orig/debian/copyright
+++ openoffice.org-thesaurus-pl-1.5/debian/copyright
@@ -0,0 +1,25 @@
+This package was debianized by Mateusz Skowroński <skowri@gmail.com> on
+Fri, 28 Jul 2006 19:48:41 +0200
+
+It was downloaded from http://synonimy.ux.pl
+
+Copyright (C) 2004-2008 Marcin Miłkowski <milek_pl@users.sourceforge.net>
+
+    This library is free software; you can redistribute it and/or
+    modify it under the terms of the GNU Lesser General Public
+    License, version 2.1, as published by the Free Software Foundation.
+
+    This library 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
+    Lesser General Public License for more details.
+
+    You should have received a copy of the GNU Lesser General Public
+    License along with this library; if not, write to the Free Software
+    Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA  02110-1301  USA
+
+On Debian systems, the complete text of the GNU Lesser General Public
+License, can be found in /usr/share/common-licenses/LGPL-2.1.
+
+The Debian packaging is Copyright (C) 2006-2011, Mateusz Skowroński <skowri@gmail.com>
+and is licensed under the GPL version 2, see `/usr/share/common-licenses/GPL-2'.
--- openoffice.org-thesaurus-pl-1.5.orig/debian/links
+++ openoffice.org-thesaurus-pl-1.5/debian/links
@@ -0,0 +1,2 @@
+/usr/share/mythes/th_pl_PL_v2.idx /usr/share/myspell/dicts/th_pl_PL_v2.idx
+/usr/share/mythes/th_pl_PL_v2.dat /usr/share/myspell/dicts/th_pl_PL_v2.dat
--- openoffice.org-thesaurus-pl-1.5.orig/debian/rules
+++ openoffice.org-thesaurus-pl-1.5/debian/rules
@@ -0,0 +1,50 @@
+#!/usr/bin/make -f
+
+#export DH_VERBOSE=1
+
+build: build-stamp
+build-stamp:
+	dh_testdir
+
+	/usr/share/mythes/th_gen_idx.pl -o th_pl_PL_v2_debian.idx < th_pl_PL_v2.dat
+
+	touch $@
+
+clean:
+	dh_testdir
+	dh_testroot
+	rm -f build-stamp
+
+	rm -f th_pl_PL_v2_debian.idx
+
+	dh_clean
+
+install: build
+	dh_testdir
+	dh_testroot
+	dh_prep
+	
+	install -D -m644 th_pl_PL_v2_debian.idx \
+	    debian/mythes-pl/usr/share/mythes/th_pl_PL_v2.idx
+	install -m644 th_pl_PL_v2.dat \
+	    debian/mythes-pl/usr/share/mythes
+	install -D -m644 debian/dictlistinfo \
+	    debian/mythes-pl/usr/share/myspell/infos/ooo/mythes-pl
+
+binary-indep: build install
+	dh_testdir
+	dh_testroot
+	dh_installchangelogs
+	dh_installdocs debian/copyright
+	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
--- openoffice.org-thesaurus-pl-1.5.orig/debian/compat
+++ openoffice.org-thesaurus-pl-1.5/debian/compat
@@ -0,0 +1 @@
+8
--- openoffice.org-thesaurus-pl-1.5.orig/debian/dictlistinfo
+++ openoffice.org-thesaurus-pl-1.5/debian/dictlistinfo
@@ -0,0 +1 @@
+THES pl PL th_pl_PL_v2
--- openoffice.org-thesaurus-pl-1.5.orig/debian/changelog
+++ openoffice.org-thesaurus-pl-1.5/debian/changelog
@@ -0,0 +1,90 @@
+openoffice.org-thesaurus-pl (1.5-4) unstable; urgency=low
+
+  * Depend on libreoffice-core. (Closes: #617556)
+  * Rename to mythes-pl. (Closes: #617566)
+  * Provide mythes-thesaurus-pl instead of openoffice.org2-thesaurus-pl.
+  * Add ${misc:Depends}. Thanks lintian.
+  * Add debian/source/format. Thanks lintian.
+  * Bump Standards-Version to 3.9.1.
+  * Fix package description.
+  * Use dh_prep instead of deprecated dh_clean.
+  * Switch to debhelper v8.
+  * Update copyright file.
+  * Add Homepage field.
+
+ -- Mateusz Skowronski <skowri@gmail.com>  Sun, 13 Mar 2011 12:01:17 +0100
+
+openoffice.org-thesaurus-pl (1.5-3) unstable; urgency=low
+
+  * Move thesaurus to /usr/share/mythes. (Closes: #541897)
+  * Bump Standards-Version to 3.8.3 (no changes needed).
+  * Update copyright file.
+  * Guard update-openoffice-dicts call with -x.
+
+ -- Mateusz Skowronski <skowri@gmail.com>  Sun, 13 Sep 2009 15:10:41 +0200
+
+openoffice.org-thesaurus-pl (1.5-2) unstable; urgency=low
+
+  * Bump Standards-Version to 3.8.0 (no changes needed).
+  * Add set -e to debian/postrm. Thanks lintian.
+  * Fix package description.
+
+ -- Mateusz Skowronski <skowri@gmail.com>  Sun, 28 Dec 2008 12:26:21 +0100
+
+openoffice.org-thesaurus-pl (1.5-1) unstable; urgency=low
+
+  * New upstream release.
+
+ -- Mateusz Skowronski <skowri@gmail.com>  Sun, 18 May 2008 11:18:23 +0200
+
+openoffice.org-thesaurus-pl (1.4-2) unstable; urgency=low
+
+  * Update copyright file.
+  * Bump Standards-Version to 3.7.3 (no changes needed).
+  * Move libmythes-dev to Build-Depends-Indep. Thanks lintian.
+
+ -- Mateusz Skowronski <skowri@gmail.com>  Wed, 09 Apr 2008 03:48:32 +0200
+
+openoffice.org-thesaurus-pl (1.4-1) unstable; urgency=low
+
+  * New upstream release.
+  * Update copyright file.
+
+ -- Mateusz Skowronski <skowri@gmail.com>  Mon,  7 May 2007 22:35:55 +0200
+
+openoffice.org-thesaurus-pl (1.3-1) unstable; urgency=low
+
+  * New upstream release.
+  * Move to main. Upstream is dual-licensed now. LGPL/OSL2.0
+    Thanks Rene Engelhard. (Closes: #420669)
+
+ -- Mateusz Skowronski <skowri@gmail.com>  Tue, 24 Apr 2007 07:50:01 +0200
+
+openoffice.org-thesaurus-pl (1.2-2) unstable; urgency=low
+
+  * Fix debian/watch file.
+
+ -- Mateusz Skowronski <skowri@gmail.com>  Sun, 26 Nov 2006 11:15:06 +0100
+
+openoffice.org-thesaurus-pl (1.2-1) unstable; urgency=low
+
+  * New upstream release.
+  * Update copyright file.
+  * Add a debian/watch file.
+  * Switch to debhelper v5.
+  * Clean up debian/control and debian/rules. Thanks Daniel Baumann.
+
+ -- Mateusz Skowronski <skowri@gmail.com>  Sat, 14 Oct 2006 19:56:15 +0200
+
+openoffice.org-thesaurus-pl (1.1-2) unstable; urgency=low
+
+  * Move to non-free. Open Software Licence version 2.0 is not
+    considered free according to the DFSG.
+
+ -- Mateusz Skowronski <skowri@gmail.com>  Tue,  8 Aug 2006 03:55:55 +0200
+
+openoffice.org-thesaurus-pl (1.1-1) unstable; urgency=low
+
+  * Initial release.
+
+ -- Mateusz Skowronski <skowri@gmail.com>  Fri, 28 Jul 2006 19:21:03 +0200
--- openoffice.org-thesaurus-pl-1.5.orig/debian/control
+++ openoffice.org-thesaurus-pl-1.5/debian/control
@@ -0,0 +1,21 @@
+Source: openoffice.org-thesaurus-pl
+Section: text
+Priority: optional
+Maintainer: Mateusz Skowronski <skowri@gmail.com>
+Build-Depends: debhelper (>= 8)
+Build-Depends-Indep: libmythes-dev
+Standards-Version: 3.9.1
+Homepage: http://synonimy.ux.pl/
+
+Package: mythes-pl
+Architecture: all
+Depends: libreoffice-core | openoffice.org-core (>= 1.9), dictionaries-common (>= 0.10) | openoffice.org-updatedicts, ${misc:Depends}
+Conflicts: openoffice.org (<< 1.9)
+Provides: mythes-thesaurus, mythes-thesaurus-pl, openoffice.org-thesaurus-pl
+Replaces: openoffice.org-thesaurus-pl
+Description: Polish thesaurus for LibreOffice/OpenOffice.org
+ Openoffice.org is a full-featured office productivity suite that provides a
+ near drop-in replacement for Microsoft(R) Office.
+ .
+ This package contains the Polish thesaurus for
+ LibreOffice/OpenOffice.org.
--- openoffice.org-thesaurus-pl-1.5.orig/debian/source/format
+++ openoffice.org-thesaurus-pl-1.5/debian/source/format
@@ -0,0 +1 @@
+1.0
