aboutsummaryrefslogtreecommitdiff
path: root/depends
diff options
context:
space:
mode:
Diffstat (limited to 'depends')
-rw-r--r--depends/README.md62
-rw-r--r--depends/packages/native_cctools.mk5
-rw-r--r--depends/packages/native_cdrkit.mk28
-rw-r--r--depends/packages/packages.mk2
-rw-r--r--depends/patches/native_cctools/segalign.patch19
-rw-r--r--depends/patches/native_cdrkit/cdrkit-deterministic.patch86
6 files changed, 45 insertions, 157 deletions
diff --git a/depends/README.md b/depends/README.md
index bf8f829848..085e0e6054 100644
--- a/depends/README.md
+++ b/depends/README.md
@@ -80,48 +80,30 @@ For linux S390X cross compilation:
sudo apt-get install g++-s390x-linux-gnu binutils-s390x-linux-gnu
### Dependency Options
+
The following can be set when running make: `make FOO=bar`
-<dl>
-<dt>SOURCES_PATH</dt>
-<dd>downloaded sources will be placed here</dd>
-<dt>BASE_CACHE</dt>
-<dd>built packages will be placed here</dd>
-<dt>SDK_PATH</dt>
-<dd>Path where sdk's can be found (used by macOS)</dd>
-<dt>FALLBACK_DOWNLOAD_PATH</dt>
-<dd>If a source file can't be fetched, try here before giving up</dd>
-<dt>NO_QT</dt>
-<dd>Don't download/build/cache qt and its dependencies</dd>
-<dt>NO_QR</dt>
-<dd>Don't download/build/cache packages needed for enabling qrencode</dd>
-<dt>NO_ZMQ</dt>
-<dd>Don't download/build/cache packages needed for enabling zeromq</dd>
-<dt>NO_WALLET</dt>
-<dd>Don't download/build/cache libs needed to enable the wallet</dd>
-<dt>NO_BDB</dt>
-<dd>Don't download/build/cache BerkeleyDB</dd>
-<dt>NO_SQLITE</dt>
-<dd>Don't download/build/cache SQLite</dd>
-<dt>NO_UPNP</dt>
-<dd>Don't download/build/cache packages needed for enabling upnp</dd>
-<dt>ALLOW_HOST_PACKAGES</dt>
-<dd>Packages that are missed in dependencies (due to `NO_*` option or
-build script logic) are searched for among the host system packages using
-`pkg-config`. It allows building with packages of other (newer) versions</dd>
-<dt>MULTIPROCESS</dt>
-<dd>build libmultiprocess (experimental, requires cmake)</dd>
-<dt>DEBUG</dt>
-<dd>disable some optimizations and enable more runtime checking</dd>
-<dt>HOST_ID_SALT</dt>
-<dd>Optional salt to use when generating host package ids</dd>
-<dt>BUILD_ID_SALT</dt>
-<dd>Optional salt to use when generating build package ids</dd>
-<dt>FORCE_USE_SYSTEM_CLANG</dt>
-<dd>(EXPERTS ONLY) When cross-compiling for macOS, use Clang found in the
-system's <code>$PATH</code> rather than the default prebuilt release of Clang
-from llvm.org. Clang 8 or later is required.</dd>
-</dl>
+- `SOURCES_PATH`: Downloaded sources will be placed here
+- `BASE_CACHE`: Built packages will be placed here
+- `SDK_PATH`: Path where SDKs can be found (used by macOS)
+- `FALLBACK_DOWNLOAD_PATH`: If a source file can't be fetched, try here before giving up
+- `NO_QT`: Don't download/build/cache Qt and its dependencies
+- `NO_QR`: Don't download/build/cache packages needed for enabling qrencode
+- `NO_ZMQ`: Don't download/build/cache packages needed for enabling ZeroMQ
+- `NO_WALLET`: Don't download/build/cache libs needed to enable the wallet
+- `NO_BDB`: Don't download/build/cache BerkeleyDB
+- `NO_SQLITE`: Don't download/build/cache SQLite
+- `NO_UPNP`: Don't download/build/cache packages needed for enabling UPnP
+- `ALLOW_HOST_PACKAGES`: Packages that are missed in dependencies (due to `NO_*` option or
+ build script logic) are searched for among the host system packages using
+ `pkg-config`. It allows building with packages of other (newer) versions
+- `MULTIPROCESS`: Build libmultiprocess (experimental, requires CMake)
+- `DEBUG`: Disable some optimizations and enable more runtime checking
+- `HOST_ID_SALT`: Optional salt to use when generating host package ids
+- `BUILD_ID_SALT`: Optional salt to use when generating build package ids
+- `FORCE_USE_SYSTEM_CLANG`: (EXPERTS ONLY) When cross-compiling for macOS, use Clang found in the
+ system's `$PATH` rather than the default prebuilt release of Clang
+ from llvm.org. Clang 8 or later is required.
If some packages are not built, for example `make NO_WALLET=1`, the appropriate
options will be passed to bitcoin's configure. In this case, `--disable-wallet`.
diff --git a/depends/packages/native_cctools.mk b/depends/packages/native_cctools.mk
index d56b636695..33f69375cc 100644
--- a/depends/packages/native_cctools.mk
+++ b/depends/packages/native_cctools.mk
@@ -4,7 +4,7 @@ $(package)_download_path=https://github.com/tpoechtrager/cctools-port/archive
$(package)_file_name=$($(package)_version).tar.gz
$(package)_sha256_hash=e51995a843533a3dac155dd0c71362dd471597a2d23f13dff194c6285362f875
$(package)_build_subdir=cctools
-$(package)_patches=ld64_disable_threading.patch
+$(package)_patches=ld64_disable_threading.patch segalign.patch
ifeq ($(strip $(FORCE_USE_SYSTEM_CLANG)),)
$(package)_clang_version=8.0.0
@@ -80,7 +80,8 @@ endef
define $(package)_preprocess_cmds
CC=$($(package)_cc) CXX=$($(package)_cxx) INSTALLPREFIX=$($(package)_extract_dir) ./libtapi/build.sh && \
CC=$($(package)_cc) CXX=$($(package)_cxx) INSTALLPREFIX=$($(package)_extract_dir) ./libtapi/install.sh && \
- patch -p1 < $($(package)_patch_dir)/ld64_disable_threading.patch
+ patch -p1 < $($(package)_patch_dir)/ld64_disable_threading.patch && \
+ patch -p1 < $($(package)_patch_dir)/segalign.patch
endef
define $(package)_config_cmds
diff --git a/depends/packages/native_cdrkit.mk b/depends/packages/native_cdrkit.mk
deleted file mode 100644
index 7bdf2d7dfd..0000000000
--- a/depends/packages/native_cdrkit.mk
+++ /dev/null
@@ -1,28 +0,0 @@
-package=native_cdrkit
-$(package)_version=1.1.11
-$(package)_download_path=https://distro.ibiblio.org/fatdog/source/600/c
-$(package)_file_name=cdrkit-$($(package)_version).tar.bz2
-$(package)_sha256_hash=b50d64c214a65b1a79afe3a964c691931a4233e2ba605d793eb85d0ac3652564
-$(package)_patches=cdrkit-deterministic.patch
-
-define $(package)_preprocess_cmds
- patch -p1 < $($(package)_patch_dir)/cdrkit-deterministic.patch
-endef
-
-# Starting with 10.1, GCC defaults to -fno-common, resulting in linking errors.
-# Pass -fcommon to retain the legacy behaviour.
-define $(package)_config_cmds
- $($(package)_cmake) -DCMAKE_C_FLAGS="$$($(1)_cflags) -fcommon"
-endef
-
-define $(package)_build_cmds
- $(MAKE) genisoimage
-endef
-
-define $(package)_stage_cmds
- $(MAKE) DESTDIR=$($(package)_staging_dir) -C genisoimage install
-endef
-
-define $(package)_postprocess_cmds
- rm bin/isovfy bin/isoinfo bin/isodump bin/isodebug bin/devdump
-endef
diff --git a/depends/packages/packages.mk b/depends/packages/packages.mk
index 4b4cc7d9ff..d4fd23a47b 100644
--- a/depends/packages/packages.mk
+++ b/depends/packages/packages.mk
@@ -25,5 +25,5 @@ darwin_native_packages = native_ds_store native_mac_alias
$(host_arch)_$(host_os)_native_packages += native_b2
ifneq ($(build_os),darwin)
-darwin_native_packages += native_cctools native_cdrkit native_libdmg-hfsplus
+darwin_native_packages += native_cctools native_libdmg-hfsplus
endif
diff --git a/depends/patches/native_cctools/segalign.patch b/depends/patches/native_cctools/segalign.patch
new file mode 100644
index 0000000000..bcdbd67a6c
--- /dev/null
+++ b/depends/patches/native_cctools/segalign.patch
@@ -0,0 +1,19 @@
+commit 7f2eb11ce6ebec7eb9b8e1429535e453054143e5
+Author: Pieter Wuille <pieter@wuille.net>
+Date: Sun Dec 13 11:34:21 2020 -0800
+
+ Make cctools_port's codesign_allocate compatible with Apple's
+
+diff --git a/cctools/libstuff/arch.c b/cctools/libstuff/arch.c
+index 6f2332f..d85c25c 100644
+--- a/cctools/libstuff/arch.c
++++ b/cctools/libstuff/arch.c
+@@ -134,7 +134,7 @@ static const struct cpu_entry cpu_entries[] = {
+ { CPU_TYPE_ARM, LITTLE_ENDIAN_BYTE_SEX, 0, 0x4000 },
+
+ /* desktop */
+- { CPU_TYPE_X86_64, LITTLE_ENDIAN_BYTE_SEX, 0x7fff5fc00000LL, 0x1000 },
++ { CPU_TYPE_X86_64, LITTLE_ENDIAN_BYTE_SEX, 0x7fff5fc00000LL, 0x2000 /* Used to be 0x1000; changed to 0x2000 to match Apple's distributed codesign_allocate. */},
+ { CPU_TYPE_I386, LITTLE_ENDIAN_BYTE_SEX, 0xc0000000, 0x1000 },
+ { CPU_TYPE_POWERPC, BIG_ENDIAN_BYTE_SEX, 0xc0000000, 0x1000 },
+ { CPU_TYPE_POWERPC64, BIG_ENDIAN_BYTE_SEX, 0x7ffff00000000LL, 0x1000 },
diff --git a/depends/patches/native_cdrkit/cdrkit-deterministic.patch b/depends/patches/native_cdrkit/cdrkit-deterministic.patch
deleted file mode 100644
index 8ab0993dc4..0000000000
--- a/depends/patches/native_cdrkit/cdrkit-deterministic.patch
+++ /dev/null
@@ -1,86 +0,0 @@
---- cdrkit-1.1.11.old/genisoimage/tree.c 2008-10-21 19:57:47.000000000 -0400
-+++ cdrkit-1.1.11/genisoimage/tree.c 2013-12-06 00:23:18.489622668 -0500
-@@ -1139,8 +1139,9 @@
- scan_directory_tree(struct directory *this_dir, char *path,
- struct directory_entry *de)
- {
-- DIR *current_dir;
-+ int current_file;
- char whole_path[PATH_MAX];
-+ struct dirent **d_list;
- struct dirent *d_entry;
- struct directory *parent;
- int dflag;
-@@ -1164,7 +1165,8 @@
- this_dir->dir_flags |= DIR_WAS_SCANNED;
-
- errno = 0; /* Paranoia */
-- current_dir = opendir(path);
-+ //current_dir = opendir(path);
-+ current_file = scandir(path, &d_list, NULL, alphasort);
- d_entry = NULL;
-
- /*
-@@ -1173,12 +1175,12 @@
- */
- old_path = path;
-
-- if (current_dir) {
-+ if (current_file >= 0) {
- errno = 0;
-- d_entry = readdir(current_dir);
-+ d_entry = d_list[0];
- }
-
-- if (!current_dir || !d_entry) {
-+ if (current_file < 0 || !d_entry) {
- int ret = 1;
-
- #ifdef USE_LIBSCHILY
-@@ -1191,8 +1193,8 @@
- de->isorec.flags[0] &= ~ISO_DIRECTORY;
- ret = 0;
- }
-- if (current_dir)
-- closedir(current_dir);
-+ if(d_list)
-+ free(d_list);
- return (ret);
- }
- #ifdef ABORT_DEEP_ISO_ONLY
-@@ -1208,7 +1210,7 @@
- errmsgno(EX_BAD, "use Rock Ridge extensions via -R or -r,\n");
- errmsgno(EX_BAD, "or allow deep ISO9660 directory nesting via -D.\n");
- }
-- closedir(current_dir);
-+ free(d_list);
- return (1);
- }
- #endif
-@@ -1250,13 +1252,13 @@
- * The first time through, skip this, since we already asked
- * for the first entry when we opened the directory.
- */
-- if (dflag)
-- d_entry = readdir(current_dir);
-+ if (dflag && current_file >= 0)
-+ d_entry = d_list[current_file];
- dflag++;
-
-- if (!d_entry)
-+ if (current_file < 0)
- break;
--
-+ current_file--;
- /* OK, got a valid entry */
-
- /* If we do not want all files, then pitch the backups. */
-@@ -1348,7 +1350,7 @@
- insert_file_entry(this_dir, whole_path, d_entry->d_name);
- #endif /* APPLE_HYB */
- }
-- closedir(current_dir);
-+ free(d_list);
-
- #ifdef APPLE_HYB
- /*