[SCM] The rsync repository. - branch master updated
Rsync CVS commit messages
rsync-cvs at lists.samba.org
Mon Sep 7 06:31:29 UTC 2020
The branch, master has been updated
via f4c3969b Leave git-version.h out of GENFILES so it doesn't go in a release tar.
via ee75e51f Allow git-version.h to be provided for the build
from 9f9240b6 Set CXX_OK=no when cross compiling.
https://git.samba.org/?p=rsync.git;a=shortlog;h=master
- Log -----------------------------------------------------------------
commit f4c3969b63013efbff55b890aa1f25a680e4ebb4
Author: Wayne Davison <wayne at opencoder.net>
Date: Sun Sep 6 23:27:28 2020 -0700
Leave git-version.h out of GENFILES so it doesn't go in a release tar.
commit ee75e51f2f4ca6456ef623e9a09bc17f32b739de
Author: Wayne Davison <wayne at opencoder.net>
Date: Sun Sep 6 22:49:27 2020 -0700
Allow git-version.h to be provided for the build
For a non-git build or for a git build w/o adequate git history, we now
allow the git-version.h file to be provided before the build. If the
file does not exist, we either create an empty file or put a define of
RSYNC_GITVER in it based on the output of git describe. The github
builds now snag the git-version.h file that was generated for the last
commit so that they all get the same version string, even with a shallow
checkout.
-----------------------------------------------------------------------
Summary of changes:
.cirrus.yml | 3 ++-
.github/workflows/build.yml | 11 ++++++-----
Makefile.in | 4 ++--
mkgitver | 15 +++++++++------
usage.c | 4 ++++
5 files changed, 23 insertions(+), 14 deletions(-)
Changeset truncated at 500 lines:
diff --git a/.cirrus.yml b/.cirrus.yml
index 4150bf3c..ba78af7d 100644
--- a/.cirrus.yml
+++ b/.cirrus.yml
@@ -7,7 +7,8 @@ freebsd_task:
prep_script:
- dd if=/dev/zero of=/tmp/zpool bs=1M count=1024
- zpool create -m `pwd`/testtmp zpool /tmp/zpool
- - pkg install -y autotools xxhash zstd liblz4
+ - pkg install -y autotools xxhash zstd liblz4 wget
+ - wget https://download.samba.org/pub/rsync/generated-files/git-version.h
configure_script:
- CPPFLAGS=-I/usr/local/include/ LDFLAGS=-L/usr/local/lib/ ./configure --disable-md2man
make_script:
diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml
index ce5eedf0..f15f737b 100644
--- a/.github/workflows/build.yml
+++ b/.github/workflows/build.yml
@@ -16,11 +16,10 @@ jobs:
runs-on: ubuntu-20.04
steps:
- uses: actions/checkout at v2
- with:
- fetch-depth: 0
- name: prep
run: |
- sudo apt-get install acl libacl1-dev attr libattr1-dev liblz4-dev libzstd-dev libxxhash-dev python3-cmarkgfm openssl
+ sudo apt-get install acl libacl1-dev attr libattr1-dev liblz4-dev libzstd-dev libxxhash-dev python3-cmarkgfm openssl wget
+ wget https://download.samba.org/pub/rsync/generated-files/git-version.h
echo "::add-path::/usr/local/bin"
- name: configure
run: ./configure
@@ -55,8 +54,9 @@ jobs:
- uses: actions/checkout at v2
- name: prep
run: |
- brew install automake openssl xxhash zstd lz4
+ brew install automake openssl xxhash zstd lz4 wget
sudo pip3 install commonmark
+ wget https://download.samba.org/pub/rsync/generated-files/git-version.h
echo "::add-path::/usr/local/bin"
- name: configure
run: CPPFLAGS=-I/usr/local/opt/openssl/include/ LDFLAGS=-L/usr/local/opt/openssl/lib/ ./configure
@@ -91,7 +91,8 @@ jobs:
args: install -y --no-progress cygwin cyg-get
- name: prep
run: |
- cyg-get make autoconf automake gcc-core attr libattr-devel python3 python36-commonmark libzstd-devel liblz4-devel libssl-devel
+ cyg-get make autoconf automake gcc-core attr libattr-devel python3 python36-commonmark libzstd-devel liblz4-devel libssl-devel wget
+ wget https://download.samba.org/pub/rsync/generated-files/git-version.h
echo "::add-path::C:/tools/cygwin/bin"
- name: configure
run: bash -c './configure --disable-xxhash'
diff --git a/Makefile.in b/Makefile.in
index 2b55d9f7..21a77540 100644
--- a/Makefile.in
+++ b/Makefile.in
@@ -171,7 +171,7 @@ gen: conf proto.h man
.PHONY: gensend
gensend: gen
- rsync -aic $(GENFILES) $${SAMBA_HOST-samba.org}:/home/ftp/pub/rsync/generated-files/
+ rsync -aic $(GENFILES) git-version.h $${SAMBA_HOST-samba.org}:/home/ftp/pub/rsync/generated-files/
aclocal.m4: $(srcdir)/m4/*.m4
aclocal -I $(srcdir)/m4
@@ -254,7 +254,7 @@ rsyncd.conf.5: rsyncd.conf.5.md md2man version.h Makefile
.PHONY: clean
clean: cleantests
rm -f *~ $(OBJS) $(CHECK_PROGS) $(CHECK_OBJS) $(CHECK_SYMLINKS) \
- rounding rounding.h *.old rsync*.1 rsync*.5 rsync*.html \
+ git-version.h rounding rounding.h *.old rsync*.1 rsync*.5 rsync*.html \
daemon-parm.h help-*.h default-*.h proto.h proto.h-tstamp
.PHONY: cleantests
diff --git a/mkgitver b/mkgitver
index c0dd1b5f..8e76774c 100755
--- a/mkgitver
+++ b/mkgitver
@@ -3,9 +3,12 @@
srcdir=`dirname $0`
gitver=`git describe --abbrev=8 2>/dev/null`
-if test x"$gitver" != x; then
- gitver=\""$gitver"\"
-else
- gitver=RSYNC_VERSION
-fi
-echo "#define RSYNC_GITVER $gitver" >git-version.h
+case "$gitver" in
+ *.*)
+ echo "#define RSYNC_GITVER \"$gitver\"" >git-version.h
+ ;;
+ *)
+ # We either create an empty file or update the time on what the user gave us.
+ touch git-version.h
+ ;;
+esac
diff --git a/usage.c b/usage.c
index 2b5f3761..f427263e 100644
--- a/usage.c
+++ b/usage.c
@@ -253,7 +253,11 @@ void daemon_usage(enum logcode F)
const char *rsync_version(void)
{
+#ifdef RSYNC_GITVER
return RSYNC_GITVER;
+#else
+ return RSYNC_VERSION;
+#endif
}
const char *default_cvsignore(void)
--
The rsync repository.
More information about the rsync-cvs
mailing list