forked from Lainports/freebsd-ports
devel/msbuild: Avoid MSB1008 build error
The following error: ============= MSBuild command ============= /big/ports/usr/ports/devel/msbuild/work/msbuild-0.06/build/../artifacts/mono-msbuild/msbuild "/big/ports/usr/ports/devel/msbuild/work/msbuild-0.06/build/Toolset.proj" /t:restore /m /clp:Summary /warnaserror /v:minimal /bl:"/big/ports/usr/ports/devel/msbuild/work/msbuild-0.06/build/../artifacts/Release-MONO/log/Toolset.binlog" =========================================== Microsoft (R) Build Engine version 15.8.38.37692 (xplat-master/3c930fa8 Tue May 8 12:36:23 EDT 2018) for Mono Copyright (C) Microsoft Corporation. All rights reserved. MSBUILD : error MSB1008: Only one project can be specified. Switch: /m can be fixed by making sure the /m is given the parameter (number of CPUs to use in parallel). MSBuild does not seem to parallelize builds currently, but this fixes the error. PR: 272961 Approved by: portmgr (build fix blanket)
This commit is contained in:
parent
85fe592a0c
commit
fed755e222
3 changed files with 24 additions and 4 deletions
9
devel/msbuild/Makefile
Normal file → Executable file
9
devel/msbuild/Makefile
Normal file → Executable file
|
|
@ -15,17 +15,17 @@ LICENSE_FILE= ${WRKSRC}/LICENSE
|
|||
|
||||
BUILD_DEPENDS= bash:shells/bash
|
||||
|
||||
USES= mono:nuget shebangfix
|
||||
|
||||
NUGET_FEEDS= DOTNET_CORE NUGET ROSLYN ROSLYN_TOOLS SYMREADER_CONVERTER
|
||||
NUGET_LAYOUT= dotnet
|
||||
|
||||
USES= mono:nuget shebangfix
|
||||
USE_GITHUB= yes
|
||||
GH_ACCOUNT= mono
|
||||
GH_TAGNAME= 0.06
|
||||
SHEBANG_FILES= *.sh artifacts/mono-msbuild/msbuild build.sh build/*.sh
|
||||
|
||||
MAKE_ENV= GIT_COMMIT=3c930fa8721935cf0e381fd349f6f50cf2bc223d
|
||||
MAKE_JOBS_UNSAFE=MSBuild has not implemented concurrent builds on non Windows platforms
|
||||
ALL_TARGET= all-mono
|
||||
TEST_TARGET= test-mono
|
||||
|
||||
|
|
@ -33,6 +33,11 @@ post-extract:
|
|||
${MKDIR} ${WRKSRC}/artifacts
|
||||
${MV} ${WRKDIR}/msbuild ${WRKSRC}/artifacts/mono-msbuild
|
||||
|
||||
pre-configure:
|
||||
${REINPLACE_CMD} -e s/%%MAKE_JOBS_NUMBER%%/${MAKE_JOBS_NUMBER}/ \
|
||||
${WRKSRC}/build/build.sh \
|
||||
${WRKSRC}/Directory.Build.rsp
|
||||
|
||||
do-build:
|
||||
(cd ${WRKSRC}; \
|
||||
${SETENV} ${MAKE_ENV} ./build/build.sh -host mono -configuration Release -skipTests build)
|
||||
|
|
|
|||
6
devel/msbuild/files/patch-Directory.Build.rsp
Normal file
6
devel/msbuild/files/patch-Directory.Build.rsp
Normal file
|
|
@ -0,0 +1,6 @@
|
|||
--- Directory.Build.rsp.orig 2018-05-02 18:19:31 UTC
|
||||
+++ Directory.Build.rsp
|
||||
@@ -1 +1 @@
|
||||
-/verbosity:minimal /m /clp:Summary
|
||||
\ No newline at end of file
|
||||
+/verbosity:minimal /m:%%MAKE_JOBS_NUMBER%% /clp:Summary
|
||||
|
|
@ -1,4 +1,4 @@
|
|||
--- build/build.sh.orig 2018-06-25 18:50:41 UTC
|
||||
--- build/build.sh.orig 2023-08-06 19:14:14 UTC
|
||||
+++ build/build.sh
|
||||
@@ -151,7 +151,7 @@ function ExitIfError {
|
||||
then
|
||||
|
|
@ -9,12 +9,21 @@
|
|||
then
|
||||
StopProcesses
|
||||
fi
|
||||
@@ -297,7 +297,7 @@ function InstallRepoToolset {
|
||||
if [ ! -d "$RepoToolsetBuildProj" ]
|
||||
then
|
||||
ToolsetProj="$ScriptRoot/Toolset.proj"
|
||||
- CallMSBuild $(QQ $ToolsetProj) /t:restore /m /clp:Summary /warnaserror /v:$verbosity $logCmd $properties
|
||||
+ CallMSBuild $(QQ $ToolsetProj) /t:restore /m:%%MAKE_JOBS_NUMBER%% /clp:Summary /warnaserror /v:$verbosity $logCmd $properties
|
||||
fi
|
||||
}
|
||||
|
||||
@@ -343,7 +343,7 @@ function Build {
|
||||
|
||||
local logCmd=$(GetLogCmd Build)
|
||||
|
||||
- commonMSBuildArgs="/m /clp:Summary /v:$verbosity /p:Configuration=$configuration /p:SolutionPath=$(QQ $MSBuildSolution) /p:CIBuild=$ci /p:DisableNerdbankVersioning=$dotnetBuildFromSource"
|
||||
+ commonMSBuildArgs="/m /clp:Summary /v:$verbosity /p:Configuration=$configuration /p:SolutionPath=$(QQ $MSBuildSolution) /p:CIBuild=$ci /p:DisableNerdbankVersioning=true"
|
||||
+ commonMSBuildArgs="/m:%%MAKE_JOBS_NUMBER%% /clp:Summary /v:$verbosity /p:Configuration=$configuration /p:SolutionPath=$(QQ $MSBuildSolution) /p:CIBuild=$ci /p:DisableNerdbankVersioning=true"
|
||||
|
||||
# Only enable warnaserror on CI runs.
|
||||
if $ci
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue