为了dotnetcore运行时的安可目标,特意在国庆假期研究了怎么编译dotnetcore的runtime。由于我们用的是.net6,最新的是8,所以从github下载的.net6的分支代码进行的编译。查遍了国内外资料,估计微软服务太体贴了,竟然没什么编译runtime的资料参照,而开始我也没翻源码doc的文档就自己猜着试了。整体试了4-5天总算自己给完全编译ok了,分享给需要安可的小伙伴,麻烦的应该就是runtime的编译了,因为涉及到cli的c++代码和环境依赖,后面再编译asp.netcore代码。虽然整个过程很痛苦,一直看编译报错和翻他的编译脚本及解决依赖问题和各种尝试。但是收获很多,C#编程环境更可控了,对Linux下c编译更加熟悉了。
成功编译的runtime
首先到开源的dotnet官网下载自己要编译的分支代码到本地
然后把下载的代码上传到linux的根下解压
代码大体层级,这个我是编译成功才翻文档的,早知道文档很明确就不用走这么多弯路了
Linux下的编译文档
Linux下用docker编译的镜像地址,不过国内网不好
dotnetcore编译的docker镜像地址,能够下载镜像的话应该镜像会容易些,不用解决复杂的依赖问题
| OS | Target Arch | Image location | crossrootfs location | Clang Version |
| --------------------------- | --------------- | ---------------------------------------------------------------------------------------------------- | -------------------- | ------------- |
| Ubuntu 16.04 | x64 | `mcr.microsoft.com/dotnet-buildtools/prereqs:ubuntu-16.04-a50a721-20191120200116` | - | -clang9 |
| Alpine | x64 | `mcr.microsoft.com/dotnet-buildtools/prereqs:alpine-3.9-WithNode-20200602002639-0fc54a3` | - | -clang5.0 |
| CentOS 7 (build for RHEL 7) | x64 | `mcr.microsoft.com/dotnet-buildtools/prereqs:centos-7-359e48e-20200313130914` | - | -clang9 |
| Ubuntu 16.04 | arm32 (armhf) | `mcr.microsoft.com/dotnet-buildtools/prereqs:ubuntu-16.04-cross-20200413125008-09ec757` | `/crossrootfs/arm` | -clang9 |
| Ubuntu 16.04 | arm64 (arm64v8) | `mcr.microsoft.com/dotnet-buildtools/prereqs:ubuntu-16.04-cross-arm64-20201022204150-b2c2436` | `/crossrootfs/arm64` | -clang9 |
| Alpine | arm64 (arm64v8) | `mcr.microsoft.com/dotnet-buildtools/prereqs:ubuntu-16.04-cross-arm64-alpine-20200413125008-406629a` | `/crossrootfs/arm64` | -clang9 |
Linux下编译环境具体介绍,参照这个文档应该更准确
以下是我自己在CentOS7的编译经历,最终执行的编译命令是./build.sh --gcc指定用gcc编译了。
首先第一次运行build.sh时候他会下载一个版本的dotnetsdk来支持编译.net得基础库,这个下载很慢,而且没告诉下载到什么地方,
翻他的脚步发现他是把包下载到/root/下dotnet的隐藏文件了,可以把隐藏文件备份处理后面放进去就行了,避免每次下载.net环境慢。也能改他sh脚本的下载地址。
这里cmake版本要对,gcc要比较新,我试的好使的是gcc9,CentOS7默认gcc是4.8,需要升级。cmake也没有要求的版本,需要源码安装。
升级gcc
sudo yum install centos-release-scl
sudo yum install devtoolset-9-gcc*
scl enable devtoolset-9 bash
echo "source /opt/rh/devtoolset-9/enable" >>/etc/profile
编译如果确实新版gcc头文件也是从gcc源码拷贝上传来解决
cmacke源码安装,下载地址https://cmake.org/files/
tar -zxvf cmake-3.16.4-Linux-x86_64.tar.gz
vi /etc/profile
export PATH=$PATH:/cmake-3.16.4-Linux-x86_64/bin
source /etc/profile
vi ~/.bashrc
export PATH=$PATH:/cmake-3.16.4-Linux-x86_64/bin
缺少ttng头文件,这里要安装ttng软件,安装后了还是在usr/include下没头文件,我又到ttng官网下载源码把头文件上传上去才解决,这里也消耗了大量时间。
把下载的源码的头文件上传到/usr/include,其他包缺头文件也是同样处理
cmake版本不对,太高了也不行,太低了也不行。这里按文档要求安装就行。这个事情我消耗了太多时间,版本低了有些代码编译报错,用最新的cmake有的写法已经移除不支持了。
缺少ninja,用yum安装就行
编译成功之后后期操作又缺Python3,由于CentOS7默认安装的是2.7,还不能卸载默认的,卸载默认的之后yum会使用有问题,yum依赖的Python
/bin/sh: Python3_EXECUTABLE-NOTFOUND: command not found
首先从https://www.python.org/ftp/python/3.7.1/Python-3.7.1.tgz下载Python3源码,上传到Linux上编译
先安装依赖,之前我安装里gcc和make额,没安装的先安装编译器
yum install libffi-devel -y
然后进入Python3代码目录生成makefile
chmod +x configure
./configure --prefix=/usr/local
执行编译和编译安装
make
make install
测试
python3 -V
pip -V
都搞定之后执行./build.sh --gcc就是漫长的编译过程了,持续十几分钟能编译完,下面是几个大概的片段
-- Performing Test HAVE_FDS_BITS - Failed
-- Performing Test HAVE_PRIVATE_FDS_BITS
-- Performing Test HAVE_PRIVATE_FDS_BITS - Failed
-- Performing Test HAVE_SENDFILE_4
-- Performing Test HAVE_SENDFILE_4 - Success
-- Performing Test HAVE_SENDFILE_6
-- Performing Test HAVE_SENDFILE_6 - Failed
-- Performing Test HAVE_SENDFILE_7
-- Performing Test HAVE_SENDFILE_7 - Failed
-- Looking for fcopyfile
-- Looking for fcopyfile - not found
-- Looking for include file sys/sockio.h
-- Looking for include file sys/sockio.h - not found
-- Looking for include file linux/ethtool.h
-- Looking for include file linux/ethtool.h - found
-- Looking for include file sys/poll.h
-- Looking for include file sys/poll.h - found
-- Looking for include file sys/proc_info.h
-- Looking for include file sys/proc_info.h - not found
-- Looking for epoll_create1
-- Looking for epoll_create1 - found
-- Looking for accept4
-- Looking for accept4 - found
-- Looking for kqueue
-- Looking for kqueue - not found
-- Looking for disconnectx
-- Looking for disconnectx - not found
-- Performing Test HAVE_GETNAMEINFO_SIGNED_FLAGS
-- Performing Test HAVE_GETNAMEINFO_SIGNED_FLAGS - Success
-- Looking for malloc_size
-- Looking for malloc_size - not found
-- Looking for malloc_usable_size
-- Looking for malloc_usable_size - found
-- Looking for malloc_usable_size
-- Looking for malloc_usable_size - not found
-- Looking for posix_memalign
-- Looking for posix_memalign - found
-- Looking for aligned_alloc
-- Looking for aligned_alloc - found
********************************************************
[ 86%] Building C object System.IO.Compression.Native/CMakeFiles/System.IO.Compression.Native.dir/runtime-6.0.22/src/libraries/Native/AnyOS/brotli/enc/cluster.c.o
[ 87%] Building C object System.IO.Compression.Native/CMakeFiles/System.IO.Compression.Native.dir/runtime-6.0.22/src/libraries/Native/AnyOS/brotli/enc/command.c.o
[ 87%] Building C object System.IO.Compression.Native/CMakeFiles/System.IO.Compression.Native-Static.dir/runtime-6.0.22/src/libraries/Native/AnyOS/brotli/enc/entropy_encode.c.o
[ 87%] Building C object System.IO.Compression.Native/CMakeFiles/System.IO.Compression.Native.dir/runtime-6.0.22/src/libraries/Native/AnyOS/brotli/enc/compress_fragment.c.o
[ 88%] Building C object System.IO.Compression.Native/CMakeFiles/System.IO.Compression.Native-Static.dir/runtime-6.0.22/src/libraries/Native/AnyOS/brotli/enc/fast_log.c.o
[ 88%] Building C object System.IO.Compression.Native/CMakeFiles/System.IO.Compression.Native-Static.dir/runtime-6.0.22/src/libraries/Native/AnyOS/brotli/enc/histogram.c.o
[ 89%] Building C object System.IO.Compression.Native/CMakeFiles/System.IO.Compression.Native.dir/runtime-6.0.22/src/libraries/Native/AnyOS/brotli/enc/compress_fragment_two_pass.c.o
[ 90%] Building C object System.IO.Compression.Native/CMakeFiles/System.IO.Compression.Native-Static.dir/runtime-6.0.22/src/libraries/Native/AnyOS/brotli/enc/literal_cost.c.o
[ 90%] Building C object System.IO.Compression.Native/CMakeFiles/System.IO.Compression.Native-Static.dir/runtime-6.0.22/src/libraries/Native/AnyOS/brotli/enc/memory.c.o
[ 91%] Building C object System.IO.Compression.Native/CMakeFiles/System.IO.Compression.Native-Static.dir/runtime-6.0.22/src/libraries/Native/AnyOS/brotli/enc/metablock.c.o
[ 91%] Building C object System.IO.Compression.Native/CMakeFiles/System.IO.Compression.Native-Static.dir/runtime-6.0.22/src/libraries/Native/AnyOS/brotli/enc/static_dict.c.o
[ 91%] Building C object System.IO.Compression.Native/CMakeFiles/System.IO.Compression.Native.dir/runtime-6.0.22/src/libraries/Native/AnyOS/brotli/enc/dictionary_hash.c.o
[ 92%] Building C object System.IO.Compression.Native/CMakeFiles/System.IO.Compression.Native.dir/runtime-6.0.22/src/libraries/Native/AnyOS/brotli/enc/encode.c.o
[ 93%] Building C object System.IO.Compression.Native/CMakeFiles/System.IO.Compression.Native-Static.dir/runtime-6.0.22/src/libraries/Native/AnyOS/brotli/enc/utf8_util.c.o
[ 93%] Building C object System.IO.Compression.Native/CMakeFiles/System.IO.Compression.Native.dir/runtime-6.0.22/src/libraries/Native/AnyOS/brotli/enc/encoder_dict.c.o
[ 94%] Building C object System.IO.Compression.Native/CMakeFiles/System.IO.Compression.Native-Static.dir/runtime-6.0.22/src/libraries/Native/AnyOS/System.IO.Compression.Native/entrypoints.c.o
[ 94%] Linking C static library libSystem.IO.Compression.Native.a
[ 95%] Building C object System.IO.Compression.Native/CMakeFiles/System.IO.Compression.Native.dir/runtime-6.0.22/src/libraries/Native/AnyOS/brotli/enc/entropy_encode.c.o
[ 95%] Built target System.IO.Compression.Native-Static
[ 95%] Building C object System.IO.Compression.Native/CMakeFiles/System.IO.Compression.Native.dir/runtime-6.0.22/src/libraries/Native/AnyOS/brotli/enc/fast_log.c.o
[ 96%] Building C object System.IO.Compression.Native/CMakeFiles/System.IO.Compression.Native.dir/runtime-6.0.22/src/libraries/Native/AnyOS/brotli/enc/histogram.c.o
[ 96%] Building C object System.IO.Compression.Native/CMakeFiles/System.IO.Compression.Native.dir/runtime-6.0.22/src/libraries/Native/AnyOS/brotli/enc/literal_cost.c.o
[ 97%] Building C object System.IO.Compression.Native/CMakeFiles/System.IO.Compression.Native.dir/runtime-6.0.22/src/libraries/Native/AnyOS/brotli/enc/memory.c.o
[ 97%] Building C object System.IO.Compression.Native/CMakeFiles/System.IO.Compression.Native.dir/runtime-6.0.22/src/libraries/Native/AnyOS/brotli/enc/metablock.c.o
[ 98%] Building C object System.IO.Compression.Native/CMakeFiles/System.IO.Compression.Native.dir/runtime-6.0.22/src/libraries/Native/AnyOS/brotli/enc/static_dict.c.o
[ 99%] Building C object System.IO.Compression.Native/CMakeFiles/System.IO.Compression.Native.dir/runtime-6.0.22/src/libraries/Native/AnyOS/brotli/enc/utf8_util.c.o
[ 99%] Building C object System.IO.Compression.Native/CMakeFiles/System.IO.Compression.Native.dir/runtime-6.0.22/src/libraries/Native/AnyOS/System.IO.Compression.Native/entrypoints.c.o
[100%] Building C object System.IO.Compression.Native/CMakeFiles/System.IO.Compression.Native.dir/__/version.c.o
[100%] Linking C shared library libSystem.IO.Compression.Native.so
Verifying System.IO.Compression.Native entry points against entrypoints.c
Stripping symbols from $<TARGET_FILE:System.IO.Compression.Native> into file $<TARGET_FILE:System.IO.Compression.Native>.dbg
[100%] Built target System.IO.Compression.Native
Install the project...
-- Install configuration: "DEBUG"
-- Installing: /runtime-6.0.22/artifacts/bin/native/net6.0-Linux-Debug-x64/./libSystem.IO.Compression.Native.so.dbg
-- Installing: /runtime-6.0.22/artifacts/bin/native/net6.0-Linux-Debug-x64/./libSystem.IO.Compression.Native.so
-- Installing: /runtime-6.0.22/artifacts/bin/native/net6.0-Linux-Debug-x64/./libSystem.IO.Compression.Native.a
-- Installing: /runtime-6.0.22/artifacts/bin/native/net6.0-Linux-Debug-x64/./libSystem.IO.Ports.Native.so.dbg
-- Installing: /runtime-6.0.22/artifacts/bin/native/net6.0-Linux-Debug-x64/./libSystem.IO.Ports.Native.so
-- Installing: /runtime-6.0.22/artifacts/bin/native/net6.0-Linux-Debug-x64/./libSystem.IO.Ports.Native.a
-- Installing: /runtime-6.0.22/artifacts/bin/native/net6.0-Linux-Debug-x64/./libSystem.Native.so.dbg
-- Installing: /runtime-6.0.22/artifacts/bin/native/net6.0-Linux-Debug-x64/./libSystem.Native.so
-- Installing: /runtime-6.0.22/artifacts/bin/native/net6.0-Linux-Debug-x64/./libSystem.Native.a
-- Installing: /runtime-6.0.22/artifacts/bin/native/net6.0-Linux-Debug-x64/./libSystem.Globalization.Native.so.dbg
-- Installing: /runtime-6.0.22/artifacts/bin/native/net6.0-Linux-Debug-x64/./libSystem.Globalization.Native.so
-- Installing: /runtime-6.0.22/artifacts/bin/native/net6.0-Linux-Debug-x64/./libSystem.Globalization.Native.a
-- Installing: /runtime-6.0.22/artifacts/bin/native/net6.0-Linux-Debug-x64/./libSystem.Net.Security.Native.so.dbg
-- Installing: /runtime-6.0.22/artifacts/bin/native/net6.0-Linux-Debug-x64/./libSystem.Net.Security.Native.so
-- Installing: /runtime-6.0.22/artifacts/bin/native/net6.0-Linux-Debug-x64/./libSystem.Net.Security.Native.a
************************************************************************
System.Security.Cryptography.Xml -> /runtime-6.0.22/artifacts/bin/System.Security.Cryptography.Xml/netstandard2.0-Debug/System.Security.Cryptography.Xml.dll
Microsoft.Extensions.Logging.Debug -> /runtime-6.0.22/artifacts/bin/Microsoft.Extensions.Logging.Debug/netstandard2.0-Debug/Microsoft.Extensions.Logging.Debug.dll
Microsoft.Extensions.Http -> /runtime-6.0.22/artifacts/bin/Microsoft.Extensions.Http/netstandard2.0-Debug/Microsoft.Extensions.Http.dll
Microsoft.Extensions.Logging.EventSource -> /runtime-6.0.22/artifacts/bin/Microsoft.Extensions.Logging.EventSource/netstandard2.0-Debug/Microsoft.Extensions.Logging.EventSource.dll
Microsoft.Extensions.Logging.TraceSource -> /runtime-6.0.22/artifacts/bin/Microsoft.Extensions.Logging.TraceSource/netstandard2.0-Debug/Microsoft.Extensions.Logging.TraceSource.dll
Microsoft.Extensions.Logging.EventLog -> /runtime-6.0.22/artifacts/bin/Microsoft.Extensions.Logging.EventLog/netstandard2.0-Debug/Microsoft.Extensions.Logging.EventLog.dll
Microsoft.Extensions.Logging.Configuration -> /runtime-6.0.22/artifacts/bin/Microsoft.Extensions.Logging.Configuration/netstandard2.0-Debug/Microsoft.Extensions.Logging.Configuration.dll
System.Security.Cryptography.Xml -> /runtime-6.0.22/artifacts/bin/System.Security.Cryptography.Xml/net6.0-Debug/System.Security.Cryptography.Xml.dll
System.Data.OleDb -> /runtime-6.0.22/artifacts/bin/System.Data.OleDb/net6.0-Debug/System.Data.OleDb.dll
Microsoft.Extensions.Logging.Console -> /runtime-6.0.22/artifacts/bin/Microsoft.Extensions.Logging.Console/netstandard2.0-Debug/Microsoft.Extensions.Logging.Console.dll
Microsoft.Extensions.Configuration.Xml -> /runtime-6.0.22/artifacts/bin/Microsoft.Extensions.Configuration.Xml/netstandard2.0-Debug/Microsoft.Extensions.Configuration.Xml.dll
Microsoft.Extensions.Logging.Console -> /runtime-6.0.22/artifacts/bin/Microsoft.Extensions.Logging.Console/net6.0-Debug/Microsoft.Extensions.Logging.Console.dll
Microsoft.Extensions.Hosting -> /runtime-6.0.22/artifacts/bin/Microsoft.Extensions.Hosting/net6.0-Debug/Microsoft.Extensions.Hosting.dll
Microsoft.Extensions.Hosting -> /runtime-6.0.22/artifacts/bin/Microsoft.Extensions.Hosting/netstandard2.1-Debug/Microsoft.Extensions.Hosting.dll
Microsoft.Extensions.Hosting.Systemd -> /runtime-6.0.22/artifacts/bin/Microsoft.Extensions.Hosting.Systemd/netstandard2.1-Debug/Microsoft.Extensions.Hosting.Systemd.dll
Microsoft.Extensions.Hosting.WindowsServices -> /runtime-6.0.22/artifacts/bin/Microsoft.Extensions.Hosting.WindowsServices/netstandard2.1-Debug/Microsoft.Extensions.Hosting.WindowsServices.dll
mscorlib -> /runtime-6.0.22/artifacts/bin/manual.mscorlib/net6.0-Debug/mscorlib.dll
System -> /runtime-6.0.22/artifacts/bin/manual.System/net6.0-Debug/System.dll
System.Data -> /runtime-6.0.22/artifacts/bin/manual.System.Data/net6.0-Debug/System.Data.dll
System.Xml -> /runtime-6.0.22/artifacts/bin/manual.System.Xml/net6.0-Debug/System.Xml.dll
ApiCompat ->
Trimming linux-x64 runtime pack assemblies with ILLinker...
Trimming linux-x64 OOB assemblies with ILLinker...
externals ->
Microsoft.NETCore.App.Runtime.Composite ->
/runtime-6.0.22/artifacts/obj/Microsoft.NETCore.App.Runtime.Composite/Debug/net6.0/linux-x64/output/ -> /runtime-6.0.22/artifacts/packages/Debug/Shipping//dotnet-runtime-internal-composite-6.0.22-linux-x64.tar.gz
/runtime-6.0.22/artifacts/obj/Microsoft.NETCore.App.Runtime.Composite/Debug/net6.0/linux-x64/symbols/ -> /runtime-6.0.22/artifacts/packages/Debug/Shipping//dotnet-runtime-composite-symbols-linux-x64-6.0.22.tar.gz
Successfully created package '/runtime-6.0.22/artifacts/packages/Debug/Shipping/Microsoft.NETCore.App.Composite.6.0.22.nupkg'.
Successfully created package '/runtime-6.0.22/artifacts/packages/Debug/Shipping/Microsoft.NETCore.App.Composite.6.0.22.symbols.nupkg'.
Microsoft.NETCore.App.Composite.Bundle ->
/runtime-6.0.22/artifacts/obj/Microsoft.NETCore.App.Composite.Bundle/Debug/net6.0/linux-x64/output/ -> /runtime-6.0.22/artifacts/packages/Debug/Shipping//dotnet-runtime-composite-6.0.22-linux-x64.tar.gz
Microsoft.NETCore.App.Ref ->
/runtime-6.0.22/artifacts/obj/Microsoft.NETCore.App.Ref/Debug/net6.0/linux-x64/output/ -> /runtime-6.0.22/artifacts/packages/Debug/Shipping//dotnet-targeting-pack-6.0.22-linux-x64.tar.gz
Successfully created package '/runtime-6.0.22/artifacts/packages/Debug/Shipping/Microsoft.NETCore.App.Ref.6.0.22.nupkg'.
Successfully created package '/runtime-6.0.22/artifacts/packages/Debug/Shipping/Microsoft.NETCore.App.Ref.6.0.22.symbols.nupkg'.
Microsoft.NETCore.App.Host ->
/runtime-6.0.22/artifacts/obj/Microsoft.NETCore.App.Host/Debug/net6.0/linux-x64/output/ -> /runtime-6.0.22/artifacts/packages/Debug/Shipping//dotnet-apphost-pack-6.0.22-linux-x64.tar.gz
Successfully created package '/runtime-6.0.22/artifacts/packages/Debug/Shipping/Microsoft.NETCore.App.Host.linux-x64.6.0.22.nupkg'.
Successfully created package '/runtime-6.0.22/artifacts/packages/Debug/Shipping/Microsoft.NETCore.App.Host.linux-x64.6.0.22.symbols.nupkg'.
Microsoft.NETCore.App.Crossgen2 ->
/runtime-6.0.22/artifacts/obj/Microsoft.NETCore.App.Crossgen2/Debug/net6.0/linux-x64/output/ -> /runtime-6.0.22/artifacts/packages/Debug/Shipping//dotnet-crossgen2-6.0.22-linux-x64.tar.gz
Successfully created package '/runtime-6.0.22/artifacts/packages/Debug/Shipping/Microsoft.NETCore.App.Crossgen2.linux-x64.6.0.22.nupkg'.
Successfully created package '/runtime-6.0.22/artifacts/packages/Debug/Shipping/Microsoft.NETCore.App.Crossgen2.linux-x64.6.0.22.symbols.nupkg'.
dotnet-host ->
dotnet-hostfxr ->
/runtime-6.0.22/artifacts/obj/dotnet-hostfxr/Debug/net6.0/linux-x64/output/ -> /runtime-6.0.22/artifacts/packages/Debug/Shipping//dotnet-hostfxr-internal-6.0.22-linux-x64.tar.gz
dotnet-runtime-deps-centos.7 ->
dotnet-runtime-deps-cm.1 ->
dotnet-runtime-deps-cm.2 ->
dotnet-runtime-deps-debian ->
dotnet-runtime-deps-fedora.27 ->
dotnet-runtime-deps-fedora.34 ->
dotnet-runtime-deps-opensuse.42 ->
dotnet-runtime-deps-oraclelinux.7 ->
dotnet-runtime-deps-rhel.7 ->
dotnet-runtime-deps-sles.12 ->
Microsoft.NETCore.App.Runtime ->
/runtime-6.0.22/artifacts/obj/Microsoft.NETCore.App.Runtime/Debug/net6.0/linux-x64/output/ -> /runtime-6.0.22/artifacts/packages/Debug/Shipping//dotnet-runtime-internal-6.0.22-linux-x64.tar.gz
/runtime-6.0.22/artifacts/obj/Microsoft.NETCore.App.Runtime/Debug/net6.0/linux-x64/symbols/ -> /runtime-6.0.22/artifacts/packages/Debug/Shipping//dotnet-runtime-symbols-linux-x64-6.0.22.tar.gz
Successfully created package '/runtime-6.0.22/artifacts/packages/Debug/Shipping/Microsoft.NETCore.App.Runtime.linux-x64.6.0.22.nupkg'.
Successfully created package '/runtime-6.0.22/artifacts/packages/Debug/Shipping/Microsoft.NETCore.App.Runtime.linux-x64.6.0.22.symbols.nupkg'.
Microsoft.NETCore.App.Bundle ->
/runtime-6.0.22/artifacts/obj/Microsoft.NETCore.App.Bundle/Debug/net6.0/linux-x64/output/ -> /runtime-6.0.22/artifacts/packages/Debug/Shipping//dotnet-runtime-6.0.22-linux-x64.tar.gz
Microsoft.NET.HostModel -> /runtime-6.0.22/artifacts/bin/Microsoft.NET.HostModel/Debug/netstandard2.0/Microsoft.NET.HostModel.dll
Successfully created package '/runtime-6.0.22/artifacts/packages/Debug/NonShipping/Microsoft.NET.HostModel.6.0.22-dev.nupkg'.
Successfully created package '/runtime-6.0.22/artifacts/packages/Debug/NonShipping/Microsoft.NET.HostModel.6.0.22-dev.symbols.nupkg'.
TestUtils -> /runtime-6.0.22/artifacts/bin/TestUtils/Debug/net6.0/TestUtils.dll
HostActivation.Tests -> /runtime-6.0.22/artifacts/bin/HostActivation.Tests/Debug/net6.0/HostActivation.Tests.dll
BundleHelper -> /runtime-6.0.22/artifacts/bin/BundleHelper/Debug/net6.0/BundleHelper.dll
Microsoft.NET.HostModel.ComHost.Tests -> /runtime-6.0.22/artifacts/bin/Microsoft.NET.HostModel.ComHost.Tests/Debug/net6.0/Microsoft.NET.HostModel.ComHost.Tests.dll
Microsoft.DotNet.CoreSetup.Packaging.Tests -> /runtime-6.0.22/artifacts/bin/Microsoft.DotNet.CoreSetup.Packaging.Tests/Debug/net6.0/Microsoft.DotNet.CoreSetup.Packaging.Tests.dll
Microsoft.NET.HostModel.AppHost.Tests -> /runtime-6.0.22/artifacts/bin/Microsoft.NET.HostModel.AppHost.Tests/Debug/net6.0/Microsoft.NET.HostModel.AppHost.Tests.dll
AppHost.Bundle.Tests -> /runtime-6.0.22/artifacts/bin/AppHost.Bundle.Tests/Debug/net6.0/AppHost.Bundle.Tests.dll
Microsoft.NET.HostModel.Bundle.Tests -> /runtime-6.0.22/artifacts/bin/Microsoft.NET.HostModel.Bundle.Tests/Debug/net6.0/Microsoft.NET.HostModel.Bundle.Tests.dll
Build succeeded.
0 Warning(s)
0 Error(s)
Time Elapsed 00:29:43.24
开心 安全可控达标,用实际证明jdk可以国内控制编译;dotnet也可以,还是我自己编译可控的,哈哈