aboutsummaryrefslogtreecommitdiff
path: root/contrib
diff options
context:
space:
mode:
Diffstat (limited to 'contrib')
-rw-r--r--contrib/depends/funcs.mk5
-rw-r--r--contrib/depends/packages/hidapi.mk6
-rw-r--r--contrib/depends/packages/libusb.mk6
-rw-r--r--contrib/depends/packages/native_biplist.mk20
-rw-r--r--contrib/depends/packages/native_cdrkit.mk26
-rw-r--r--contrib/depends/packages/native_cmake-unused.mk23
-rw-r--r--contrib/depends/packages/native_ds_store.mk17
-rw-r--r--contrib/depends/packages/native_libdmg-hfsplus.mk22
-rw-r--r--contrib/depends/packages/native_mac_alias.mk21
-rw-r--r--contrib/depends/packages/openssl.mk8
-rw-r--r--contrib/depends/patches/cmake/cmake-1-fixes.patch67
-rw-r--r--contrib/depends/patches/native_biplist/sorted_list.patch29
-rw-r--r--contrib/depends/patches/native_cdrkit/cdrkit-deterministic.patch86
-rw-r--r--contrib/depends/patches/native_mac_alias/python3.patch72
-rw-r--r--contrib/depends/patches/openssl/fix_darwin.patch60
-rw-r--r--contrib/epee/src/mlog.cpp13
-rw-r--r--contrib/epee/src/readline_buffer.cpp4
17 files changed, 30 insertions, 455 deletions
diff --git a/contrib/depends/funcs.mk b/contrib/depends/funcs.mk
index 804125990..66555aad7 100644
--- a/contrib/depends/funcs.mk
+++ b/contrib/depends/funcs.mk
@@ -143,8 +143,11 @@ $(1)_config_env+=PKG_CONFIG_PATH=$($($(1)_type)_prefix)/share/pkgconfig
$(1)_config_env+=PATH="$(build_prefix)/bin:$(PATH)"
$(1)_build_env+=PATH="$(build_prefix)/bin:$(PATH)"
$(1)_stage_env+=PATH="$(build_prefix)/bin:$(PATH)"
-$(1)_autoconf=./configure --host=$($($(1)_type)_host) --disable-dependency-tracking --prefix=$($($(1)_type)_prefix) $$($(1)_config_opts) CC="$$($(1)_cc)" CXX="$$($(1)_cxx)"
+$(1)_autoconf=./configure --host=$($($(1)_type)_host) --prefix=$($($(1)_type)_prefix) $$($(1)_config_opts) CC="$$($(1)_cc)" CXX="$$($(1)_cxx)"
+ifneq ($(1),libusb)
+$(1)_autoconf += --disable-dependency-tracking
+endif
ifneq ($($(1)_nm),)
$(1)_autoconf += NM="$$($(1)_nm)"
endif
diff --git a/contrib/depends/packages/hidapi.mk b/contrib/depends/packages/hidapi.mk
index 97e204f17..64935a36a 100644
--- a/contrib/depends/packages/hidapi.mk
+++ b/contrib/depends/packages/hidapi.mk
@@ -1,8 +1,8 @@
package=hidapi
-$(package)_version=0.11.0
-$(package)_download_path=https://github.com/libusb/hidapi/archive
+$(package)_version=0.13.1
+$(package)_download_path=https://github.com/libusb/hidapi/archive/refs/tags
$(package)_file_name=$(package)-$($(package)_version).tar.gz
-$(package)_sha256_hash=391d8e52f2d6a5cf76e2b0c079cfefe25497ba1d4659131297081fc0cd744632
+$(package)_sha256_hash=476a2c9a4dc7d1fc97dd223b84338dbea3809a84caea2dcd887d9778725490e3
$(package)_linux_dependencies=libusb eudev
$(package)_patches=missing_win_include.patch
diff --git a/contrib/depends/packages/libusb.mk b/contrib/depends/packages/libusb.mk
index 348c410a7..c1d9fe6a9 100644
--- a/contrib/depends/packages/libusb.mk
+++ b/contrib/depends/packages/libusb.mk
@@ -1,8 +1,8 @@
package=libusb
-$(package)_version=1.0.22
-$(package)_download_path=https://sourceforge.net/projects/libusb/files/libusb-1.0/libusb-$($(package)_version)/
+$(package)_version=1.0.26
+$(package)_download_path=https://github.com/libusb/libusb/releases/download/v$($(package)_version)
$(package)_file_name=$(package)-$($(package)_version).tar.bz2
-$(package)_sha256_hash=75aeb9d59a4fdb800d329a545c2e6799f732362193b465ea198f2aa275518157
+$(package)_sha256_hash=12ce7a61fc9854d1d2a1ffe095f7b5fac19ddba095c259e6067a46500381b5a5
define $(package)_preprocess_cmds
autoreconf -i
diff --git a/contrib/depends/packages/native_biplist.mk b/contrib/depends/packages/native_biplist.mk
deleted file mode 100644
index 3c6e8900f..000000000
--- a/contrib/depends/packages/native_biplist.mk
+++ /dev/null
@@ -1,20 +0,0 @@
-package=native_biplist
-$(package)_version=0.9
-$(package)_download_path=https://pypi.python.org/packages/source/b/biplist
-$(package)_file_name=biplist-$($(package)_version).tar.gz
-$(package)_sha256_hash=b57cadfd26e4754efdf89e9e37de87885f9b5c847b2615688ca04adfaf6ca604
-$(package)_install_libdir=$(build_prefix)/lib/python/dist-packages
-$(package)_patches=sorted_list.patch
-
-define $(package)_preprocess_cmds
- patch -p1 < $($(package)_patch_dir)/sorted_list.patch
-endef
-
-define $(package)_build_cmds
- python setup.py build
-endef
-
-define $(package)_stage_cmds
- mkdir -p $($(package)_install_libdir) && \
- python setup.py install --root=$($(package)_staging_dir) --prefix=$(build_prefix) --install-lib=$($(package)_install_libdir)
-endef
diff --git a/contrib/depends/packages/native_cdrkit.mk b/contrib/depends/packages/native_cdrkit.mk
deleted file mode 100644
index 8243458ec..000000000
--- a/contrib/depends/packages/native_cdrkit.mk
+++ /dev/null
@@ -1,26 +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
-
-define $(package)_config_cmds
- cmake -DCMAKE_INSTALL_PREFIX=$(build_prefix)
-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/contrib/depends/packages/native_cmake-unused.mk b/contrib/depends/packages/native_cmake-unused.mk
deleted file mode 100644
index c9ab75711..000000000
--- a/contrib/depends/packages/native_cmake-unused.mk
+++ /dev/null
@@ -1,23 +0,0 @@
-package=native_cmake
-$(package)_version=3.14.0
-$(package)_version_dot=v3.14
-$(package)_download_path=https://cmake.org/files/$($(package)_version_dot)/
-$(package)_file_name=cmake-$($(package)_version).tar.gz
-$(package)_sha256_hash=aa76ba67b3c2af1946701f847073f4652af5cbd9f141f221c97af99127e75502
-
-define $(package)_set_vars
-$(package)_config_opts=
-endef
-
-define $(package)_config_cmds
- ./bootstrap &&\
- ./configure $($(package)_config_opts)
-endef
-
-define $(package)_build_cmd
- $(MAKE)
-endef
-
-define $(package)_stage_cmds
- $(MAKE) DESTDIR=$($(package)_staging_dir) install
-endef
diff --git a/contrib/depends/packages/native_ds_store.mk b/contrib/depends/packages/native_ds_store.mk
deleted file mode 100644
index f0c617659..000000000
--- a/contrib/depends/packages/native_ds_store.mk
+++ /dev/null
@@ -1,17 +0,0 @@
-package=native_ds_store
-$(package)_version=1.1.0
-$(package)_download_path=https://github.com/al45tair/ds_store/archive/
-$(package)_download_file=v$($(package)_version).tar.gz
-$(package)_file_name=$(package)-$($(package)_version).tar.gz
-$(package)_sha256_hash=a9f4c0755c6be7224ff7029e188dd262e830bb81e801424841db9eb0780ec8ed
-$(package)_install_libdir=$(build_prefix)/lib/python/dist-packages
-$(package)_dependencies=native_biplist
-
-define $(package)_build_cmds
- python setup.py build
-endef
-
-define $(package)_stage_cmds
- mkdir -p $($(package)_install_libdir) && \
- python setup.py install --root=$($(package)_staging_dir) --prefix=$(build_prefix) --install-lib=$($(package)_install_libdir)
-endef
diff --git a/contrib/depends/packages/native_libdmg-hfsplus.mk b/contrib/depends/packages/native_libdmg-hfsplus.mk
deleted file mode 100644
index a4ffb6046..000000000
--- a/contrib/depends/packages/native_libdmg-hfsplus.mk
+++ /dev/null
@@ -1,22 +0,0 @@
-package=native_libdmg-hfsplus
-$(package)_version=0.1
-$(package)_download_path=https://github.com/theuni/libdmg-hfsplus/archive
-$(package)_file_name=libdmg-hfsplus-v$($(package)_version).tar.gz
-$(package)_sha256_hash=6569a02eb31c2827080d7d59001869ea14484c281efab0ae7f2b86af5c3120b3
-$(package)_build_subdir=build
-
-define $(package)_preprocess_cmds
- mkdir build
-endef
-
-define $(package)_config_cmds
- cmake -DCMAKE_INSTALL_PREFIX:PATH=$(build_prefix)/bin ..
-endef
-
-define $(package)_build_cmds
- $(MAKE) -C dmg
-endef
-
-define $(package)_stage_cmds
- $(MAKE) DESTDIR=$($(package)_staging_dir) -C dmg install
-endef
diff --git a/contrib/depends/packages/native_mac_alias.mk b/contrib/depends/packages/native_mac_alias.mk
deleted file mode 100644
index 48bd90fb6..000000000
--- a/contrib/depends/packages/native_mac_alias.mk
+++ /dev/null
@@ -1,21 +0,0 @@
-package=native_mac_alias
-$(package)_version=1.1.0
-$(package)_download_path=https://github.com/al45tair/mac_alias/archive/
-$(package)_download_file=v$($(package)_version).tar.gz
-$(package)_file_name=$(package)-$($(package)_version).tar.gz
-$(package)_sha256_hash=b10cb44ecb64fc25283fae7a9cf365d2829377d84e37b9c21100aca8757509be
-$(package)_install_libdir=$(build_prefix)/lib/python/dist-packages
-$(package)_patches=python3.patch
-
-define $(package)_preprocess_cmds
- patch -p1 < $($(package)_patch_dir)/python3.patch
-endef
-
-define $(package)_build_cmds
- python setup.py build
-endef
-
-define $(package)_stage_cmds
- mkdir -p $($(package)_install_libdir) && \
- python setup.py install --root=$($(package)_staging_dir) --prefix=$(build_prefix) --install-lib=$($(package)_install_libdir)
-endef
diff --git a/contrib/depends/packages/openssl.mk b/contrib/depends/packages/openssl.mk
index 0d8478d49..990b85093 100644
--- a/contrib/depends/packages/openssl.mk
+++ b/contrib/depends/packages/openssl.mk
@@ -1,9 +1,8 @@
package=openssl
-$(package)_version=1.1.1l
+$(package)_version=1.1.1t
$(package)_download_path=https://www.openssl.org/source
$(package)_file_name=$(package)-$($(package)_version).tar.gz
-$(package)_sha256_hash=0b7a3e5e59c34827fe0c3a74b7ec8baef302b98fa80088d7f9153aa16fa76bd1
-$(package)_patches=fix_darwin.patch
+$(package)_sha256_hash=8dee9b24bdb1dcbf0c3d1e9b02fb8f6bf22165e807f45adeb7c9677536859d3b
define $(package)_set_vars
$(package)_config_env=AR="$($(package)_ar)" ARFLAGS=$($(package)_arflags) RANLIB="$($(package)_ranlib)" CC="$($(package)_cc)"
@@ -50,8 +49,7 @@ $(package)_config_opts_x86_64_freebsd=BSD-x86_64
endef
define $(package)_preprocess_cmds
- sed -i.old 's|"engines", "apps", "test", "util", "tools", "fuzz"|"engines", "tools"|' Configure && \
- patch -p1 < $($(package)_patch_dir)/fix_darwin.patch
+ sed -i.old 's|"engines", "apps", "test", "util", "tools", "fuzz"|"engines", "tools"|' Configure
endef
define $(package)_config_cmds
diff --git a/contrib/depends/patches/cmake/cmake-1-fixes.patch b/contrib/depends/patches/cmake/cmake-1-fixes.patch
deleted file mode 100644
index 062c06767..000000000
--- a/contrib/depends/patches/cmake/cmake-1-fixes.patch
+++ /dev/null
@@ -1,67 +0,0 @@
-This file is part of MXE. See LICENSE.md for licensing information.
-
-Contains ad hoc patches for cross building.
-
-From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
-From: Tony Theodore <tonyt@logyst.com>
-Date: Fri, 12 Aug 2016 02:01:20 +1000
-Subject: [PATCH 1/3] fix windres invocation options
-
-windres doesn't recognise various gcc flags like -mms-bitfields,
--fopenmp, -mthreads etc. (basically not `-D` or `-I`)
-
-diff --git a/Modules/Platform/Windows-windres.cmake b/Modules/Platform/Windows-windres.cmake
-index 1111111..2222222 100644
---- a/Modules/Platform/Windows-windres.cmake
-+++ b/Modules/Platform/Windows-windres.cmake
-@@ -1 +1 @@
--set(CMAKE_RC_COMPILE_OBJECT "<CMAKE_RC_COMPILER> -O coff <DEFINES> <INCLUDES> <FLAGS> <SOURCE> <OBJECT>")
-+set(CMAKE_RC_COMPILE_OBJECT "<CMAKE_RC_COMPILER> -O coff <DEFINES> <INCLUDES> <SOURCE> <OBJECT>")
-
-From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
-From: Tony Theodore <tonyt@logyst.com>
-Date: Tue, 25 Jul 2017 20:34:56 +1000
-Subject: [PATCH 2/3] add option to disable -isystem
-
-taken from (not accepted):
-https://gitlab.kitware.com/cmake/cmake/merge_requests/895
-
-see also:
-https://gitlab.kitware.com/cmake/cmake/issues/16291
-https://gitlab.kitware.com/cmake/cmake/issues/16919
-
-diff --git a/Modules/Compiler/GNU.cmake b/Modules/Compiler/GNU.cmake
-index 1111111..2222222 100644
---- a/Modules/Compiler/GNU.cmake
-+++ b/Modules/Compiler/GNU.cmake
-@@ -42,7 +42,7 @@ macro(__compiler_gnu lang)
- string(APPEND CMAKE_${lang}_FLAGS_RELWITHDEBINFO_INIT " -O2 -g -DNDEBUG")
- set(CMAKE_${lang}_CREATE_PREPROCESSED_SOURCE "<CMAKE_${lang}_COMPILER> <DEFINES> <INCLUDES> <FLAGS> -E <SOURCE> > <PREPROCESSED_SOURCE>")
- set(CMAKE_${lang}_CREATE_ASSEMBLY_SOURCE "<CMAKE_${lang}_COMPILER> <DEFINES> <INCLUDES> <FLAGS> -S <SOURCE> -o <ASSEMBLY_SOURCE>")
-- if(NOT APPLE OR NOT CMAKE_${lang}_COMPILER_VERSION VERSION_LESS 4) # work around #4462
-+ if(NOT APPLE OR NOT CMAKE_${lang}_COMPILER_VERSION VERSION_LESS 4 AND (NOT MXE_DISABLE_INCLUDE_SYSTEM_FLAG)) # work around #4462
- set(CMAKE_INCLUDE_SYSTEM_FLAG_${lang} "-isystem ")
- endif()
- endmacro()
-
-From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
-From: Tony Theodore <tonyt@logyst.com>
-Date: Tue, 15 Aug 2017 15:25:06 +1000
-Subject: [PATCH 3/3] add CPACK_NSIS_EXECUTABLE variable
-
-
-diff --git a/Source/CPack/cmCPackNSISGenerator.cxx b/Source/CPack/cmCPackNSISGenerator.cxx
-index 1111111..2222222 100644
---- a/Source/CPack/cmCPackNSISGenerator.cxx
-+++ b/Source/CPack/cmCPackNSISGenerator.cxx
-@@ -384,7 +384,9 @@ int cmCPackNSISGenerator::InitializeInternal()
- }
- #endif
-
-- nsisPath = cmSystemTools::FindProgram("makensis", path, false);
-+ this->SetOptionIfNotSet("CPACK_NSIS_EXECUTABLE", "makensis");
-+ nsisPath = cmSystemTools::FindProgram(
-+ this->GetOption("CPACK_NSIS_EXECUTABLE"), path, false);
-
- if (nsisPath.empty()) {
- cmCPackLogger(
diff --git a/contrib/depends/patches/native_biplist/sorted_list.patch b/contrib/depends/patches/native_biplist/sorted_list.patch
deleted file mode 100644
index 89abdb1b7..000000000
--- a/contrib/depends/patches/native_biplist/sorted_list.patch
+++ /dev/null
@@ -1,29 +0,0 @@
---- a/biplist/__init__.py 2014-10-26 19:03:11.000000000 +0000
-+++ b/biplist/__init__.py 2016-07-19 19:30:17.663521999 +0000
-@@ -541,7 +541,7 @@
- return HashableWrapper(n)
- elif isinstance(root, dict):
- n = {}
-- for key, value in iteritems(root):
-+ for key, value in sorted(iteritems(root)):
- n[self.wrapRoot(key)] = self.wrapRoot(value)
- return HashableWrapper(n)
- elif isinstance(root, list):
-@@ -616,7 +616,7 @@
- elif isinstance(obj, dict):
- size = proc_size(len(obj))
- self.incrementByteCount('dictBytes', incr=1+size)
-- for key, value in iteritems(obj):
-+ for key, value in sorted(iteritems(obj)):
- check_key(key)
- self.computeOffsets(key, asReference=True)
- self.computeOffsets(value, asReference=True)
-@@ -714,7 +714,7 @@
- keys = []
- values = []
- objectsToWrite = []
-- for key, value in iteritems(obj):
-+ for key, value in sorted(iteritems(obj)):
- keys.append(key)
- values.append(value)
- for key in keys:
diff --git a/contrib/depends/patches/native_cdrkit/cdrkit-deterministic.patch b/contrib/depends/patches/native_cdrkit/cdrkit-deterministic.patch
deleted file mode 100644
index 8ab0993dc..000000000
--- a/contrib/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
- /*
diff --git a/contrib/depends/patches/native_mac_alias/python3.patch b/contrib/depends/patches/native_mac_alias/python3.patch
deleted file mode 100644
index 1a32340be..000000000
--- a/contrib/depends/patches/native_mac_alias/python3.patch
+++ /dev/null
@@ -1,72 +0,0 @@
-diff -dur a/mac_alias/alias.py b/mac_alias/alias.py
---- a/mac_alias/alias.py 2015-10-19 12:12:48.000000000 +0200
-+++ b/mac_alias/alias.py 2016-04-03 12:13:12.037159417 +0200
-@@ -243,10 +243,10 @@
- alias = Alias()
- alias.appinfo = appinfo
-
-- alias.volume = VolumeInfo (volname.replace('/',':'),
-+ alias.volume = VolumeInfo (volname.decode().replace('/',':'),
- voldate, fstype, disktype,
- volattrs, volfsid)
-- alias.target = TargetInfo (kind, filename.replace('/',':'),
-+ alias.target = TargetInfo (kind, filename.decode().replace('/',':'),
- folder_cnid, cnid,
- crdate, creator_code, type_code)
- alias.target.levels_from = levels_from
-@@ -261,9 +261,9 @@
- b.read(1)
-
- if tag == TAG_CARBON_FOLDER_NAME:
-- alias.target.folder_name = value.replace('/',':')
-+ alias.target.folder_name = value.decode().replace('/',':')
- elif tag == TAG_CNID_PATH:
-- alias.target.cnid_path = struct.unpack(b'>%uI' % (length // 4),
-+ alias.target.cnid_path = struct.unpack('>%uI' % (length // 4),
- value)
- elif tag == TAG_CARBON_PATH:
- alias.target.carbon_path = value
-@@ -298,9 +298,9 @@
- alias.target.creation_date \
- = mac_epoch + datetime.timedelta(seconds=seconds)
- elif tag == TAG_POSIX_PATH:
-- alias.target.posix_path = value
-+ alias.target.posix_path = value.decode()
- elif tag == TAG_POSIX_PATH_TO_MOUNTPOINT:
-- alias.volume.posix_path = value
-+ alias.volume.posix_path = value.decode()
- elif tag == TAG_RECURSIVE_ALIAS_OF_DISK_IMAGE:
- alias.volume.disk_image_alias = Alias.from_bytes(value)
- elif tag == TAG_USER_HOME_LENGTH_PREFIX:
-@@ -422,13 +422,13 @@
- # (so doing so is ridiculous, and nothing could rely on it).
- b.write(struct.pack(b'>h28pI2shI64pII4s4shhI2s10s',
- self.target.kind,
-- carbon_volname, voldate,
-+ carbon_volname, int(voldate),
- self.volume.fs_type,
- self.volume.disk_type,
- self.target.folder_cnid,
- carbon_filename,
- self.target.cnid,
-- crdate,
-+ int(crdate),
- self.target.creator_code,
- self.target.type_code,
- self.target.levels_from,
-@@ -449,12 +449,12 @@
-
- b.write(struct.pack(b'>hhQhhQ',
- TAG_HIGH_RES_VOLUME_CREATION_DATE,
-- 8, long(voldate * 65536),
-+ 8, int(voldate * 65536),
- TAG_HIGH_RES_CREATION_DATE,
-- 8, long(crdate * 65536)))
-+ 8, int(crdate * 65536)))
-
- if self.target.cnid_path:
-- cnid_path = struct.pack(b'>%uI' % len(self.target.cnid_path),
-+ cnid_path = struct.pack('>%uI' % len(self.target.cnid_path),
- *self.target.cnid_path)
- b.write(struct.pack(b'>hh', TAG_CNID_PATH,
- len(cnid_path)))
diff --git a/contrib/depends/patches/openssl/fix_darwin.patch b/contrib/depends/patches/openssl/fix_darwin.patch
deleted file mode 100644
index a917daa12..000000000
--- a/contrib/depends/patches/openssl/fix_darwin.patch
+++ /dev/null
@@ -1,60 +0,0 @@
-From 96ac8f13f4d0ee96baf5724d9f96c44c34b8606c Mon Sep 17 00:00:00 2001
-From: David Carlier <devnexen@gmail.com>
-Date: Tue, 24 Aug 2021 22:40:14 +0100
-Subject: [PATCH] Darwin platform allows to build on releases before
- Yosemite/ios 8.
-
-issue #16407 #16408
-
-Reviewed-by: Paul Dale <pauli@openssl.org>
-Reviewed-by: Tomas Mraz <tomas@openssl.org>
-(Merged from https://github.com/openssl/openssl/pull/16409)
----
- crypto/rand/rand_unix.c | 5 +----
- include/crypto/rand.h | 10 ++++++++++
- 2 files changed, 11 insertions(+), 4 deletions(-)
-
-diff --git a/crypto/rand/rand_unix.c b/crypto/rand/rand_unix.c
-index 43f1069d151d..0f4525106af7 100644
---- a/crypto/rand/rand_unix.c
-+++ b/crypto/rand/rand_unix.c
-@@ -34,9 +34,6 @@
- #if defined(__OpenBSD__)
- # include <sys/param.h>
- #endif
--#if defined(__APPLE__)
--# include <CommonCrypto/CommonRandom.h>
--#endif
-
- #if defined(OPENSSL_SYS_UNIX) || defined(__DJGPP__)
- # include <sys/types.h>
-@@ -381,7 +378,7 @@ static ssize_t syscall_random(void *buf, size_t buflen)
- if (errno != ENOSYS)
- return -1;
- }
--# elif defined(__APPLE__)
-+# elif defined(OPENSSL_APPLE_CRYPTO_RANDOM)
- if (CCRandomGenerateBytes(buf, buflen) == kCCSuccess)
- return (ssize_t)buflen;
-
-diff --git a/include/crypto/rand.h b/include/crypto/rand.h
-index 5350d3a93119..674f840fd13c 100644
---- a/include/crypto/rand.h
-+++ b/include/crypto/rand.h
-@@ -20,6 +20,16 @@
-
- # include <openssl/rand.h>
-
-+# if defined(__APPLE__) && !defined(OPENSSL_NO_APPLE_CRYPTO_RANDOM)
-+# include <Availability.h>
-+# if (defined(__MAC_OS_X_VERSION_MIN_REQUIRED) && __MAC_OS_X_VERSION_MIN_REQUIRED >= 101000) || \
-+ (defined(__IPHONE_OS_VERSION_MIN_REQUIRED) && __IPHONE_OS_VERSION_MIN_REQUIRED >= 80000)
-+# define OPENSSL_APPLE_CRYPTO_RANDOM 1
-+# include <CommonCrypto/CommonCryptoError.h>
-+# include <CommonCrypto/CommonRandom.h>
-+# endif
-+# endif
-+
- /* forward declaration */
- typedef struct rand_pool_st RAND_POOL;
-
diff --git a/contrib/epee/src/mlog.cpp b/contrib/epee/src/mlog.cpp
index 092d41777..4ca1a3632 100644
--- a/contrib/epee/src/mlog.cpp
+++ b/contrib/epee/src/mlog.cpp
@@ -338,11 +338,21 @@ bool is_stdout_a_tty()
return is_a_tty.load(std::memory_order_relaxed);
}
+static bool is_nocolor()
+{
+ static const char *no_color_var = getenv("NO_COLOR");
+ static const bool no_color = no_color_var && *no_color_var; // apparently, NO_COLOR=0 means no color too (as per no-color.org)
+ return no_color;
+}
+
void set_console_color(int color, bool bright)
{
if (!is_stdout_a_tty())
return;
+ if (is_nocolor())
+ return;
+
switch(color)
{
case console_color_default:
@@ -461,6 +471,9 @@ void reset_console_color() {
if (!is_stdout_a_tty())
return;
+ if (is_nocolor())
+ return;
+
#ifdef WIN32
HANDLE h_stdout = GetStdHandle(STD_OUTPUT_HANDLE);
SetConsoleTextAttribute(h_stdout, FOREGROUND_RED | FOREGROUND_GREEN | FOREGROUND_BLUE);
diff --git a/contrib/epee/src/readline_buffer.cpp b/contrib/epee/src/readline_buffer.cpp
index 1047d1696..ac68d1fdb 100644
--- a/contrib/epee/src/readline_buffer.cpp
+++ b/contrib/epee/src/readline_buffer.cpp
@@ -238,6 +238,10 @@ static char** attempted_completion(const char* text, int start, int end)
static void install_line_handler()
{
+#if RL_READLINE_VERSION >= 0x0801
+ rl_variable_bind("enable-bracketed-paste", "off");
+#endif
+
rl_attempted_completion_function = attempted_completion;
rl_callback_handler_install("", handle_line);
stifle_history(500);