]> granicus.if.org Git - strace/commitdiff
make-dist: generate strace-*.tar.gz, strace.dsc, and strace.spec
authorDmitry V. Levin <ldv@altlinux.org>
Wed, 8 Jun 2016 00:32:22 +0000 (00:32 +0000)
committerDmitry V. Levin <ldv@altlinux.org>
Wed, 8 Jun 2016 09:28:25 +0000 (09:28 +0000)
Change make-dist to generate strace-*.tar.gz, strace.dsc,
and strace.spec in addition to strace-*.tar.xz.

* configure.ac (AM_INIT_AUTOMAKE): Remove no-dist-gzip.
* make-dsc: New file.
* make-dist: Use it.
* .gitignore: Add strace-*.tar.gz, strace.dsc, and strace.spec.

.gitignore
configure.ac
make-dist
make-dsc [new file with mode: 0755]

index f407a17665a6ac53b9b743b5a248856b1e60b24c..68efd603e6ffa1b8795a5f312f39b6ef00999f60 100644 (file)
 /sen.h
 /stamp-h1
 /strace
+/strace-*.tar.gz
 /strace-*.tar.xz
+/strace.dsc
+/strace.spec
 /sys_func.h
 /test-driver
 /tests-m32
index ea89de4313b4db7a5c52b6b4d7104f93252f072d..3f5a340317a1ab1db85bbbfe06f48c2e42096444 100644 (file)
@@ -36,7 +36,7 @@ AC_INIT([strace],
 AC_CONFIG_SRCDIR([strace.c])
 AC_CONFIG_AUX_DIR([.])
 AC_CONFIG_HEADERS([config.h])
-AM_INIT_AUTOMAKE([foreign nostdinc dist-xz no-dist-gzip silent-rules parallel-tests])
+AM_INIT_AUTOMAKE([foreign nostdinc dist-xz silent-rules parallel-tests])
 AM_MAINTAINER_MODE
 AC_CANONICAL_HOST
 
index f0e7296696f5bcf0a9fc78ca0fd0818ca271d71a..9accae760002210c514162a37cee9a7dae2cf287 100755 (executable)
--- a/make-dist
+++ b/make-dist
@@ -28,4 +28,8 @@ else
        echo 'SKIP: make news-check'
 fi
 
-mv -f strace-*.tar.xz ..
+./make-dsc strace-*.tar.gz > ../strace.dsc
+
+cat strace.spec > ../strace.spec
+
+mv -f strace-*.tar.[gx]z ..
diff --git a/make-dsc b/make-dsc
new file mode 100755 (executable)
index 0000000..951c5a9
--- /dev/null
+++ b/make-dsc
@@ -0,0 +1,49 @@
+#!/bin/sh -e
+
+exec < /dev/null
+
+cat <<__EOF__
+Format: 1.0
+$(sed '/^Source:[[:space:]]*/!d;q' debian/control)
+Binary: $(sed '/^Package:[[:space:]]*/!d;s///' debian/control |
+       tr '\n' ' ' | sed 's/ ./,&/g')
+$(sed '/^Architecture:[[:space:]]*/!d;q' debian/control)
+Version: $(sed -n '1s/^[^(]*(\([^)]\+\)).*/\1/p' debian/changelog)
+$(sed '/^Maintainer:[[:space:]]*/!d;q' debian/control)
+$(sed '/^Homepage:[[:space:]]*/!d;q' debian/control)
+$(sed '/^Standards-Version:[[:space:]]*/!d;q' debian/control)
+$(sed '/^Build-Depends:[[:space:]]*/!d;q' debian/control)
+Package-List:
+ strace deb $(
+       sed '/^Section:[[:space:]]*/!d;s///;q' debian/control) $(
+       sed '/^Priority:[[:space:]]*/!d;s///;q' debian/control) arch=$(
+       sed -n "/^Package:[[:space:]]*strace\$/,/^\$/p" debian/control |
+               sed -e '/^Architecture:[[:space:]]*/!d;s///' -e 's/ /,/g')
+ strace64 deb $(sed '/^Section:[[:space:]]*/!d;s///;q' debian/control) $(
+       sed -n "/^Package:[[:space:]]*strace64\$/,/^\$/p" debian/control |
+               sed '/^Priority:[[:space:]]*/!d;s///;q') arch=$(
+       sed -n "/^Package:[[:space:]]*strace64\$/,/^\$/p" debian/control |
+               sed -e '/^Architecture:[[:space:]]*/!d;s///' -e 's/ /,/g')
+ strace-udeb udeb $(
+       sed -n "/^Package:[[:space:]]*strace-udeb\$/,/^\$/p" debian/control |
+               sed '/^Section:[[:space:]]*/!d;s///;q') $(
+       sed -n "/^Package:[[:space:]]*strace-udeb\$/,/^\$/p" debian/control |
+               sed '/^Priority:[[:space:]]*/!d;s///;q') arch=$(
+       sed -n "/^Package:[[:space:]]*strace-udeb\$/,/^\$/p" debian/control |
+               sed -e '/^Architecture:[[:space:]]*/!d;s///' -e 's/ /,/g')
+Checksums-Sha1:
+$(for f; do echo " $(
+       sha1sum -- "$f" | sed 's/ .*//') $(
+       stat -c %s -- "$f") $(
+       echo $f | sed 's/-/_/;s/\.tar/.orig&/')"; done)
+Checksums-Sha256:
+$(for f; do echo " $(
+       sha256sum -- "$f" | sed 's/ .*//') $(
+       stat -c %s -- "$f") $(
+       echo $f | sed 's/-/_/;s/\.tar/.orig&/')"; done)
+Files:
+$(for f; do echo " $(
+       md5sum -- "$f" | sed 's/ .*//') $(
+       stat -c %s -- "$f") $(
+       echo $f | sed 's/-/_/;s/\.tar/.orig&/')"; done)
+__EOF__