aboutsummaryrefslogtreecommitdiff
path: root/contrib
diff options
context:
space:
mode:
Diffstat (limited to 'contrib')
-rwxr-xr-xcontrib/devtools/symbol-check.py10
-rw-r--r--contrib/gitian-descriptors/gitian-linux.yml1
-rw-r--r--contrib/gitian-descriptors/gitian-osx.yml2
-rw-r--r--contrib/guix/README.md11
-rwxr-xr-xcontrib/guix/guix-build.sh11
-rw-r--r--contrib/guix/libexec/build.sh26
-rw-r--r--contrib/guix/manifest.scm16
-rwxr-xr-xcontrib/verifybinaries/verify.py4
8 files changed, 50 insertions, 31 deletions
diff --git a/contrib/devtools/symbol-check.py b/contrib/devtools/symbol-check.py
index b30ed62521..436f179d61 100755
--- a/contrib/devtools/symbol-check.py
+++ b/contrib/devtools/symbol-check.py
@@ -73,6 +73,8 @@ ELF_ALLOWED_LIBRARIES = {
'ld-linux-riscv64-lp64d.so.1', # 64-bit RISC-V dynamic linker
# bitcoin-qt only
'libxcb.so.1', # part of X11
+'libxkbcommon.so.0', # keyboard keymapping
+'libxkbcommon-x11.so.0', # keyboard keymapping
'libfontconfig.so.1', # font support
'libfreetype.so.6', # font parsing
'libdl.so.2' # programming interface to dynamic linker
@@ -98,10 +100,15 @@ MACHO_ALLOWED_LIBRARIES = {
'CoreGraphics', # 2D rendering
'CoreServices', # operating system services
'CoreText', # interface for laying out text and handling fonts.
+'CoreVideo', # video processing
'Foundation', # base layer functionality for apps/frameworks
'ImageIO', # read and write image file formats.
'IOKit', # user-space access to hardware devices and drivers.
+'IOSurface', # cross process image/drawing buffers
'libobjc.A.dylib', # Objective-C runtime library
+'Metal', # 3D graphics
+'Security', # access control and authentication
+'QuartzCore', # animation
}
PE_ALLOWED_LIBRARIES = {
@@ -116,12 +123,15 @@ PE_ALLOWED_LIBRARIES = {
'dwmapi.dll', # desktop window manager
'GDI32.dll', # graphics device interface
'IMM32.dll', # input method editor
+'NETAPI32.dll',
'ole32.dll', # component object model
'OLEAUT32.dll', # OLE Automation API
'SHLWAPI.dll', # light weight shell API
+'USERENV.dll',
'UxTheme.dll',
'VERSION.dll', # version checking
'WINMM.dll', # WinMM audio API
+'WTSAPI32.dll',
}
class CPPFilt(object):
diff --git a/contrib/gitian-descriptors/gitian-linux.yml b/contrib/gitian-descriptors/gitian-linux.yml
index b06fc782a3..52e2a0514a 100644
--- a/contrib/gitian-descriptors/gitian-linux.yml
+++ b/contrib/gitian-descriptors/gitian-linux.yml
@@ -11,6 +11,7 @@ packages:
- "autoconf"
- "automake"
- "binutils"
+- "bison"
- "bsdmainutils"
- "ca-certificates"
- "curl"
diff --git a/contrib/gitian-descriptors/gitian-osx.yml b/contrib/gitian-descriptors/gitian-osx.yml
index 0dc531df0e..98c3888b45 100644
--- a/contrib/gitian-descriptors/gitian-osx.yml
+++ b/contrib/gitian-descriptors/gitian-osx.yml
@@ -21,9 +21,7 @@ packages:
- "bsdmainutils"
- "cmake"
- "imagemagick"
-- "libcap-dev"
- "libz-dev"
-- "libbz2-dev"
- "python3"
- "python3-dev"
- "python3-setuptools"
diff --git a/contrib/guix/README.md b/contrib/guix/README.md
index e218ba89a0..1122ec9ba5 100644
--- a/contrib/guix/README.md
+++ b/contrib/guix/README.md
@@ -103,8 +103,8 @@ find output/ -type f -print0 | sort -z | xargs -r0 sha256sum
Override the space-separated list of platform triples for which to perform a
bootstrappable build. _(defaults to "x86\_64-linux-gnu arm-linux-gnueabihf
- aarch64-linux-gnu riscv64-linux-gnu x86_64-w64-mingw32
- x86_64-apple-darwin18")_
+ aarch64-linux-gnu riscv64-linux-gnu powerpc64-linux-gnu powerpc64le-linux-gnu
+ x86\_64-w64-mingw32 x86\_64-apple-darwin18")_
* _**SOURCES_PATH**_
@@ -118,6 +118,13 @@ find output/ -type f -print0 | sort -z | xargs -r0 sha256sum
depends tree. Setting this to the same directory across multiple builds of the
depends tree can eliminate unnecessary building of packages.
+* _**SDK_PATH**_
+
+ Set the path where _extracted_ SDKs can be found. This is passed through to
+ the depends tree. Note that this is should be set to the _parent_ directory of
+ the actual SDK (e.g. SDK_PATH=$HOME/Downloads/macOS-SDKs instead of
+ $HOME/Downloads/macOS-SDKs/Xcode-11.3.1-11C505-extracted-SDK-with-libcxx-headers).
+
* _**MAX_JOBS**_
Override the maximum number of jobs to run simultaneously, you might want to
diff --git a/contrib/guix/guix-build.sh b/contrib/guix/guix-build.sh
index 7af132b240..7c32fb5726 100755
--- a/contrib/guix/guix-build.sh
+++ b/contrib/guix/guix-build.sh
@@ -9,7 +9,7 @@ set -e -o pipefail
################
# Check 1: Make sure that we can invoke required tools
################
-for cmd in git make guix cat mkdir; do
+for cmd in git make guix cat mkdir curl; do
if ! command -v "$cmd" > /dev/null 2>&1; then
echo "ERR: This script requires that '$cmd' is installed and available in your \$PATH"
exit 1
@@ -163,7 +163,7 @@ SOURCE_DATE_EPOCH="${SOURCE_DATE_EPOCH:-$(git log --format=%at -1)}"
time-machine() {
# shellcheck disable=SC2086
guix time-machine --url=https://github.com/dongcarl/guix.git \
- --commit=6c9d16db962a6f7155571b36eced681fd2889e23 \
+ --commit=490e39ff303f4f6873a04bfb8253755bdae1b29c \
--max-jobs="$MAX_JOBS" \
--keep-failed \
${SUBSTITUTE_URLS:+--substitute-urls="$SUBSTITUTE_URLS"} \
@@ -196,10 +196,11 @@ and untracked files and directories will be wiped, allowing you to start anew.
EOF
}
-# Create SOURCES_PATH and BASE_CACHE if they are non-empty so that we can map
-# them into the container
+# Create SOURCES_PATH, BASE_CACHE, and SDK_PATH if they are non-empty so that we
+# can map them into the container
[ -z "$SOURCES_PATH" ] || mkdir -p "$SOURCES_PATH"
[ -z "$BASE_CACHE" ] || mkdir -p "$BASE_CACHE"
+[ -z "$SDK_PATH" ] || mkdir -p "$SDK_PATH"
# Deterministically build Bitcoin Core
# shellcheck disable=SC2153
@@ -302,6 +303,7 @@ EOF
--expose="$(git rev-parse --git-common-dir)" \
${SOURCES_PATH:+--share="$SOURCES_PATH"} \
${BASE_CACHE:+--share="$BASE_CACHE"} \
+ ${SDK_PATH:+--share="$SDK_PATH"} \
--max-jobs="$MAX_JOBS" \
--keep-failed \
${SUBSTITUTE_URLS:+--substitute-urls="$SUBSTITUTE_URLS"} \
@@ -312,6 +314,7 @@ EOF
${V:+V=1} \
${SOURCES_PATH:+SOURCES_PATH="$SOURCES_PATH"} \
${BASE_CACHE:+BASE_CACHE="$BASE_CACHE"} \
+ ${SDK_PATH:+SDK_PATH="$SDK_PATH"} \
DISTSRC="$(DISTSRC_BASE=/distsrc-base && distsrc_for_host "$HOST")" \
OUTDIR=/outdir \
bash -c "cd /bitcoin && bash contrib/guix/libexec/build.sh"
diff --git a/contrib/guix/libexec/build.sh b/contrib/guix/libexec/build.sh
index 72588c54a7..051066a6a0 100644
--- a/contrib/guix/libexec/build.sh
+++ b/contrib/guix/libexec/build.sh
@@ -3,6 +3,16 @@ export LC_ALL=C
set -e -o pipefail
export TZ=UTC
+# Although Guix _does_ set umask when building its own packages (in our case,
+# this is all packages in manifest.scm), it does not set it for `guix
+# environment`. It does make sense for at least `guix environment --container`
+# to set umask, so if that change gets merged upstream and we bump the
+# time-machine to a commit which includes the aforementioned change, we can
+# remove this line.
+#
+# This line should be placed before any commands which creates files.
+umask 0022
+
if [ -n "$V" ]; then
# Print both unexpanded (-v) and expanded (-x) forms of commands as they are
# read from this file.
@@ -48,17 +58,10 @@ unset C_INCLUDE_PATH
unset CPLUS_INCLUDE_PATH
case "$HOST" in
*darwin*)
- # When targeting darwin, some native tools built by depends require
- # native packages not incorporated in depends
- #
- # libcap required by native_cdrkit/wodim
- # zlib, bzip2 required by native_cdrkit/genisoimage
- for native_pkg in libcap zlib bzip2; do
- native_pkg_store_path=$(store_path "$native_pkg")
- export LIBRARY_PATH="${native_pkg_store_path}/lib:${LIBRARY_PATH}"
- export CPATH="${native_pkg_store_path}/include:${CPATH}"
- done
- ;;
+ # When targeting darwin, zlib is required by native_libdmg-hfsplus.
+ zlib_store_path=$(store_path "zlib")
+ export LIBRARY_PATH="${zlib_store_path}/lib:${LIBRARY_PATH}"
+ export CPATH="${zlib_store_path}/include:${CPATH}"
esac
# Set environment variables to point the CROSS toolchain to the right
@@ -174,6 +177,7 @@ make -C depends --jobs="$MAX_JOBS" HOST="$HOST" \
${V:+V=1} \
${SOURCES_PATH+SOURCES_PATH="$SOURCES_PATH"} \
${BASE_CACHE+BASE_CACHE="$BASE_CACHE"} \
+ ${SDK_PATH+SDK_PATH="$SDK_PATH"} \
i686_linux_CC=i686-linux-gnu-gcc \
i686_linux_CXX=i686-linux-gnu-g++ \
i686_linux_AR=i686-linux-gnu-ar \
diff --git a/contrib/guix/manifest.scm b/contrib/guix/manifest.scm
index fb585b7f25..4228532cb1 100644
--- a/contrib/guix/manifest.scm
+++ b/contrib/guix/manifest.scm
@@ -3,6 +3,7 @@
(gnu packages autotools)
(gnu packages base)
(gnu packages bash)
+ (gnu packages bison)
(gnu packages cdrom)
(gnu packages check)
(gnu packages cmake)
@@ -125,9 +126,9 @@ chain for " target " development."))
(define* (make-bitcoin-cross-toolchain target
#:key
- (base-gcc-for-libc gcc-5)
- (base-kernel-headers linux-libre-headers-4.19)
- (base-libc glibc-2.27)
+ (base-gcc-for-libc gcc-7)
+ (base-kernel-headers linux-libre-headers-5.4)
+ (base-libc glibc) ; glibc 2.31
(base-gcc (make-gcc-rpath-link gcc-9)))
"Convenience wrapper around MAKE-CROSS-TOOLCHAIN with default values
desirable for building Bitcoin Core release binaries."
@@ -219,6 +220,7 @@ chain for " target " development."))
autoconf
automake
pkg-config
+ bison
;; Scripting
perl
python-3
@@ -232,14 +234,8 @@ chain for " target " development."))
(list zip
(make-mingw-pthreads-cross-toolchain "x86_64-w64-mingw32")
(make-nsis-with-sde-support nsis-x86_64)))
- ((string-contains target "riscv64-linux-")
- (list (make-bitcoin-cross-toolchain target
- #:base-gcc-for-libc gcc-7)))
- ((string-contains target "powerpc64le-linux-")
- (list (make-bitcoin-cross-toolchain target
- #:base-gcc-for-libc gcc-7)))
((string-contains target "-linux-")
(list (make-bitcoin-cross-toolchain target)))
((string-contains target "darwin")
- (list clang-8 libcap binutils imagemagick libtiff librsvg font-tuffy cmake xorriso))
+ (list clang-8 binutils imagemagick libtiff librsvg font-tuffy cmake xorriso))
(else '())))))
diff --git a/contrib/verifybinaries/verify.py b/contrib/verifybinaries/verify.py
index b97ad11b8e..6cbaf2dc0c 100755
--- a/contrib/verifybinaries/verify.py
+++ b/contrib/verifybinaries/verify.py
@@ -51,7 +51,7 @@ def download_with_wget(remote_file, local_file=None):
if local_file:
wget_args = ['wget', '-O', local_file, remote_file]
else:
- # use timestamping mechanism if local filename is not explicitely set
+ # use timestamping mechanism if local filename is not explicitly set
wget_args = ['wget', '-N', remote_file]
result = subprocess.run(wget_args,
@@ -85,7 +85,7 @@ def main(args):
print("Error: need to specify a version on the command line")
return 3
- # determine remote dir dependend on provided version string
+ # determine remote dir dependent on provided version string
version_base, version_rc, os_filter = parse_version_string(args[0])
remote_dir = f"/bin/{VERSIONPREFIX}{version_base}/"
if version_rc: