always use "git archive" tarballs
This commit is contained in:
parent
ee6fc81588
commit
e074d0f41a
@ -2,17 +2,14 @@
|
|||||||
set -e
|
set -e
|
||||||
|
|
||||||
NAME=systemd
|
NAME=systemd
|
||||||
UPSTREAM=git://anongit.freedesktop.org/systemd/systemd
|
UPSTREAM=git@github.com:systemd/systemd.git
|
||||||
REFDIR="$HOME/git/systemd" # for faster cloning, if available
|
|
||||||
|
|
||||||
|
|
||||||
[ -n "$1" ] && HEAD="$1" || HEAD="HEAD"
|
[ -n "$1" ] && HEAD="$1" || HEAD="HEAD"
|
||||||
|
|
||||||
WORKDIR="$(mktemp -d --tmpdir "$NAME.XXXXXXXXXX")"
|
WORKDIR="$(mktemp -d --tmpdir "$NAME.XXXXXXXXXX")"
|
||||||
trap 'rm -rf $WORKDIR' exit
|
trap 'rm -rf $WORKDIR' exit
|
||||||
|
|
||||||
[ -d "$REFDIR" ] && REFERENCE="--reference $REFDIR"
|
git clone "$UPSTREAM" "$WORKDIR"
|
||||||
git clone $REFERENCE "$UPSTREAM" "$WORKDIR"
|
|
||||||
|
|
||||||
pushd "$WORKDIR" > /dev/null
|
pushd "$WORKDIR" > /dev/null
|
||||||
git branch to-archive $HEAD
|
git branch to-archive $HEAD
|
||||||
|
12
systemd.spec
12
systemd.spec
@ -25,7 +25,7 @@ Summary: A System and Service Manager
|
|||||||
# Snapshot tarball can be created using: ./make-git-shapshot.sh [gitcommit]
|
# Snapshot tarball can be created using: ./make-git-shapshot.sh [gitcommit]
|
||||||
Source0: %{name}-git%{gitcommit}.tar.xz
|
Source0: %{name}-git%{gitcommit}.tar.xz
|
||||||
%else
|
%else
|
||||||
Source0: http://www.freedesktop.org/software/systemd/%{name}-%{version}.tar.xz
|
Source0: %{name}-%{version}.tar.xz
|
||||||
%endif
|
%endif
|
||||||
|
|
||||||
# Prevent accidental removal of the systemd package
|
# Prevent accidental removal of the systemd package
|
||||||
@ -87,11 +87,9 @@ BuildRequires: gnu-efi gnu-efi-devel
|
|||||||
# https://bugzilla.redhat.com/show_bug.cgi?id=1071284
|
# https://bugzilla.redhat.com/show_bug.cgi?id=1071284
|
||||||
BuildRequires: libseccomp-devel
|
BuildRequires: libseccomp-devel
|
||||||
%endif
|
%endif
|
||||||
%if %{defined gitcommit}%{num_patches}
|
|
||||||
BuildRequires: automake
|
BuildRequires: automake
|
||||||
BuildRequires: autoconf
|
BuildRequires: autoconf
|
||||||
BuildRequires: libtool
|
BuildRequires: libtool
|
||||||
%endif
|
|
||||||
%if %{num_patches}
|
%if %{num_patches}
|
||||||
BuildRequires: git
|
BuildRequires: git
|
||||||
%endif
|
%endif
|
||||||
@ -256,13 +254,7 @@ sed -r -i 's/\blibsystemd-(login|journal|id128|daemon).c \\/\\/' Makefile.am
|
|||||||
%endif
|
%endif
|
||||||
|
|
||||||
%build
|
%build
|
||||||
%if %{defined gitcommit}
|
./autogen.sh
|
||||||
./autogen.sh
|
|
||||||
%else
|
|
||||||
%if %{num_patches}
|
|
||||||
autoreconf -i
|
|
||||||
%endif
|
|
||||||
%endif
|
|
||||||
|
|
||||||
%{?fedora: %global ntpvendor fedora}
|
%{?fedora: %global ntpvendor fedora}
|
||||||
%{?rhel: %global ntpvendor rhel}
|
%{?rhel: %global ntpvendor rhel}
|
||||||
|
Loading…
Reference in New Issue
Block a user