File: susv3.postinst

package info (click to toggle)
sus 7.20180621
  • links: PTS
  • area: contrib
  • in suites: buster
  • size: 76 kB
  • sloc: sh: 40; makefile: 2
file content (22 lines) | stat: -rw-r--r-- 686 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
#!/bin/sh

set -e

TEMPDIR=$(mktemp -d) || exit 1

echo Fetching file...
wget -P $TEMPDIR http://www.opengroup.org/onlinepubs/007904975/download/susv3.tar.bz2

echo Verifying SHA512 checksum...
SHA512SUM="b1b8a79112d3f41a3d2951341cd9220566f551e5750378bba5cf786a0c381b064fa1a1cfeb6e76e9c6beb85a893cbb6f90879203e9931e9043bcb95b032def40"
[ x"$(sha512sum $TEMPDIR/susv3.tar.bz2 | cut -f1 -d\ )" = x"$SHA512SUM" ] || (rm -rf $TEMPDIR; exit 1)

echo Untarring...
bunzip2 -cd $TEMPDIR/susv3.tar.bz2 | tar xf - -C /usr/share/doc/susv3 --no-same-permissions --no-same-owner

rm -rf $TEMPDIR

## Note: Keep debhelper token after so that files exist when they're being
## registered.

#DEBHELPER#