Skip to content

Mono runtime component infrastructure including EventPipe/DiagnosticsServer as a Mono runtime component. #50837

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 55 commits into from
Apr 20, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
55 commits
Select commit Hold shift + click to select a range
a003944
XXX wip hot reload component - doesn't build - Mar 12
lambdageek Mar 12, 2021
4af6881
XXX - wip hot reload component - checkpoint - it builds - Mar 18
lambdageek Mar 18, 2021
1dc389d
actually export the entrypoint from the components
lambdageek Mar 19, 2021
5a9069f
wip - make mono/component cmake more uniform
lambdageek Mar 19, 2021
e9b865b
wip - mono.proj copy (dynamic) components to artifacts/bin
lambdageek Mar 19, 2021
716b549
wip - mono.proj - fixup component rpaths libmonosgen-2.0.dylib -> lib…
lambdageek Mar 19, 2021
dc56cb3
wip - metadata - call mono_components_init from mono_metadata_init
lambdageek Mar 19, 2021
768da98
wip - components - big component loading hack - code runs now
lambdageek Mar 19, 2021
64e6c6e
wip - initial skeleton of component design document
lambdageek Mar 19, 2021
0db7d16
update doc
lambdageek Mar 22, 2021
a7c8b97
wip - add support for STATIC_COMPONENTS - seems to work
lambdageek Mar 22, 2021
4d4289b
wip - fix dynamic components install_name_tool stuff
lambdageek Mar 23, 2021
c3eaebc
wip - put stubs in the component directory
lambdageek Mar 23, 2021
109b339
wip - default to static components on ios/tvos device and on wasm
lambdageek Mar 24, 2021
d26ed44
Add eglib_objects cmake object target for eglib
lambdageek Mar 24, 2021
b1414bb
wip - static link eglib_objects into dynamic components
lambdageek Mar 25, 2021
812067b
Convert EventPipe/DiagnosticsServer into components.
lateralusX Mar 25, 2021
bbb9c92
Use EventPipe component API from runtime.
lateralusX Mar 26, 2021
9314372
Export needed Mono API's used by component.
lateralusX Mar 29, 2021
fad70f7
Correctly export/import symbols on Windows.
lateralusX Mar 29, 2021
31d1cd4
Resolve components_dir based on coreclr location.
lateralusX Mar 29, 2021
3f87923
Keep eventpipe/diagnostic server sources separated until added to com…
lateralusX Mar 29, 2021
a698804
Enable Diagnostics TCP PAL for iOS and Android.
lateralusX Mar 30, 2021
aa53572
EventPipe/DiagnosticServer as static components.
lateralusX Mar 30, 2021
63ea63a
Fix EventPipe tests after switching to component based arch.
lateralusX Mar 30, 2021
997f30f
Fix memory leak in EventPipe buffer manager.
lateralusX Mar 30, 2021
a3844c1
Fix osx builds.
lateralusX Mar 31, 2021
b933f9c
Fix iOS builds.
lateralusX Mar 31, 2021
d9b55a6
Fix some warnings.
lateralusX Mar 31, 2021
84c5704
Add support to disable components.
lateralusX Apr 1, 2021
8e28f27
Quite hot_reload component.
lateralusX Apr 1, 2021
850367b
Build shared mono runtime using final library name.
lateralusX Apr 1, 2021
bcbe7bc
Fix multiple components hosted by same shared library.
lateralusX Apr 1, 2021
73738a8
Use static components and disable TCP/IP.
lateralusX Apr 6, 2021
dd59777
Cleanup after rebase/merge.
lateralusX Apr 7, 2021
e730fdd
Removed components.md.
lateralusX Apr 7, 2021
be1778a
Only build mono dac shared library on Windows x64 and don't install.
lateralusX Apr 8, 2021
853dd85
Split static and shared lib names.
lateralusX Apr 8, 2021
e9238e3
Add component artifacts to installer pkg.
lateralusX Apr 8, 2021
cf6710e
Make owning_thread_id a little less racy on EP_CHECKED_BUILD.
lateralusX Apr 8, 2021
7eba3c4
Emit EEStartupStart event on Mono runtime.
lateralusX Apr 8, 2021
b74160c
Fix DISABLE_COMPONENTS to included needed stubs in monosgen-2.0 stati…
lateralusX Apr 9, 2021
773315f
Switch WebAssembly over to DISABLE_COMPONENTS (eventpipe and hot-relo…
lateralusX Apr 9, 2021
95e5a36
Add component link support in Android/iOS AppBuilder
lateralusX Apr 13, 2021
f79ae26
Add ability to disable link of static components into shared runtime …
lateralusX Apr 13, 2021
45c96d5
Enable diagnostics server TCP PAL for iOS and Android.
lateralusX Apr 13, 2021
1891d94
Remove ep->ds dependecy using callback.
lateralusX Apr 14, 2021
6b88bfa
Bundle DiagnosticsServer/EventPipe in diagnostics_tracing component.
lateralusX Apr 14, 2021
3213dec
Fix warning.
lateralusX Apr 15, 2021
0c83477
Fix linking of none stub components on Android.
lateralusX Apr 15, 2021
65cdb35
Remove changes done to components.md.
lateralusX Apr 15, 2021
f15dc9b
Review feedback.
lateralusX Apr 16, 2021
28606d8
Fix none Windows build error.
lateralusX Apr 16, 2021
58a349c
Only include lib once in runtime artifacts when not building shared l…
lateralusX Apr 16, 2021
277159c
Only install static libraries on platforms currently shipping them.
lateralusX Apr 16, 2021
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
16 changes: 16 additions & 0 deletions src/installer/pkg/sfx/Microsoft.NETCore.App/Directory.Build.props
Original file line number Diff line number Diff line change
Expand Up @@ -169,13 +169,29 @@
<PlatformManifestFileEntry Include="Microsoft.DiaSymReader.Native.arm.dll" IsNative="true" FallbackFileVersion="$(MicrosoftDiaSymReaderNativeFileVersion)" />
<PlatformManifestFileEntry Include="Microsoft.DiaSymReader.Native.arm64.dll" IsNative="true" FallbackFileVersion="$(MicrosoftDiaSymReaderNativeFileVersion)" />
<!-- Mono-specific files -->
<PlatformManifestFileEntry Include="libmonosgen-2.0.lib" IsNative="true" />
<PlatformManifestFileEntry Include="libmonosgen-2.0.a" IsNative="true" />
<PlatformManifestFileEntry Include="libmonosgen-2.0.so" IsNative="true" />
<PlatformManifestFileEntry Include="libmonosgen-2.0.dylib" IsNative="true" />
<PlatformManifestFileEntry Include="llc" IsNative="true" />
<PlatformManifestFileEntry Include="mono-aot-cross" IsNative="true" />
<PlatformManifestFileEntry Include="mono-aot-cross.exe" IsNative="true" FallbackFileVersion="6.0.0" />
<PlatformManifestFileEntry Include="opt" IsNative="true" />
<!-- Mono components specific files -->
<PlatformManifestFileEntry Include="libmono-component-diagnostics_tracing-static.dll" IsNative="true" />
<PlatformManifestFileEntry Include="libmono-component-diagnostics_tracing-static.so" IsNative="true" />
<PlatformManifestFileEntry Include="libmono-component-diagnostics_tracing-static.dylib" IsNative="true" />
<PlatformManifestFileEntry Include="libmono-component-diagnostics_tracing-static.a" IsNative="true" />
<PlatformManifestFileEntry Include="libmono-component-diagnostics_tracing-stub-static.a" IsNative="true" />
<PlatformManifestFileEntry Include="libmono-component-diagnostics_tracing-static.lib" IsNative="true" />
<PlatformManifestFileEntry Include="libmono-component-diagnostics_tracing-stub-static.lib" IsNative="true" />
<PlatformManifestFileEntry Include="libmono-component-hot_reload-static.dll" IsNative="true" />
<PlatformManifestFileEntry Include="libmono-component-hot_reload-static.so" IsNative="true" />
<PlatformManifestFileEntry Include="libmono-component-hot_reload-static.dylib" IsNative="true" />
<PlatformManifestFileEntry Include="libmono-component-hot_reload-static.a" IsNative="true" />
<PlatformManifestFileEntry Include="libmono-component-hot_reload-stub-static.a" IsNative="true" />
<PlatformManifestFileEntry Include="libmono-component-hot_reload-static.lib" IsNative="true" />
<PlatformManifestFileEntry Include="libmono-component-hot_reload-stub-static.lib" IsNative="true" />
<!-- Mono WASM-specific files -->
<PlatformManifestFileEntry Include="libmono-ee-interp.a" IsNative="true" />
<PlatformManifestFileEntry Include="libmono-icall-table.a" IsNative="true" />
Expand Down
21 changes: 20 additions & 1 deletion src/mono/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,14 @@ set(CMAKE_CXX_FLAGS_CHECKED "")
set(CMAKE_EXE_LINKER_FLAGS_CHECKED "")
set(CMAKE_SHARED_LINKER_FLAGS_CHECKED "")

if(NOT MONO_LIB_NAME)
set(MONO_LIB_NAME "monosgen-2.0")
endif()

if(NOT MONO_SHARED_LIB_NAME)
set(MONO_SHARED_LIB_NAME "$(MONO_LIB_NAME)")
endif()

include(GNUInstallDirs)
include(CheckIncludeFile)
include(CheckFunctionExists)
Expand Down Expand Up @@ -106,7 +114,6 @@ if(DISABLE_INTERPRETER)
endif()

add_definitions(-DHAVE_CONFIG_H)
add_definitions(-DMONO_DLL_EXPORT)

if(GCC)
add_definitions(-g) # TODO: should this really be on by default?
Expand Down Expand Up @@ -652,6 +659,18 @@ if (CMAKE_BUILD_TYPE STREQUAL "Debug")
endif()
### End of debug build checks

######################################
# COMPONENT BUILD CHECKS
######################################
if(DISABLE_COMPONENTS AND NOT STATIC_COMPONENTS)
set(STATIC_COMPONENTS 1)
endif()

if(DISABLE_LINK_STATIC_COMPONENTS AND NOT STATIC_COMPONENTS)
set(STATIC_COMPONENTS 1)
endif()
### End of component build checks

######################################
# OTHER CHECKS
######################################
Expand Down
4 changes: 3 additions & 1 deletion src/mono/cmake/config.h.in
Original file line number Diff line number Diff line change
Expand Up @@ -1052,9 +1052,11 @@
/* Enable runtime support for metadata updates */
#cmakedefine ENABLE_METADATA_UPDATE 1

/* Enable static linking of mono runtime components */
#cmakedefine STATIC_COMPONENTS

#if defined(ENABLE_LLVM) && defined(HOST_WIN32) && defined(TARGET_WIN32) && (!defined(TARGET_AMD64) || !defined(_MSC_VER))
#error LLVM for host=Windows and target=Windows is only supported on x64 MSVC build.
#endif

#endif

2 changes: 2 additions & 0 deletions src/mono/cmake/options.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -53,10 +53,12 @@ option (ENABLE_CHECKED_BUILD_THREAD "Enable runtime history of per-thread coop s
option (ENABLE_CHECKED_BUILD_METADATA "Enable runtime checks of mempool references between metadata images (must set env var MONO_CHECK_MODE=metadata)")
option (ENABLE_METADATA_UPDATE "Enable runtime support for metadata updates")
option (ENABLE_MSCORDBI "Generate mscordbi to support icordbg interface")
option (STATIC_COMPONENTS "Compile mono runtime components as static (not dynamic) libraries")

set (GC_SUSPEND "default" CACHE STRING "GC suspend method (default, preemptive, coop, hybrid)")
set (CHECKED_BUILD "" CACHE STRING "Set ENABLE_CHECKED_BUILD_ options at once. Comma-separated list of lowercase ENABLE_CHECKED_BUILD_ options ie. 'gc,threads,private_types' etc.")
set (ENABLE_MINIMAL "" CACHE STRING "Set many DISABLE_ options at once. Comma-separated list of lowercase DISABLE_ options ie. 'jit,simd' etc.")
set (AOT_TARGET_TRIPLE "" CACHE STRING "Target triple for AOT cross compiler")
set (AOT_OFFSETS_FILE "" CACHE STRING "Offsets file for AOT cross compiler")
set (LLVM_PREFIX "" CACHE STRING "Enable LLVM support with LLVM installed at <LLVM_PREFIX>.")

92 changes: 60 additions & 32 deletions src/mono/mono.proj
Original file line number Diff line number Diff line change
Expand Up @@ -19,24 +19,24 @@
<ScriptExt Condition="'$(OS)' == 'Windows_NT'">.cmd</ScriptExt>
<ScriptExt Condition="'$(OS)' != 'Windows_NT'">.sh</ScriptExt>
<ExeExt Condition="'$(OS)' == 'Windows_NT'">.exe</ExeExt>
<LibExt Condition="'$(TargetsWindows)' == 'true'">.dll</LibExt>
<LibExt Condition="'$(TargetsOSX)' == 'true'">.dylib</LibExt>
<LibExt Condition="'$(TargetsMacCatalyst)' == 'true'">.dylib</LibExt>
<LibExt Condition="'$(LibExt)' == ''">.so</LibExt>
<LibPrefix Condition="'$(TargetsOSX)' == 'true'">lib</LibPrefix>
<LibPrefix Condition="'$(TargetsMacCatalyst)' == 'true'">lib</LibPrefix>
<LibPrefix Condition="'$(TargetsWindows)' != 'true'">lib</LibPrefix>
<SharedLibExt Condition="'$(TargetsOSX)' == 'true' or '$(TargetsMacCatalyst)' == 'true' or '$(TargetsiOS)' == 'true' or '$(TargetstvOS)' == 'true'">.dylib</SharedLibExt>
<SharedLibExt Condition="'$(TargetsWindows)' == 'true'">.dll</SharedLibExt>
<SharedLibExt Condition="'$(SharedLibExt)' == ''">.so</SharedLibExt>
<StaticLibExt Condition="'$(TargetsWindows)' == 'true'">.lib</StaticLibExt>
<StaticLibExt Condition="'$(StaticLibExt)' == ''">.a</StaticLibExt>
<EscapedQuoteW Condition="'$(OS)' == 'Windows_NT'">\&quot;</EscapedQuoteW>
<PythonCmd Condition="'$(OS)' != 'Windows_NT'">python3</PythonCmd>
<PythonCmd Condition="'$(OS)' == 'Windows_NT'">python</PythonCmd>
<CoreClrFileName Condition="'$(TargetsWindows)' == 'true'">coreclr.dll</CoreClrFileName>
<CoreClrFileName Condition="'$(TargetsOSX)' == 'true'">libcoreclr.dylib</CoreClrFileName>
<CoreClrFileName Condition="'$(TargetsMacCatalyst)' == 'true'">libcoreclr.dylib</CoreClrFileName>
<CoreClrFileName Condition="'$(CoreClrFileName)' == ''">libcoreclr.so</CoreClrFileName>
<MonoFileName Condition="'$(TargetsiOS)' == 'true' or '$(TargetstvOS)' == 'true'">libmonosgen-2.0.dylib</MonoFileName>
<MonoFileName Condition="'$(TargetsAndroid)' == 'true'">libmonosgen-2.0.so</MonoFileName>
<MonoFileName Condition="'$(TargetsBrowser)' == 'true'">libmonosgen-2.0.a</MonoFileName>
<MonoFileName Condition="'$(MonoFileName)' == ''">$(CoreClrFileName)</MonoFileName>
<MonoStaticFileName Condition="'$(TargetsMacCatalyst)' == 'true' or '$(TargetsiOS)' == 'true' or '$(TargetstvOS)' == 'true' or '$(TargetsAndroid)' == 'true'">libmonosgen-2.0.a</MonoStaticFileName>
<CoreClrLibName>coreclr</CoreClrLibName>
<CoreClrFileName>$(LibPrefix)$(CoreClrLibName)$(SharedLibExt)</CoreClrFileName>
<MonoLibName>monosgen-2.0</MonoLibName>
<MonoSharedLibName Condition="'$(TargetsiOS)' == 'true' or '$(TargetstvOS)' == 'true' or '$(TargetsAndroid)' == 'true' or '$(TargetsBrowser)' == 'true'">$(MonoLibName)</MonoSharedLibName>
<MonoSharedLibName Condition="'$(MonoSharedLibName)' == ''">$(CoreClrLibName)</MonoSharedLibName>
<MonoSharedLibFileName>$(LibPrefix)$(MonoSharedLibName)$(SharedLibExt)</MonoSharedLibFileName>
<MonoStaticLibFileName>$(LibPrefix)$(MonoLibName)$(StaticLibExt)</MonoStaticLibFileName>
<MonoFileName Condition="'$(TargetsBrowser)' == 'true'">$(MonoStaticLibFileName)</MonoFileName>
<MonoFileName Condition="'$(MonoFileName)' == ''">$(MonoSharedLibFileName)</MonoFileName>
<CoreClrTestConfig Condition="'$(CoreClrTestConfig)' == ''">$(Configuration)</CoreClrTestConfig>
<LibrariesTestConfig Condition="'$(LibrariesTestConfig)' == ''">$(Configuration)</LibrariesTestConfig>
<CoreClrTestCoreRoot>$([MSBuild]::NormalizeDirectory('$(ArtifactsDir)', 'tests', 'coreclr', '$(TargetOS).$(Platform).$(CoreClrTestConfig)', 'Tests', 'Core_Root'))</CoreClrTestCoreRoot>
Expand Down Expand Up @@ -74,6 +74,16 @@
<MonoThreadSuspend Condition="'$(MonoThreadSuspend)' == ''">hybrid</MonoThreadSuspend>
</PropertyGroup>

<!-- How to build runtime components? Static or dynamic. -->
<PropertyGroup>
<MonoComponentsStatic Condition="'$(TargetsBrowser)' == 'true' and '$(MonoComponentsStatic)' == ''">true</MonoComponentsStatic>
<MonoComponentsStatic Condition="'$(TargetsiOS)' == 'true' and '$(TargetsiOSSimulator)' != 'true' and '$(MonoComponentsStatic)' == ''">true</MonoComponentsStatic>
<MonoComponentsStatic Condition="'$(TargetstvOS)' == 'true' and '$(TargetstvOSSimulator)' != 'true' and '$(MonoComponentsStatic)' == ''">true</MonoComponentsStatic>
<!-- by default, do dynamic components -->
<!-- TODO: Change to dynamic as default once package/deploy is fixed for all targets -->
<MonoComponentsStatic Condition="'$(MonoComponentsStatic)' == ''">true</MonoComponentsStatic>
</PropertyGroup>

<ItemGroup Condition="'$(TargetsBrowser)' == 'true' or '$(TargetsiOS)' == 'true' or '$(TargetstvOS)' == 'true'">
<PackageReference Include="Microsoft.NETCore.Runtime.ICU.Transport" PrivateAssets="all" Version="$(MicrosoftNETCoreRuntimeICUTransportVersion)" GeneratePathProperty="true" />
</ItemGroup>
Expand Down Expand Up @@ -190,6 +200,8 @@
<_MonoCMakeArgs Condition="'$(CMakeArgs)' != ''" Include="$(CMakeArgs)"/>
<_MonoCMakeArgs Condition="'$(MonoEnableLLVM)' == 'true'" Include="-DLLVM_PREFIX=$(MonoLLVMDir.TrimEnd('\/'))" />
<_MonoCMakeArgs Include="-DGC_SUSPEND=$(MonoThreadSuspend)" />
<_MonoCMakeArgs Include="-DMONO_LIB_NAME=$(MonoLibName)" />
<_MonoCMakeArgs Include="-DMONO_SHARED_LIB_NAME=$(MonoSharedLibName)" />
</ItemGroup>

<!-- We build LLVM bits for x64 Linux without C++11 ABI (CentOS 7 has libstdc++ < 5.1) -->
Expand Down Expand Up @@ -272,10 +284,11 @@
<_MonoMinimal Condition="'$(Configuration)' == 'Release' and '$(MonoEnableAssertMessages)' != 'true'">$(_MonoMinimal),assert_messages</_MonoMinimal>
</PropertyGroup>
<ItemGroup Condition="'$(TargetsBrowser)' == 'true'">
<_MonoCMakeArgs Include="-DENABLE_MINIMAL=jit,portability,sgen_major_marksweep_conc,sgen_split_nursery,sgen_gc_bridge,sgen_toggleref,sgen_debug_helpers,sgen_binary_protocol,logging,shared_perfcounters,interpreter,threads,eventpipe,qcalls$(_MonoMinimal)"/>
<_MonoCMakeArgs Include="-DENABLE_MINIMAL=jit,portability,sgen_major_marksweep_conc,sgen_split_nursery,sgen_gc_bridge,sgen_toggleref,sgen_debug_helpers,sgen_binary_protocol,logging,shared_perfcounters,interpreter,threads,qcalls$(_MonoMinimal)"/>
<_MonoCMakeArgs Include="-DENABLE_INTERP_LIB=1"/>
<_MonoCMakeArgs Include="-DDISABLE_ICALL_TABLES=1"/>
<_MonoCMakeArgs Include="-DDISABLE_CRASH_REPORTING=1"/>
<_MonoCMakeArgs Include="-DDISABLE_COMPONENTS=1"/>
<_MonoCMakeArgs Include="-DENABLE_ICALL_EXPORT=1"/>
<_MonoCMakeArgs Include="-DENABLE_LAZY_GC_THREAD_CREATION=1"/>
<_MonoCMakeArgs Include="-DENABLE_LLVM_RUNTIME=1"/>
Expand Down Expand Up @@ -349,7 +362,6 @@
<_MonoCMakeArgs Include="-DENABLE_MINIMAL=ssa,portability,logging" />
<_MonoCMakeArgs Include="-DENABLE_SIGALTSTACK=1"/>
<_MonoCMakeArgs Include="-DDISABLE_CRASH_REPORTING=1"/>
<_MonoCMakeArgs Include="-DENABLE_PERFTRACING=0"/>

<_MonoCFLAGS Condition="'$(Platform)' == 'arm'" Include="-march=armv7-a" />
<_MonoCFLAGS Condition="'$(Platform)' == 'arm'" Include="-mtune=cortex-a8" />
Expand Down Expand Up @@ -396,6 +408,17 @@
<_MonoCMakeArgs Include="-DENABLE_MSCORDBI=1" />
</ItemGroup>

<ItemGroup Condition="'$(TargetsiOS)' == 'true' or '$(TargetstvOS)' == 'true' or '$(TargetsAndroid)' == 'true'">
<_MonoCMakeArgs Include="-DFEATURE_PERFTRACING_PAL_TCP=1"/>
<_MonoCMakeArgs Include="-DFEATURE_PERFTRACING_DISABLE_LISTEN_PORTS=1"/>
<_MonoCMakeArgs Include="-DDISABLE_LINK_STATIC_COMPONENTS=1" />
</ItemGroup>

<!-- Components -->
<ItemGroup Condition="'$(MonoComponentsStatic)' == 'true'">
<_MonoCMakeArgs Include="-DSTATIC_COMPONENTS=1" />
</ItemGroup>

<PropertyGroup>
<_MonoCFLAGSOption>-DCMAKE_C_FLAGS="@(_MonoCPPFLAGS, ' ') @(_MonoCFLAGS, ' ')"</_MonoCFLAGSOption>
<_MonoCXXFLAGSOption>-DCMAKE_CXX_FLAGS="@(_MonoCPPFLAGS, ' ') @(_MonoCXXFLAGS, ' ')"</_MonoCXXFLAGSOption>
Expand Down Expand Up @@ -546,6 +569,7 @@
<MonoAOTCMakeArgs Include="-DENABLE_ICALL_SYMBOL_MAP=1" />
<MonoAOTCMakeArgs Include="-DDISABLE_SHARED_LIBS=1" />
<MonoAOTCMakeArgs Include="-DDISABLE_LIBS=1" />
<MonoAOTCMakeArgs Include="-DDISABLE_COMPONENTS=1" />
<MonoAOTCMakeArgs Condition="'$(MonoAotOffsetsFile)' != ''" Include="-DAOT_OFFSETS_FILE=&quot;$(MonoAotOffsetsFile)&quot;" />
<MonoAOTCMakeArgs Condition="'$(MonoAOTEnableLLVM)' == 'true'" Include="-DLLVM_PREFIX=$(MonoAOTLLVMDir.TrimEnd('\/'))" />
<MonoAOTCMakeArgs Include="$(_MonoAOTCFLAGSOption)" />
Expand Down Expand Up @@ -607,14 +631,9 @@
<!-- General targets -->
<Target Name="BuildMono" AfterTargets="Build" DependsOnTargets="$(MonoDependsOnTargets)">
<PropertyGroup Condition="'$(BuildMonoAOTCrossCompilerOnly)' != 'true'">
<_MonoRuntimeFilePath Condition="'$(TargetsWindows)' == 'true'">$(MonoObjDir)out\bin\monosgen-2.0.dll</_MonoRuntimeFilePath>
<_MonoRuntimeFilePath Condition="'$(TargetsOSX)' == 'true'">$(MonoObjDir)out\lib\libmonosgen-2.0.dylib</_MonoRuntimeFilePath>
<_MonoRuntimeFilePath Condition="'$(TargetsMacCatalyst)' == 'true'">$(MonoObjDir)out\lib\libmonosgen-2.0.dylib</_MonoRuntimeFilePath>
<_MonoRuntimeFilePath Condition="'$(TargetsiOS)' == 'true'">$(MonoObjDir)out\lib\libmonosgen-2.0.dylib</_MonoRuntimeFilePath>
<_MonoRuntimeFilePath Condition="'$(TargetstvOS)' == 'true'">$(MonoObjDir)out\lib\libmonosgen-2.0.dylib</_MonoRuntimeFilePath>
<_MonoRuntimeFilePath Condition="'$(TargetsBrowser)' == 'true'">$(MonoObjDir)out\lib\libmonosgen-2.0.a</_MonoRuntimeFilePath>
<_MonoRuntimeFilePath Condition="'$(_MonoRuntimeFilePath)' == ''">$(MonoObjDir)out\lib\libmonosgen-2.0.so</_MonoRuntimeFilePath>
<_MonoRuntimeStaticFilePath Condition="'$(TargetsMacCatalyst)' == 'true' or '$(TargetsiOS)' == 'true' or '$(TargetstvOS)' == 'true' or '$(TargetsAndroid)' == 'true'">$(MonoObjDir)out\lib\libmonosgen-2.0.a</_MonoRuntimeStaticFilePath>
<_MonoRuntimeFilePath Condition="'$(TargetsWindows)' == 'true'">$(MonoObjDir)out\bin\$(MonoFileName)</_MonoRuntimeFilePath>
<_MonoRuntimeFilePath Condition="'$(_MonoRuntimeFilePath)' == ''">$(MonoObjDir)out\lib\$(MonoFileName)</_MonoRuntimeFilePath>
<_MonoRuntimeStaticFilePath Condition="'$(TargetsMacCatalyst)' == 'true' or '$(TargetsiOS)' == 'true' or '$(TargetstvOS)' == 'true' or '$(TargetsAndroid)' == 'true'">$(MonoObjDir)out\lib\$(MonoStaticLibFileName)</_MonoRuntimeStaticFilePath>
<_MonoIncludeInterpStaticFiles Condition="'$(TargetsBrowser)' == 'true'">true</_MonoIncludeInterpStaticFiles>
<_MonoIncludeIcuFiles Condition="'$(TargetsiOS)' == 'true' or '$(TargetstvOS)' == 'true'">true</_MonoIncludeIcuFiles>
</PropertyGroup>
Expand All @@ -624,11 +643,20 @@

<!-- Copy Mono runtime files to artifacts directory -->
<ItemGroup>
<_MonoRuntimeArtifacts Include="$(_MonoRuntimeFilePath)">
<_MonoRuntimeComponentsStaticFilePath Include="$([System.IO.Directory]::GetParent($(_MonoRuntimeFilePath)))\libmono-component-*$(StaticLibExt)" Condition="Exists($(_MonoRuntimeFilePath))" />
<_MonoRuntimeComponentsSharedFilePath Include="$([System.IO.Directory]::GetParent($(_MonoRuntimeFilePath)))\libmono-component-*$(SharedLibExt)" Condition="Exists($(_MonoRuntimeFilePath))" />
<_MonoRuntimeArtifacts Include="$(_MonoRuntimeFilePath)" Condition="Exists($(_MonoRuntimeFilePath))">
<Destination>$(RuntimeBinDir)$(MonoFileName)</Destination>
</_MonoRuntimeArtifacts>
<_MonoRuntimeArtifacts Include="$(_MonoRuntimeStaticFilePath)">
<Destination>$(RuntimeBinDir)$(MonoStaticFileName)</Destination>
<_MonoRuntimeArtifacts Include="$(_MonoRuntimeStaticFilePath)" Condition="Exists($(_MonoRuntimeStaticFilePath)) and '$(_MonoRuntimeStaticFilePath)' != '$(_MonoRuntimeFilePath)'">
<Destination>$(RuntimeBinDir)$(MonoStaticLibFileName)</Destination>
</_MonoRuntimeArtifacts>
<!-- copy the mono runtime component shared or static libraries -->
<_MonoRuntimeArtifacts Include="@(_MonoRuntimeComponentsStaticFilePath)">
<Destination>$(RuntimeBinDir)%(_MonoRuntimeComponentsStaticFilePath.Filename)%(_MonoRuntimeComponentsStaticFilePath.Extension)</Destination>
</_MonoRuntimeArtifacts>
<_MonoRuntimeArtifacts Include="@(_MonoRuntimeComponentsSharedFilePath)">
<Destination>$(RuntimeBinDir)%(_MonoRuntimeComponentsSharedFilePath.Filename)%(_MonoRuntimeComponentsSharedFilePath.Extension)</Destination>
</_MonoRuntimeArtifacts>
<_MonoRuntimeArtifacts Include="$(_MonoAotCrossFilePath)">
<Destination>$(RuntimeBinDir)cross\$(PackageRID)\mono-aot-cross$(ExeExt)</Destination>
Expand Down Expand Up @@ -658,11 +686,11 @@
<_MonoRuntimeArtifacts Condition="'$(TargetsBrowser)' == 'true' and '$(BuildMonoAOTCrossCompilerOnly)' != 'true'" Include="$(MonoObjDir)out\lib\libmono-profiler-aot.a">
<Destination>$(RuntimeBinDir)libmono-profiler-aot.a</Destination>
</_MonoRuntimeArtifacts>
<_MonoICorDebugArtifacts Condition="'$(MonoMsCorDbi)' == 'true'" Include="$(MonoObjDir)out\lib\$(LibPrefix)dbgshim$(LibExt)">
<Destination>$(RuntimeBinDir)$(LibPrefix)dbgshim$(LibExt)</Destination>
<_MonoICorDebugArtifacts Condition="'$(MonoMsCorDbi)' == 'true'" Include="$(MonoObjDir)out\lib\$(LibPrefix)dbgshim$(SharedLibExt)">
<Destination>$(RuntimeBinDir)$(LibPrefix)dbgshim$(SharedLibExt)</Destination>
</_MonoICorDebugArtifacts>
<_MonoICorDebugArtifacts Condition="'$(MonoMsCorDbi)' == 'true'" Include="$(MonoObjDir)out\lib\$(LibPrefix)mscordbi$(LibExt)">
<Destination>$(RuntimeBinDir)$(LibPrefix)mscordbi$(LibExt)</Destination>
<_MonoICorDebugArtifacts Condition="'$(MonoMsCorDbi)' == 'true'" Include="$(MonoObjDir)out\lib\$(LibPrefix)mscordbi$(SharedLibExt)">
<Destination>$(RuntimeBinDir)$(LibPrefix)mscordbi$(SharedLibExt)</Destination>
</_MonoICorDebugArtifacts>

<_IcuArtifacts Condition="'$(_MonoIncludeIcuFiles)' == 'true'"
Expand Down
6 changes: 0 additions & 6 deletions src/mono/mono/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -2,12 +2,6 @@ project(mono)

set(subdirs mini profiler)

if(ENABLE_PERFTRACING)
list(APPEND subdirs
eventpipe/test
)
endif(ENABLE_PERFTRACING)

foreach(dir ${subdirs})
add_subdirectory(${dir})
endforeach()
Loading