mirror of
https://github.com/bitcoin/bitcoin.git
synced 2025-01-10 20:03:34 -03:00
1f59885d27
17f81e9648
script: Enable SC2001 rule for Gitian scripts (Hennadii Stepanov)61bb21b418
script: Enable SC2155 rule for Gitian scripts (Hennadii Stepanov)577682d9e8
script: Enable SC2006 rule for Gitian scripts (Hennadii Stepanov)14aded46df
script: Lint Gitian descriptors with ShellCheck (Hennadii Stepanov) Pull request description: This PR extracts shell scripts from Gitian descriptors (`contrib/gitian-descriptors/`) and checks for ShellCheck warnings as any other one. Some non-controversial warnings are fixed. ACKs for top commit: practicalswift: ACK17f81e9648
-- diff looks correct Tree-SHA512: bdfa3d35bbb65ff634c90835d75c3df63e958b558599771d21366724f5cf64da83a68957d926e926a99c3704b9529e96a17697dc8d9ff3adf7154d9cb1999a8d
40 lines
1.2 KiB
YAML
40 lines
1.2 KiB
YAML
---
|
|
name: "bitcoin-dmg-signer"
|
|
distro: "ubuntu"
|
|
suites:
|
|
- "bionic"
|
|
architectures:
|
|
- "linux64"
|
|
packages:
|
|
- "faketime"
|
|
remotes:
|
|
- "url": "https://github.com/bitcoin-core/bitcoin-detached-sigs.git"
|
|
"dir": "signature"
|
|
files:
|
|
- "bitcoin-osx-unsigned.tar.gz"
|
|
script: |
|
|
set -e -o pipefail
|
|
|
|
WRAP_DIR=$HOME/wrapped
|
|
mkdir -p ${WRAP_DIR}
|
|
export PATH="$PWD":$PATH
|
|
FAKETIME_PROGS="dmg genisoimage"
|
|
|
|
# Create global faketime wrappers
|
|
for prog in ${FAKETIME_PROGS}; do
|
|
echo '#!/usr/bin/env bash' > ${WRAP_DIR}/${prog}
|
|
echo "REAL=\`which -a ${prog} | grep -v ${WRAP_DIR}/${prog} | head -1\`" >> ${WRAP_DIR}/${prog}
|
|
echo "export LD_PRELOAD='/usr/\$LIB/faketime/libfaketime.so.1'" >> ${WRAP_DIR}/${prog}
|
|
echo "export FAKETIME=\"${REFERENCE_DATETIME}\"" >> ${WRAP_DIR}/${prog}
|
|
echo "\$REAL \$@" >> $WRAP_DIR/${prog}
|
|
chmod +x ${WRAP_DIR}/${prog}
|
|
done
|
|
|
|
UNSIGNED=bitcoin-osx-unsigned.tar.gz
|
|
SIGNED=bitcoin-osx-signed.dmg
|
|
|
|
tar -xf ${UNSIGNED}
|
|
OSX_VOLNAME="$(cat osx_volname)"
|
|
./detached-sig-apply.sh ${UNSIGNED} signature/osx
|
|
${WRAP_DIR}/genisoimage -no-cache-inodes -D -l -probe -V "${OSX_VOLNAME}" -no-pad -r -dir-mode 0755 -apple -o uncompressed.dmg signed-app
|
|
${WRAP_DIR}/dmg dmg uncompressed.dmg ${OUTDIR}/${SIGNED}
|