Skip to content

Commit

Permalink
build: Consider SOURCE_DATE_EPOCH in Guix environment only
Browse files Browse the repository at this point in the history
  • Loading branch information
hebasto committed Mar 28, 2024
1 parent d1e9a02 commit d871c33
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 3 deletions.
3 changes: 1 addition & 2 deletions Makefile.am
Original file line number Diff line number Diff line change
Expand Up @@ -129,8 +129,7 @@ deploydir: $(OSX_ZIP)
else !BUILD_DARWIN
APP_DIST_DIR=$(top_builddir)/dist

$(OSX_ZIP): deploydir
if [ -n "$(SOURCE_DATE_EPOCH)" ]; then find $(APP_DIST_DIR) -exec touch -d @$(SOURCE_DATE_EPOCH) {} +; fi
$(OSX_ZIP):
cd $(APP_DIST_DIR) && find . | sort | $(ZIP) -X@ $@

$(APP_DIST_DIR)/$(OSX_APP)/Contents/MacOS/Bitcoin-Qt: $(OSX_APP_BUILT) $(OSX_PACKAGING)
Expand Down
4 changes: 3 additions & 1 deletion contrib/guix/libexec/build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -302,6 +302,9 @@ mkdir -p "$DISTSRC"
*darwin*)
make osx_volname ${V:+V=1}
make deploydir ${V:+V=1}
find dist -print0 | xargs -0r touch --no-dereference --date="@${SOURCE_DATE_EPOCH}"
make deploy ${V:+V=1} OSX_ZIP="${OUTDIR}/${DISTNAME}-${HOST}-unsigned.zip"

mkdir -p "unsigned-app-${HOST}"
cp --target-directory="unsigned-app-${HOST}" \
osx_volname \
Expand All @@ -315,7 +318,6 @@ mkdir -p "$DISTSRC"
| gzip -9n > "${OUTDIR}/${DISTNAME}-${HOST}-unsigned.tar.gz" \
|| ( rm -f "${OUTDIR}/${DISTNAME}-${HOST}-unsigned.tar.gz" && exit 1 )
)
make deploy ${V:+V=1} OSX_ZIP="${OUTDIR}/${DISTNAME}-${HOST}-unsigned.zip"
;;
esac
(
Expand Down

0 comments on commit d871c33

Please sign in to comment.