Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/mono/monodevelop.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMikayla Hutchinson <m.j.hutchinson@gmail.com>2018-06-16 07:14:08 +0300
committerMikayla Hutchinson <m.j.hutchinson@gmail.com>2018-06-20 16:59:38 +0300
commitfa72e185176061d9bad894d89ce68dfc31b1072f (patch)
tree9f30668e7e8bdcbdc3ab295fdcf68b332dace6c8
parent2b9a36e536b33d64f0726a6cd407ee3ad46c442f (diff)
Set up a bunch of common project props
This will mean projects can skip setting them. This should also make projects more consistent and easier to read.
-rw-r--r--main/msbuild/MonoDevelop.AfterCommon.props7
-rw-r--r--main/msbuild/MonoDevelop.BeforeCommon.targets45
2 files changed, 37 insertions, 15 deletions
diff --git a/main/msbuild/MonoDevelop.AfterCommon.props b/main/msbuild/MonoDevelop.AfterCommon.props
index dae19fed55..d3e6a9009a 100644
--- a/main/msbuild/MonoDevelop.AfterCommon.props
+++ b/main/msbuild/MonoDevelop.AfterCommon.props
@@ -22,4 +22,11 @@
<PropertyGroup>
<MDBuildTasks>$(MSBuildThisFileDirectory)</MDBuildTasks>
</PropertyGroup>
+
+ <!-- set a bunch of default value the project can override -->
+ <PropertyGroup>
+ <OutputType>Library</OutputType>
+ <AssemblyName>$(MSBuildProjectName)</AssemblyName>
+ <RootNamespace>$(MSBuildProjectName)</RootNamespace>
+ </PropertyGroup>
</Project>
diff --git a/main/msbuild/MonoDevelop.BeforeCommon.targets b/main/msbuild/MonoDevelop.BeforeCommon.targets
index 7d6f766b24..c06c7740df 100644
--- a/main/msbuild/MonoDevelop.BeforeCommon.targets
+++ b/main/msbuild/MonoDevelop.BeforeCommon.targets
@@ -4,26 +4,41 @@
<MSBuildAllProjects>$(MSBuildAllProjects);$(MSBuildThisFileFullPath)</MSBuildAllProjects>
</PropertyGroup>
- <!-- force Roslyn compiler -->
- <PropertyGroup Condition="'$(OS)'=='Unix' And '$(MSBuildProjectExtension)'=='.csproj'">
- <_MonoBinDir>$(MSBuildBinPath)\..\..\..\4.5\</_MonoBinDir>
- <CscToolExe>csc.exe</CscToolExe>
- <CscToolPath>$(_MonoBinDir)</CscToolPath>
- <DebugType>portable</DebugType>
- <CscDebugFileExt>.pdb</CscDebugFileExt>
- <_DebugFileExt>.pdb</_DebugFileExt>
- </PropertyGroup>
-
+ <!-- force a bunch of default values for consistency -->
<PropertyGroup>
+ <Optimize>$(MDConfigIsRelease)</Optimize>
+ <DebugSymbols>true</DebugSymbols>
+ <DebugType>portable</DebugType>
+ <WarningLevel>4</WarningLevel>
<Deterministic>True</Deterministic>
+ <!-- always produce docs -->
<OutputPath Condition="!HasTrailingSlash('$(OutputPath)')">$(OutputPath)\</OutputPath>
<DocumentationFile Condition="'$(SuppressDocs)'!='True'">$(OutputPath)$(AssemblyName).xml</DocumentationFile>
- <NoWarn>$(NoWarn);1591</NoWarn>
+ <!-- don't warn about missing doc comments -->
+ <NoWarn>$(NoWarn);1591;1573</NoWarn>
</PropertyGroup>
- <!-- C# only -->
- <PropertyGroup Condition="'$(MSBuildProjectExtension)'=='.csproj'">
- <Deterministic>True</Deterministic>
- <NoWarn>$(NoWarn);1591</NoWarn>
+ <PropertyGroup Condition="$(Configuration.Contains('Debug'))">
+ <DefineConstants>$(DefineConstants);DEBUG</DefineConstants>
+ </PropertyGroup>
+
+ <PropertyGroup Condition="$(Platform.Equals('x86'))">
+ <PlatformTarget>x86</PlatformTarget>
+ </PropertyGroup>
+
+ <PropertyGroup Condition="$(Platform.Equals('x64'))">
+ <PlatformTarget>x64</PlatformTarget>
+ </PropertyGroup>
+
+ <PropertyGroup Condition="$(Configuration.Contains('Mac'))">
+ <DefineConstants>$(DefineConstants);MAC</DefineConstants>
+ </PropertyGroup>
+
+ <PropertyGroup Condition="$(Configuration.Contains('Win32'))">
+ <DefineConstants>$(DefineConstants);WIN32;WINDOWS</DefineConstants>
+ </PropertyGroup>
+
+ <PropertyGroup Condition="$(Configuration.Contains('Gnome'))">
+ <DefineConstants>$(DefineConstants);GNOME;LINUX</DefineConstants>
</PropertyGroup>
</Project>