~ubuntu-branches/debian/jessie/systemd/jessie

« back to all changes in this revision

Viewing changes to debian/systemd-hack-up-the-source.hook

  • Committer: Package Import Robot
  • Author(s): Tollef Fog Heen, Tollef Fog Heen, Michael Biebl
  • Date: 2012-04-03 19:59:17 UTC
  • mfrom: (1.1.10) (6.1.3 experimental)
  • Revision ID: package-import@ubuntu.com-20120403195917-l532urrbg4pkreas
Tags: 44-1
[ Tollef Fog Heen ]
* New upstream version.
  - Backport 3492207: journal: PAGE_SIZE is not known on ppc and other
    archs
  - Backport 5a2a2a1: journal: react with immediate rotation to a couple
    of more errors
  - Backport 693ce21: util: never follow symlinks in rm_rf_children()
    Fixes CVE-2012-1174, closes: #664364
* Drop output message from init-functions hook, it's pointless.
* Only rmdir /lib/init/rw if it exists.
* Explicitly order debian-fixup before sysinit.target to prevent a
  possible race condition with the creation of sockets.  Thanks to
  Michael Biebl for debugging this.
* Always restart the initctl socket on upgrades, to mask sysvinit
  removing it.

[ Michael Biebl ]
* Remove workaround for non-interactive sessions from pam config again.
* Create compat /dev/initctl symlink in case we are upgrading from a system
  running a newer version of sysvinit (using /run/initctl) and sysvinit is
  replaced with systemd-sysv during the upgrade. Closes: #663219
* Install new man pages.
* Build-Depend on valac (>= 0.12) instead of valac-0.12. Closes: #663323

Show diffs side-by-side

added added

removed removed

Lines of Context:
4
4
 
5
5
set -x
6
6
 
 
7
. /usr/share/gitpkg/hooks/repo-config-helper
 
8
 
7
9
find -name Makefile -type l -print -delete
8
 
rm -r test1 test2 src/Makefile
9
 
. /usr/share/gitpkg/hooks/quilt-patches-deb-export-hook
 
10
#rm -r  src/Makefile
 
11
#. /usr/share/gitpkg/hooks/quilt-patches-deb-export-hook
 
12
 
 
13
patch_list=debian/source/git-patches
 
14
patch_dir=debian/patches
 
15
 
 
16
if [ ! -r "$patch_list" ]; then
 
17
    echo "No $patch_list file, I guess you've pushed them all upstream."
 
18
    echo "Good Work!"
 
19
    exit 0
 
20
fi
 
21
 
 
22
if [ -e "$patch_dir" ]; then
 
23
    echo "Uh oh.  You already have a $patch_dir here."
 
24
    echo "You probably don't want us to scribble on that without asking."
 
25
    exit 1
 
26
fi
 
27
 
 
28
if [ -z "$REPO_DIR" ]; then
 
29
    # support running as a free-standing script, without gitpkg
 
30
    DEB_VERSION="$(dpkg-parsechangelog | sed -rne 's/^Version: ([^:]+:)?//p')"
 
31
    UPSTREAM_VERSION="${DEB_VERSION%-*}"
 
32
    REPO_DIR=.
 
33
fi
 
34
 
 
35
DEB_REF=$(sanitise_git_ref $DEB_VERSION)
 
36
UPSTREAM_REF="${DEB_REF%-*}"
 
37
 
 
38
do_patches (){
 
39
    while read -r line
 
40
    do
 
41
        [ -n "$line" ] || continue
 
42
        case $line in
 
43
            \#*)
 
44
                ;;
 
45
            *)
 
46
                git --git-dir "$REPO_DIR/.git" diff "$line" > "$patch_dir/$line"
 
47
                echo "$line" >> "$patch_dir/series"
 
48
                ;;
 
49
        esac
 
50
    done
 
51
}
 
52
 
 
53
mkdir -p "$patch_dir" || exit 1
 
54
echo "# $patch_list exported from git by export-hook" > "$patch_dir/series"
 
55
 
 
56
(sed -e "s/\$DEB_VERSION/$DEB_VERSION/g"                \
 
57
    -e "s/\${DEB_VERSION}/$DEB_VERSION/g"               \
 
58
    -e "s/\$UPSTREAM_VERSION/$UPSTREAM_VERSION/g"       \
 
59
    -e "s/\${UPSTREAM_VERSION}/$UPSTREAM_VERSION/g"     \
 
60
    -e "s/\$DEB_REF/$DEB_REF/g"                         \
 
61
    -e "s/\${DEB_REF}/$DEB_REF/g"                       \
 
62
    -e "s/\$UPSTREAM_REF/$UPSTREAM_REF/g"               \
 
63
    -e "s/\${UPSTREAM_REF}/$UPSTREAM_REF/g"             \
 
64
    < "$patch_list" ; echo ) | do_patches || exit 1