Skip to content

Commit 9b4dfec

Browse files
committed
Merge #17029: gitian: Various improvements for Windows descriptor
9d1f971 gitian: Put things in the right place to begin with (Carl Dong) 71949a9 gitian: Eliminate rename dependency (Carl Dong) 999a9a5 gitian: Smaller diff with gitian-linux.yml (Carl Dong) c4a3c25 gitian: Fix README inclusion in archives (Carl Dong) 93cb974 gitian: Use split-debug.sh for Win builds (Carl Dong) Pull request description: It would seem that our `gitian-win.yml` has not been keeping up with `gitian-linux.yml`, this PR: 1. Minimizes the diff size between `gitian-{win,linux}.yml` 2. Eliminates the `rename` dependency ACKs for top commit: laanwj: ACK 9d1f971 Tree-SHA512: 84ed47c685e12d0064c02811907ae3d0fd3c47db8773d497dcc38f0defbfb3040fd82899fb026cf355f229b906d05a1c8038a95642bb90d044afbc2e0b239af2
2 parents 520d140 + 9d1f971 commit 9b4dfec

File tree

2 files changed

+12
-13
lines changed

2 files changed

+12
-13
lines changed

contrib/gitian-descriptors/gitian-linux.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -181,7 +181,7 @@ script: |
181181
rm -rf ${DISTNAME}/lib/pkgconfig
182182
find ${DISTNAME}/bin -type f -executable -print0 | xargs -0 -n1 -I{} ../contrib/devtools/split-debug.sh {} {} {}.dbg
183183
find ${DISTNAME}/lib -type f -print0 | xargs -0 -n1 -I{} ../contrib/devtools/split-debug.sh {} {} {}.dbg
184-
cp ../doc/README.md ${DISTNAME}/
184+
cp ../README.md ${DISTNAME}/
185185
find ${DISTNAME} -not -name "*.dbg" | sort | tar --mtime="$REFERENCE_DATETIME" --no-recursion --mode='u+rw,go+r-w,a+X' --owner=0 --group=0 -c -T - | gzip -9n > ${OUTDIR}/${DISTNAME}-${i}.tar.gz
186186
find ${DISTNAME} -name "*.dbg" | sort | tar --mtime="$REFERENCE_DATETIME" --no-recursion --mode='u+rw,go+r-w,a+X' --owner=0 --group=0 -c -T - | gzip -9n > ${OUTDIR}/${DISTNAME}-${i}-debug.tar.gz
187187
cd ../../

contrib/gitian-descriptors/gitian-win.yml

Lines changed: 11 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,6 @@ packages:
2222
- "zip"
2323
- "ca-certificates"
2424
- "python3"
25-
- "rename"
2625
remotes:
2726
- "url": "https://github.com/bitcoin/bitcoin.git"
2827
"dir": "bitcoin"
@@ -124,14 +123,11 @@ script: |
124123
make dist
125124
SOURCEDIST=`echo bitcoin-*.tar.gz`
126125
DISTNAME=`echo ${SOURCEDIST} | sed 's/.tar.*//'`
127-
128126
# Correct tar file order
129127
mkdir -p temp
130128
pushd temp
131129
tar -xf ../$SOURCEDIST
132130
find bitcoin-* | sort | tar --mtime="$REFERENCE_DATETIME" --no-recursion --mode='u+rw,go+r-w,a+X' --owner=0 --group=0 -c -T - | gzip -9n > ../$SOURCEDIST
133-
mkdir -p $OUTDIR/src
134-
cp ../$SOURCEDIST $OUTDIR/src
135131
popd
136132
137133
# Workaround for tarball not building with the bare tag version (prep)
@@ -157,24 +153,27 @@ script: |
157153
make ${MAKEOPTS} -C src check-security
158154
make deploy
159155
make install DESTDIR=${INSTALLPATH}
160-
rename 's/-setup\.exe$/-setup-unsigned.exe/' *-setup.exe
161-
cp -f bitcoin-*setup*.exe $OUTDIR/
156+
(
157+
SETUP_EXE="$(basename "$(echo ./*-setup.exe)")"
158+
cp -f "$SETUP_EXE" "${OUTDIR}/${SETUP_EXE/%-setup.exe/-setup-unsigned.exe}"
159+
)
162160
cd installed
163161
mv ${DISTNAME}/bin/*.dll ${DISTNAME}/lib/
164162
find . -name "lib*.la" -delete
165163
find . -name "lib*.a" -delete
166164
rm -rf ${DISTNAME}/lib/pkgconfig
167-
find ${DISTNAME}/bin -type f -executable -exec ${i}-objcopy --only-keep-debug {} {}.dbg \; -exec ${i}-strip -s {} \; -exec ${i}-objcopy --add-gnu-debuglink={}.dbg {} \;
168-
find ${DISTNAME}/lib -type f -exec ${i}-objcopy --only-keep-debug {} {}.dbg \; -exec ${i}-strip -s {} \; -exec ${i}-objcopy --add-gnu-debuglink={}.dbg {} \;
169-
find ${DISTNAME} -not -name "*.dbg" -type f | sort | zip -X@ ${OUTDIR}/${DISTNAME}-${i}.zip
170-
find ${DISTNAME} -name "*.dbg" -type f | sort | zip -X@ ${OUTDIR}/${DISTNAME}-${i}-debug.zip
165+
find ${DISTNAME}/bin -type f -executable -print0 | xargs -0 -n1 -I{} ../contrib/devtools/split-debug.sh {} {} {}.dbg
166+
find ${DISTNAME}/lib -type f -print0 | xargs -0 -n1 -I{} ../contrib/devtools/split-debug.sh {} {} {}.dbg
167+
cp ../doc/README_windows.txt ${DISTNAME}/readme.txt
168+
find ${DISTNAME} -not -name "*.dbg" -type f | sort | zip -X@ ${OUTDIR}/${DISTNAME}-${i//x86_64-w64-mingw32/win64}.zip
169+
find ${DISTNAME} -name "*.dbg" -type f | sort | zip -X@ ${OUTDIR}/${DISTNAME}-${i//x86_64-w64-mingw32/win64}-debug.zip
171170
cd ../../
172171
rm -rf distsrc-${i}
173172
done
173+
mkdir -p $OUTDIR/src
174+
mv $SOURCEDIST $OUTDIR/src
174175
cp -rf contrib/windeploy $BUILD_DIR
175176
cd $BUILD_DIR/windeploy
176177
mkdir unsigned
177178
cp $OUTDIR/bitcoin-*setup-unsigned.exe unsigned/
178179
find . | sort | tar --mtime="$REFERENCE_DATETIME" --no-recursion --mode='u+rw,go+r-w,a+X' --owner=0 --group=0 -c -T - | gzip -9n > ${OUTDIR}/${DISTNAME}-win-unsigned.tar.gz
179-
mv ${OUTDIR}/${DISTNAME}-x86_64-*-debug.zip ${OUTDIR}/${DISTNAME}-win64-debug.zip
180-
mv ${OUTDIR}/${DISTNAME}-x86_64-*.zip ${OUTDIR}/${DISTNAME}-win64.zip

0 commit comments

Comments
 (0)