Skip to content

Commit b8306a3

Browse files
Use single constant definitions.
1 parent a4c40ec commit b8306a3

File tree

3 files changed

+33
-65
lines changed

3 files changed

+33
-65
lines changed

Directory.Build.props

Lines changed: 33 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,10 +29,42 @@
2929
<SuppressNETCoreSdkPreviewMessage>true</SuppressNETCoreSdkPreviewMessage>
3030
</PropertyGroup>
3131

32+
<!--
33+
https://apisof.net/
34+
+===================+================+===================+==============================+======================+==========================+
35+
| Target Framework | SUPPORTS_MATHF | SUPPORTS_HASHCODE | SUPPORTS_EXTENDED_INTRINSICS | SUPPORTS_SPAN_STREAM | SUPPORTS_ENCODING_STRING |
36+
+===================+================+===================+==============================+======================+==========================+
37+
| netcoreapp3.1 | Y | Y | Y | Y | Y |
38+
| netcoreapp2.1 | Y | Y | Y | Y | Y |
39+
| netcoreapp2.0 | Y | N | N | N | N |
40+
| netstandard2.1 | Y | N | N | Y | Y |
41+
| netstandard2.0 | N | N | N | N | N |
42+
| netstandard1.3 | N | N | N | N | N |
43+
| net472 | N | N | Y | N | N |
44+
+===================+================+===================+==============================+======================+==========================+
45+
-->
46+
47+
<!-- TODO: Include additional targets to TargetFrameworks -->
48+
<PropertyGroup Condition=" '$(TargetFramework)' == 'netcoreapp3.1'">
49+
<DefineConstants>$(DefineConstants);SUPPORTS_MATHF;SUPPORTS_HASHCODE;SUPPORTS_EXTENDED_INTRINSICS;SUPPORTS_SPAN_STREAM;SUPPORTS_ENCODING_STRING</DefineConstants>
50+
</PropertyGroup>
51+
<PropertyGroup Condition=" '$(TargetFramework)' == 'netcoreapp2.1'">
52+
<DefineConstants>$(DefineConstants);SUPPORTS_MATHF;SUPPORTS_HASHCODE;SUPPORTS_EXTENDED_INTRINSICS;SUPPORTS_SPAN_STREAM;SUPPORTS_ENCODING_STRING</DefineConstants>
53+
</PropertyGroup>
54+
<PropertyGroup Condition=" '$(TargetFramework)' == 'netcoreapp2.0'">
55+
<DefineConstants>$(DefineConstants);SUPPORTS_MATHF;</DefineConstants>
56+
</PropertyGroup>
57+
<PropertyGroup Condition=" '$(TargetFramework)' == 'netstandard2.1'">
58+
<DefineConstants>$(DefineConstants);SUPPORTS_MATHF;SUPPORTS_SPAN_STREAM;SUPPORTS_ENCODING_STRING</DefineConstants>
59+
</PropertyGroup>
60+
<PropertyGroup Condition=" '$(TargetFramework)' == 'net472'">
61+
<DefineConstants>$(DefineConstants);SUPPORTS_EXTENDED_INTRINSICS</DefineConstants>
62+
</PropertyGroup>
63+
3264
<PropertyGroup Condition="'$(Configuration)' == 'Release'">
3365
<TreatWarningsAsErrors>true</TreatWarningsAsErrors>
3466
</PropertyGroup>
35-
67+
3668
<!--TODO: Check what this is testing for and why does it fail?-->
3769
<PropertyGroup Condition="'$(Configuration)' == 'Debug'">
3870
<CheckForOverflowUnderflow>false</CheckForOverflowUnderflow>

src/ImageSharp.Drawing/ImageSharp.Drawing.csproj

Lines changed: 0 additions & 32 deletions
Original file line numberDiff line numberDiff line change
@@ -12,38 +12,6 @@
1212
<TargetFrameworks>netcoreapp2.1;netstandard2.0;netstandard1.3</TargetFrameworks>
1313
</PropertyGroup>
1414

15-
<!--
16-
https://apisof.net/
17-
+===================+================+===================+==============================+======================+==========================+
18-
| Target Framework | SUPPORTS_MATHF | SUPPORTS_HASHCODE | SUPPORTS_EXTENDED_INTRINSICS | SUPPORTS_SPAN_STREAM | SUPPORTS_ENCODING_STRING |
19-
+===================+================+===================+==============================+======================+==========================+
20-
| netcoreapp3.1 | Y | Y | Y | Y | Y |
21-
| netcoreapp2.1 | Y | Y | Y | Y | Y |
22-
| netcoreapp2.0 | Y | N | N | N | N |
23-
| netstandard2.1 | Y | N | N | Y | Y |
24-
| netstandard2.0 | N | N | N | N | N |
25-
| netstandard1.3 | N | N | N | N | N |
26-
| net472 | N | N | Y | N | N |
27-
+===================+================+===================+==============================+======================+==========================+
28-
-->
29-
30-
<!-- TODO: Include additional targets to TargetFrameworks -->
31-
<PropertyGroup Condition=" '$(TargetFramework)' == 'netcoreapp3.1'">
32-
<DefineConstants>$(DefineConstants);SUPPORTS_MATHF;SUPPORTS_HASHCODE;SUPPORTS_EXTENDED_INTRINSICS;SUPPORTS_SPAN_STREAM;SUPPORTS_ENCODING_STRING</DefineConstants>
33-
</PropertyGroup>
34-
<PropertyGroup Condition=" '$(TargetFramework)' == 'netcoreapp2.1'">
35-
<DefineConstants>$(DefineConstants);SUPPORTS_MATHF;SUPPORTS_HASHCODE;SUPPORTS_EXTENDED_INTRINSICS;SUPPORTS_SPAN_STREAM;SUPPORTS_ENCODING_STRING</DefineConstants>
36-
</PropertyGroup>
37-
<PropertyGroup Condition=" '$(TargetFramework)' == 'netcoreapp2.0'">
38-
<DefineConstants>$(DefineConstants);SUPPORTS_MATHF;</DefineConstants>
39-
</PropertyGroup>
40-
<PropertyGroup Condition=" '$(TargetFramework)' == 'netstandard2.1'">
41-
<DefineConstants>$(DefineConstants);SUPPORTS_MATHF;SUPPORTS_SPAN_STREAM;SUPPORTS_ENCODING_STRING</DefineConstants>
42-
</PropertyGroup>
43-
<PropertyGroup Condition=" '$(TargetFramework)' == 'net472'">
44-
<DefineConstants>$(DefineConstants);SUPPORTS_EXTENDED_INTRINSICS</DefineConstants>
45-
</PropertyGroup>
46-
4715
<ItemGroup>
4816
<PackageReference Include="SixLabors.Fonts" />
4917
<PackageReference Include="SixLabors.Shapes" />

src/ImageSharp/ImageSharp.csproj

Lines changed: 0 additions & 32 deletions
Original file line numberDiff line numberDiff line change
@@ -19,38 +19,6 @@
1919
<RootNamespace>SixLabors.ImageSharp</RootNamespace>
2020
</PropertyGroup>
2121

22-
<!--
23-
https://apisof.net/
24-
+===================+================+===================+==============================+======================+==========================+
25-
| Target Framework | SUPPORTS_MATHF | SUPPORTS_HASHCODE | SUPPORTS_EXTENDED_INTRINSICS | SUPPORTS_SPAN_STREAM | SUPPORTS_ENCODING_STRING |
26-
+===================+================+===================+==============================+======================+==========================+
27-
| netcoreapp3.1 | Y | Y | Y | Y | Y |
28-
| netcoreapp2.1 | Y | Y | Y | Y | Y |
29-
| netcoreapp2.0 | Y | N | N | N | N |
30-
| netstandard2.1 | Y | N | N | Y | Y |
31-
| netstandard2.0 | N | N | N | N | N |
32-
| netstandard1.3 | N | N | N | N | N |
33-
| net472 | N | N | Y | N | N |
34-
+===================+================+===================+==============================+======================+==========================+
35-
-->
36-
37-
<!-- TODO: Include additional targets to TargetFrameworks -->
38-
<PropertyGroup Condition=" '$(TargetFramework)' == 'netcoreapp3.1'">
39-
<DefineConstants>$(DefineConstants);SUPPORTS_MATHF;SUPPORTS_HASHCODE;SUPPORTS_EXTENDED_INTRINSICS;SUPPORTS_SPAN_STREAM;SUPPORTS_ENCODING_STRING</DefineConstants>
40-
</PropertyGroup>
41-
<PropertyGroup Condition=" '$(TargetFramework)' == 'netcoreapp2.1'">
42-
<DefineConstants>$(DefineConstants);SUPPORTS_MATHF;SUPPORTS_HASHCODE;SUPPORTS_EXTENDED_INTRINSICS;SUPPORTS_SPAN_STREAM;SUPPORTS_ENCODING_STRING</DefineConstants>
43-
</PropertyGroup>
44-
<PropertyGroup Condition=" '$(TargetFramework)' == 'netcoreapp2.0'">
45-
<DefineConstants>$(DefineConstants);SUPPORTS_MATHF;</DefineConstants>
46-
</PropertyGroup>
47-
<PropertyGroup Condition=" '$(TargetFramework)' == 'netstandard2.1'">
48-
<DefineConstants>$(DefineConstants);SUPPORTS_MATHF;SUPPORTS_SPAN_STREAM;SUPPORTS_ENCODING_STRING</DefineConstants>
49-
</PropertyGroup>
50-
<PropertyGroup Condition=" '$(TargetFramework)' == 'net472'">
51-
<DefineConstants>$(DefineConstants);SUPPORTS_EXTENDED_INTRINSICS</DefineConstants>
52-
</PropertyGroup>
53-
5422
<ItemGroup>
5523
<Compile Include="..\..\shared-infrastructure\**\*.cs" />
5624
</ItemGroup>

0 commit comments

Comments
 (0)