|
1 | 1 | <Project> |
2 | 2 |
|
3 | | - <Target Name="_CreateMonoInfoProps" |
4 | | - Condition=" ($([MSBuild]::IsOSPlatform ('linux')) Or $([MSBuild]::IsOSPlatform ('osx'))) And '$(_MonoPath)' != '' " |
5 | | - AfterTargets="AfterBuild" |
6 | | - DependsOnTargets="_GetLinuxMonoPaths;_GetMacOSMonoPaths" |
7 | | - Inputs="$(MSBuildThisFileFullPath);$(MSBuildThisFileDirectory)Java.Interop.BootstrapTasks.csproj" |
8 | | - Outputs="$(_OutputPath)MonoInfo.props"> |
9 | | - <ItemGroup> |
10 | | - <_MonoInfoLine Include="<Project>" /> |
11 | | - <_MonoInfoLine Include=" <Choose>" /> |
12 | | - <_MonoInfoLine Include=" <When Condition=" %27%24(MonoFrameworkPath)%27 == %27%27 ">" /> |
13 | | - <_MonoInfoLine Include=" <PropertyGroup>" /> |
14 | | - <_MonoInfoLine Include=" <MonoFrameworkPath>$(_MonoFrameworkPath)</MonoFrameworkPath>" /> |
15 | | - <_MonoInfoLine Include=" <MonoLibs >$(_MonoLibs)</MonoLibs>" /> |
16 | | - <_MonoInfoLine Include=" </PropertyGroup>" /> |
17 | | - <_MonoInfoLine Include=" <ItemGroup>" /> |
18 | | - <_MonoInfoLine Include=" <MonoIncludePath Include="$(_MonoIncludePath)" />" /> |
19 | | - <_MonoInfoLine Include=" </ItemGroup>" /> |
20 | | - <_MonoInfoLine Include=" </When>" /> |
21 | | - <_MonoInfoLine Include=" </Choose>" /> |
22 | | - <_MonoInfoLine Include="</Project>" /> |
23 | | - </ItemGroup> |
24 | | - <WriteLinesToFile |
25 | | - File="$(_OutputPath)MonoInfo.props" |
26 | | - Lines="@(_MonoInfoLine)" |
27 | | - Overwrite="True" |
28 | | - /> |
29 | | - <Touch Files="$(_OutputPath)MonoInfo.props" /> |
30 | | - </Target> |
31 | | - |
32 | | - <Target Name="_CreateMonoMk" |
33 | | - AfterTargets="AfterBuild" |
34 | | - DependsOnTargets="_GetLinuxMonoPaths;_GetMacOSMonoPaths" |
35 | | - Inputs="$(MSBuildThisFileFullPath);$(MSBuildThisFileDirectory)Java.Interop.BootstrapTasks.csproj" |
36 | | - Outputs="$(_OutputPath)mono.mk"> |
37 | | - <ItemGroup> |
38 | | - <_MonoMkLine Include="JI_MONO_LIB_PATH=$(_MonoLibPath)" /> |
39 | | - </ItemGroup> |
40 | | - <WriteLinesToFile |
41 | | - File="$(_OutputPath)mono.mk" |
42 | | - Lines="@(_MonoMkLine)" |
43 | | - Overwrite="True" |
44 | | - /> |
45 | | - <Touch Files="$(_OutputPath)mono.mk" /> |
46 | | - </Target> |
47 | | - |
48 | | - <Target Name="_GetLinuxMonoPath" |
49 | | - Condition=" $([MSBuild]::IsOSPlatform ('linux')) "> |
50 | | - <Exec |
51 | | - Command="which mono" |
52 | | - ConsoleToMsBuild="true" |
53 | | - IgnoreExitCode="true"> |
54 | | - <Output TaskParameter="ConsoleOutput" PropertyName="_MonoPath" /> |
55 | | - </Exec> |
56 | | - </Target> |
57 | | - |
58 | | - <Target Name="_GetLinuxMonoPaths" |
59 | | - DependsOnTargets="_GetLinuxMonoPath" |
60 | | - Condition=" $([MSBuild]::IsOSPlatform ('linux')) And '$(_MonoPath)' != '' "> |
61 | | - <Exec |
62 | | - Command="pkg-config --variable=libdir mono-2" |
63 | | - ConsoleToMsBuild="True"> |
64 | | - <Output TaskParameter="ConsoleOutput" PropertyName="_MonoPkgConfigLibdir" /> |
65 | | - </Exec> |
66 | | - <Exec |
67 | | - Command="pkg-config --variable=includedir mono-2" |
68 | | - ConsoleToMsBuild="True"> |
69 | | - <Output TaskParameter="ConsoleOutput" PropertyName="_MonoPkgConfigIncludedir" /> |
70 | | - </Exec> |
71 | | - <PropertyGroup> |
72 | | - <_MonoLibPath>$([System.IO.Path]::GetDirectoryName($(_MonoPath)))/../lib/</_MonoLibPath> |
73 | | - <_MonoFrameworkPath>$(_MonoPkgConfigLibdir)/libmonosgen-2.0.so</_MonoFrameworkPath> |
74 | | - <_MonoIncludePath>$(_MonoPkgConfigIncludedir)</_MonoIncludePath> |
75 | | - <_MonoLibs>-L "$(_MonoPkgConfigLibdir)" -lmonosgen-2.0</_MonoLibs> |
76 | | - </PropertyGroup> |
77 | | - </Target> |
78 | | - |
79 | | - <Target Name="_GetMacOSMonoPaths" |
80 | | - Condition=" $([MSBuild]::IsOSPlatform ('osx')) "> |
81 | | - <PropertyGroup> |
82 | | - <_MonoBase>/Library/Frameworks/Mono.framework/</_MonoBase> |
83 | | - <_MonoLibPath>$(_MonoBase)Libraries/</_MonoLibPath> |
84 | | - <_MonoFrameworkPath>$(_MonoLibPath)libmonosgen-2.0.1.dylib</_MonoFrameworkPath> |
85 | | - <_MonoIncludePath>$(_MonoBase)Headers/mono-2.0</_MonoIncludePath> |
86 | | - <_MonoLibs>-L "$(_MonoLibPath)" -lmonosgen-2.0</_MonoLibs> |
87 | | - </PropertyGroup> |
88 | | - </Target> |
89 | | - |
90 | | - |
91 | 3 | <Target Name="_CreatePackagePathsProps" |
92 | 4 | AfterTargets="AfterBuild" |
93 | 5 | Inputs="$(MSBuildThisFileFullPath);$(MSBuildThisFileDirectory)Java.Interop.BootstrapTasks.csproj" |
|
0 commit comments