aboutsummaryrefslogtreecommitdiff
path: root/debian
diff options
context:
space:
mode:
authortoni <matzeton@googlemail.com>2014-04-12 02:27:35 +0200
committertoni <matzeton@googlemail.com>2014-04-12 02:27:35 +0200
commit47b459fe55a098076bd167f8b13d79e3a0705d1d (patch)
tree3c62b6ae46bd0f784a27f079d11d43811ae41066 /debian
initial commit
Diffstat (limited to 'debian')
-rw-r--r--debian/README.Debian6
-rw-r--r--debian/README.source9
-rw-r--r--debian/changelog5
-rw-r--r--debian/compat1
-rw-r--r--debian/control15
-rw-r--r--debian/copyright38
-rw-r--r--debian/docs0
-rw-r--r--debian/postinst42
-rw-r--r--debian/postrm35
-rw-r--r--debian/preinst42
-rwxr-xr-xdebian/rules13
-rw-r--r--debian/source/format1
12 files changed, 207 insertions, 0 deletions
diff --git a/debian/README.Debian b/debian/README.Debian
new file mode 100644
index 0000000..b54397b
--- /dev/null
+++ b/debian/README.Debian
@@ -0,0 +1,6 @@
+naskpass for Debian
+-------------------
+
+<possible notes regarding this package - if none, delete this file>
+
+ -- Toni Uhlig <matzeton@googlemail.com> Sun, 30 Mar 2014 22:59:32 +0200
diff --git a/debian/README.source b/debian/README.source
new file mode 100644
index 0000000..c58010d
--- /dev/null
+++ b/debian/README.source
@@ -0,0 +1,9 @@
+naskpass for Debian
+-------------------
+
+<this file describes information about the source package, see Debian policy
+manual section 4.14. You WILL either need to modify or delete this file>
+
+
+
+
diff --git a/debian/changelog b/debian/changelog
new file mode 100644
index 0000000..89e5a8f
--- /dev/null
+++ b/debian/changelog
@@ -0,0 +1,5 @@
+naskpass (1.0-1) unstable; urgency=low
+
+ * Initial release (Closes: #nnnn) <nnnn is the bug number of your ITP>
+
+ -- Toni Uhlig <matzeton@googlemail.com> Sun, 30 Mar 2014 22:59:32 +0200
diff --git a/debian/compat b/debian/compat
new file mode 100644
index 0000000..45a4fb7
--- /dev/null
+++ b/debian/compat
@@ -0,0 +1 @@
+8
diff --git a/debian/control b/debian/control
new file mode 100644
index 0000000..f1af7c3
--- /dev/null
+++ b/debian/control
@@ -0,0 +1,15 @@
+Source: naskpass
+Section: unknown
+Priority: extra
+Maintainer: Toni Uhlig <matzeton@googlemail.com>
+Build-Depends: debhelper (>= 8.0.0), libncurses5-dev, libtinfo-dev
+Standards-Version: 3.9.3
+Homepage: https://github.com/freecoding/naskpass.git
+#Vcs-Git: git://git.debian.org/collab-maint/naskpass.git
+#Vcs-Browser: http://git.debian.org/?p=collab-maint/naskpass.git;a=summary
+
+Package: naskpass
+Architecture: any
+Depends: ${shlibs:Depends}, ${misc:Depends}, libncurses5, libtinfo5
+Description: Ncurses based cryptsetup askpass replacement
+ NULL.
diff --git a/debian/copyright b/debian/copyright
new file mode 100644
index 0000000..1fdb272
--- /dev/null
+++ b/debian/copyright
@@ -0,0 +1,38 @@
+Format: http://www.debian.org/doc/packaging-manuals/copyright-format/1.0/
+Upstream-Name: naskpass
+Source: <url://example.com>
+
+Files: *
+Copyright: <years> <put author's name and email here>
+ <years> <likewise for another author>
+License: <special license>
+ <Put the license of the package here indented by 1 space>
+ <This follows the format of Description: lines in control file>
+ .
+ <Including paragraphs>
+
+# If you want to use GPL v2 or later for the /debian/* files use
+# the following clauses, or change it to suit. Delete these two lines
+Files: debian/*
+Copyright: 2014 Toni Uhlig <matzeton@googlemail.com>
+License: GPL-2+
+ This package 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.
+ .
+ This package 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, see <http://www.gnu.org/licenses/>
+ .
+ On Debian systems, the complete text of the GNU General
+ Public License version 2 can be found in "/usr/share/common-licenses/GPL-2".
+
+# Please also look if there are files or directories which have a
+# different copyright/license attached and list them here.
+# Please avoid to pick license terms that are more restrictive than the
+# packaged work, as it may make Debian's contributions unacceptable upstream.
diff --git a/debian/docs b/debian/docs
new file mode 100644
index 0000000..e69de29
--- /dev/null
+++ b/debian/docs
diff --git a/debian/postinst b/debian/postinst
new file mode 100644
index 0000000..e3cf5b0
--- /dev/null
+++ b/debian/postinst
@@ -0,0 +1,42 @@
+#!/bin/sh
+# postinst script for naskpass
+#
+# see: dh_installdeb(1)
+
+set -e
+
+
+export RDSUM="5924c70e5c9fabf0398050349c3f4f283ab80091b23ea8c677249ee7bdd41f6e4910ce5e1bc32577e67763dc30d9b96cc3528256e1cc63dba959a5e3866ec21f"
+export ORGFILE="/usr/share/initramfs-tools/scripts/local-top/cryptroot"
+export DIVFILE="/usr/share/naskpass/cryptroot.orig"
+
+case "$1" in
+ install)
+ mkdir -p /usr/share/naskpass
+ if [ ! -f ${ORGFILE} ]; then
+ whiptail --title "Missing file" --msgbox "/usr/share/initramfs-tools/scripts/local-top/cryptroot is missing!\nabort .." 9 70
+ else
+ if [ ${RDSUM} = "$(/usr/bin/sha512sum ${ORGFILE} | grep -Eo '^[0-9a-zA-Z]*')" ]; then
+ dpkg-divert --package naskpass --divert ${DIVFILE} --rename --add ${ORGFILE}
+ else
+ whiptail --title "Wrong SHA checksum" --msgbox "in /usr/share/initramfs-tools/scripts/local-top/cryptroot\n\nabort .." 9 70
+ fi
+ fi
+ ;;
+
+ upgrade|configure)
+ update-initramfs -u
+ ;;
+
+ *)
+ echo "postinst called with unknown argument \`$1'" >&2
+ exit 1
+ ;;
+esac
+
+# dh_installdeb will replace this with shell code automatically
+# generated by other debhelper scripts.
+
+#DEBHELPER#
+
+exit 0
diff --git a/debian/postrm b/debian/postrm
new file mode 100644
index 0000000..12bde65
--- /dev/null
+++ b/debian/postrm
@@ -0,0 +1,35 @@
+#!/bin/sh
+# postrm script for naskpass
+#
+# see: dh_installdeb(1)
+
+set -e
+
+
+export ORGFILE="/usr/share/initramfs-tools/scripts/local-top/cryptroot"
+
+case "$1" in
+ purge)
+ ;;
+ remove)
+ dpkg-divert --package naskpass --remove --rename ${ORGFILE}
+ update-initramfs -u
+ ;;
+ upgrade|failed-upgrade|abort-install|abort-upgrade|disappear)
+ if [ -d /usr/share/naskpass ]; then
+ rmdir --ignore-fail-on-non-empty /usr/share/naskpass
+ fi
+ ;;
+
+ *)
+ echo "postrm called with unknown argument \`$1'" >&2
+ exit 1
+ ;;
+esac
+
+# dh_installdeb will replace this with shell code automatically
+# generated by other debhelper scripts.
+
+#DEBHELPER#
+
+exit 0
diff --git a/debian/preinst b/debian/preinst
new file mode 100644
index 0000000..0e9ba2d
--- /dev/null
+++ b/debian/preinst
@@ -0,0 +1,42 @@
+#!/bin/sh
+# postinst script for naskpass
+#
+# see: dh_installdeb(1)
+
+set -e
+
+
+export RDSUM="5924c70e5c9fabf0398050349c3f4f283ab80091b23ea8c677249ee7bdd41f6e4910ce5e1bc32577e67763dc30d9b96cc3528256e1cc63dba959a5e3866ec21f"
+export ORGFILE="/usr/share/initramfs-tools/scripts/local-top/cryptroot"
+export DIVFILE="/usr/share/naskpass/cryptroot.orig"
+
+case "$1" in
+ install)
+ mkdir -p /usr/share/naskpass
+ if [ ! -f ${ORGFILE} ]; then
+ whiptail --title "Missing file" --msgbox "/usr/share/initramfs-tools/scripts/local-top/cryptroot is missing!\nabort .." 9 70
+ else
+ if [ ${RDSUM} = "$(/usr/bin/sha512sum ${ORGFILE} | grep -Eo '^[0-9a-zA-Z]*')" ]; then
+ dpkg-divert --package naskpass --divert ${DIVFILE} --rename --add ${ORGFILE}
+ update-initramfs -u
+ else
+ whiptail --title "Wrong SHA checksum" --msgbox "in /usr/share/initramfs-tools/scripts/local-top/cryptroot\n\nabort .." 9 70
+ fi
+ fi
+ ;;
+
+ upgrade)
+ ;;
+
+ *)
+ echo "postinst called with unknown argument \`$1'" >&2
+ exit 1
+ ;;
+esac
+
+# dh_installdeb will replace this with shell code automatically
+# generated by other debhelper scripts.
+
+#DEBHELPER#
+
+exit 0
diff --git a/debian/rules b/debian/rules
new file mode 100755
index 0000000..3f5e541
--- /dev/null
+++ b/debian/rules
@@ -0,0 +1,13 @@
+#!/usr/bin/make -f
+
+# Uncomment this to turn on verbose mode.
+#export DH_VERBOSE=1
+
+%:
+ dh $@
+
+override_dh_auto_install:
+ echo "*** REDIRECT INITRAMFS SCRIPT" >&2
+ $(MAKE) DESTDIR=$(CURDIR)/debian/naskpass install
+ mkdir -p $(CURDIR)/debian/naskpass/usr/share/initramfs-tools/scripts/local-top
+ mv $(CURDIR)/debian/naskpass/usr/share/naskpass/naskpass.script.initramfs $(CURDIR)/debian/naskpass/usr/share/initramfs-tools/scripts/local-top/cryptroot
diff --git a/debian/source/format b/debian/source/format
new file mode 100644
index 0000000..163aaf8
--- /dev/null
+++ b/debian/source/format
@@ -0,0 +1 @@
+3.0 (quilt)