Bug 31785 - parallel build of 4.0.2.4 fails
Summary: parallel build of 4.0.2.4 fails
Status: RESOLVED FIXED
Alias: None
Product: Installers
Classification: Mono
Component: Linux packages ()
Version: 4.0.0
Hardware: PC Linux
: --- normal
Target Milestone: ---
Assignee: Jo Shields
URL:
Depends on:
Blocks:
 
Reported: 2015-07-09 09:15 UTC by Chris Morgan
Modified: 2017-08-29 16:09 UTC (History)
3 users (show)

Tags:
Is this bug a regression?: ---
Last known good build:

Notice (2018-05-24): bugzilla.xamarin.com is now in read-only mode.

Please join us on Visual Studio Developer Community and in the Xamarin and Mono organizations on GitHub to continue tracking issues. Bugzilla will remain available for reference in read-only mode. We will continue to work on open Bugzilla bugs, copy them to the new locations as needed for follow-up, and add the new items under Related Links.

Our sincere thanks to everyone who has contributed on this bug tracker over the years. Thanks also for your understanding as we make these adjustments and improvements for the future.


Please create a new report on GitHub or Developer Community with your current version information, steps to reproduce, and relevant error messages or log files if you are hitting an issue that looks similar to this resolved bug and you do not yet see a matching new report.

Related Links:
Status:
RESOLVED FIXED

Description Chris Morgan 2015-07-09 09:15:17 UTC
I've seen the issue here on Fedora 22.

Issue appears to be that under a parallel build the same files are installed multiple times and this is caught as an error.



An email from another person who ran into the same issue when building mono under Yocto:

A race was observed during `make install` of mono-native under
PARALLEL_MAKE=-j6:

/usr/bin/install: cannot change permissions of
build/tmp-glibc/work/x86_64-linux/mono-native/4.0.2.4-r0/image/
build/tmp-glibc/sysroots/x86_64-linux/usr/lib/mono/xbuild-frameworks/
.NETFramework/v4.5/RedistList/FrameworkList.xml: No such file or
directory

This is definitely a race, because FrameworkList.xml was present once
the failed build completed.

The present mono build doesn't appear to build much of anything in
parallel in the first place, and I would guess that this issue applies
equally to the mono and mono-native builds. So the correct place for the
workaround ought to be in the shared .inc file.

Signed-off-by: Richard Tollerton <rich.tollerton@ni.com>
---
 recipes-mono/mono/mono-4.xx.inc | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/recipes-mono/mono/mono-4.xx.inc b/recipes-mono/mono/mono-4.xx.inc
index 2d7f65d..973593a 100644
--- a/recipes-mono/mono/mono-4.xx.inc
+++ b/recipes-mono/mono/mono-4.xx.inc
@@ -68,3 +68,6 @@ FILES_${PN}-dbg                       += " ${datadir}/mono-2.0/mono/cil/cil-opcodes.xml ${libdir}/m
 FILES_${PN}-staticdev                  += " ${libdir}/*.a"

 RDEPENDS_${PN} =+ "bash"
+
+# Workaround for observed race in `make install`
+PARALLEL_MAKE=""
Comment 1 Jo Shields 2017-08-29 16:09:01 UTC
I'm not aware of any lingering issues with high -j values. They definitely used to exist.