aboutsummaryrefslogtreecommitdiff
path: root/maint/make-dist
blob: 30b3a8924dd62eb786a2594851f7fe75c2d7c644 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
#!/bin/sh -e
#
# Copyright (c) 2009-2020 The strace developers.
# All rights reserved.
#
# SPDX-License-Identifier: LGPL-2.1-or-later

id="$(git rev-parse --verify "${1:-@}^{commit}")"

distdir=Linux-PAM-dist-$$
abs_distdir="`pwd`/$distdir"
trap 'chmod -Rf u+w $abs_distdir; rm -rf $abs_distdir' 1 2 15 0

set -x
git clone -q -n -s .git "$distdir"

cd $distdir
git config advice.detachedHead false
git checkout -f "$id"

mkdir build
meson setup --buildtype=debugoptimized -Dwerror=true build
meson dist -C build
mv -f build/meson-dist/Linux-PAM-*.tar.* ..