mirror of
https://github.com/bitcoin/bitcoin.git
synced 2024-11-19 18:09:47 +01:00
build: use patch rather than sed in native_cctools package
This commit is contained in:
parent
865cb23a48
commit
cc107a3af1
@ -4,6 +4,8 @@ $(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
|
||||
|
||||
ifeq ($(strip $(FORCE_USE_SYSTEM_CLANG)),)
|
||||
$(package)_clang_version=8.0.0
|
||||
$(package)_clang_download_path=https://releases.llvm.org/$($(package)_clang_version)
|
||||
@ -78,7 +80,7 @@ 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 && \
|
||||
sed -i.old "/define HAVE_PTHREADS/d" $($(package)_build_subdir)/ld64/src/ld/InputFiles.h
|
||||
patch -p1 < $($(package)_patch_dir)/ld64_disable_threading.patch
|
||||
endef
|
||||
|
||||
define $(package)_config_cmds
|
||||
|
26
depends/patches/native_cctools/ld64_disable_threading.patch
Normal file
26
depends/patches/native_cctools/ld64_disable_threading.patch
Normal file
@ -0,0 +1,26 @@
|
||||
commit 584668415039adeed073decee7e04de28248afd3
|
||||
Author: fanquake <fanquake@gmail.com>
|
||||
Date: Tue Aug 18 01:20:24 2020 +0000
|
||||
|
||||
Disable threading to fix non-determinism
|
||||
|
||||
A bug in the file parser can cause dependencies to be calculated
|
||||
differently based on which files have already been parsed. This is more
|
||||
likely to occur on systems with more CPUs.
|
||||
|
||||
Just disable threading for now. There is no noticable slowdown.
|
||||
|
||||
See #9891.
|
||||
|
||||
diff --git a/cctools/ld64/src/ld/InputFiles.h b/cctools/ld64/src/ld/InputFiles.h
|
||||
index ef9c756..90a70b6 100644
|
||||
--- a/cctools/ld64/src/ld/InputFiles.h
|
||||
+++ b/cctools/ld64/src/ld/InputFiles.h
|
||||
@@ -25,7 +25,6 @@
|
||||
#ifndef __INPUT_FILES_H__
|
||||
#define __INPUT_FILES_H__
|
||||
|
||||
-#define HAVE_PTHREADS 1
|
||||
|
||||
#include <stdlib.h>
|
||||
#include <sys/types.h>
|
Loading…
Reference in New Issue
Block a user