diff options
author | Mikael Urankar <mikael@FreeBSD.org> | 2022-03-28 11:21:02 +0200 |
---|---|---|
committer | Mikael Urankar <mikael@FreeBSD.org> | 2022-03-28 12:21:05 +0200 |
commit | b62ec370c8d8289c7fe8892a88c4d65eaab92f5b (patch) | |
tree | dc069fc78cadbc3b5063a7e76eb7e76e86718aab /lang/mono | |
parent | b7051d827bb668262d11bff6ad45384495762d13 (diff) | |
download | freebsd-ports-b62ec370c8d8289c7fe8892a88c4d65eaab92f5b.zip |
lang/mono5.10,lang/mono: Attempt to fix build on aarch64
The Roslyn C# compiler has a concurrency problem on aarch64:
https://github.com/mono/mono/issues/7017 (not FreeBSD specific)
so the workaround is to disable parallelism… so the .NET libraries are built
very very slowly
PR: 229710
Approved by: portmgr (build fix blanket)
Diffstat (limited to 'lang/mono')
-rw-r--r-- | lang/mono/Makefile | 1 | ||||
-rw-r--r-- | lang/mono/files/extra-patch-aarch64-race-workaround | 26 |
2 files changed, 27 insertions, 0 deletions
diff --git a/lang/mono/Makefile b/lang/mono/Makefile index 7003f645a52a..227a8cf9d404 100644 --- a/lang/mono/Makefile +++ b/lang/mono/Makefile @@ -66,6 +66,7 @@ OPTIONS_SLAVE= MONOLITE .include <bsd.port.options.mk> .if ${ARCH} == aarch64 +EXTRA_PATCHES= ${FILESDIR}/extra-patch-aarch64-race-workaround PLIST= ${.CURDIR}/pkg-plist.aarch64 .endif diff --git a/lang/mono/files/extra-patch-aarch64-race-workaround b/lang/mono/files/extra-patch-aarch64-race-workaround new file mode 100644 index 000000000000..d7dd165bd609 --- /dev/null +++ b/lang/mono/files/extra-patch-aarch64-race-workaround @@ -0,0 +1,26 @@ +https://bugs.freebsd.org/bugzilla/attachment.cgi?id=195063&action=diff#i/lang/mono/files/extra-patch-aarch64-race-workaround_sec1 + +Workaround for Roslyn crash: https://github.com/mono/mono/issues/7017 + +--- mcs/build/profiles/basic.make.orig 2021-11-08 19:42:34.845483000 +0100 ++++ mcs/build/profiles/basic.make 2021-11-08 19:43:00.996003000 +0100 +@@ -47,7 +47,7 @@ LIBRARY_COMPILE = $(BOOT_COMPILE) + # + # Copy from rules.make because I don't know how to unset MCS_FLAGS + # +-USE_MCS_FLAGS = /codepage:$(CODEPAGE) /nologo /noconfig /deterministic $(LOCAL_MCS_FLAGS) $(PLATFORM_MCS_FLAGS) $(PROFILE_MCS_FLAGS) $(MCS_FLAGS) ++USE_MCS_FLAGS = /codepage:$(CODEPAGE) /parallel- /nologo /noconfig /deterministic $(LOCAL_MCS_FLAGS) $(PLATFORM_MCS_FLAGS) $(PROFILE_MCS_FLAGS) $(MCS_FLAGS) + + .PHONY: profile-check do-profile-check + profile-check: +--- mcs/build/rules.make.orig 2021-11-08 19:43:05.777570000 +0100 ++++ mcs/build/rules.make 2021-11-08 19:43:20.886314000 +0100 +@@ -34,7 +34,7 @@ BUILD_TOOLS_PROFILE = build + endif + endif + +-USE_MCS_FLAGS = /codepage:$(CODEPAGE) /nologo /noconfig /deterministic $(LOCAL_MCS_FLAGS) $(PLATFORM_MCS_FLAGS) $(PROFILE_MCS_FLAGS) $(MCS_FLAGS) ++USE_MCS_FLAGS = /codepage:$(CODEPAGE) /parallel- /nologo /noconfig /deterministic $(LOCAL_MCS_FLAGS) $(PLATFORM_MCS_FLAGS) $(PROFILE_MCS_FLAGS) $(MCS_FLAGS) + USE_MBAS_FLAGS = /codepage:$(CODEPAGE) $(LOCAL_MBAS_FLAGS) $(PLATFORM_MBAS_FLAGS) $(PROFILE_MBAS_FLAGS) $(MBAS_FLAGS) + USE_CFLAGS = $(LOCAL_CFLAGS) $(CFLAGS) $(CPPFLAGS) + CSCOMPILE = $(Q_MCS) $(MCS) $(USE_MCS_FLAGS) |