更新时间:2022-01-15 23:05:27
我设法运行了.NET Core在带有Raspbian的Raspberry PI 3上的2个应用程序。
I have managed to run .NET Core 2 app on Raspberry PI 3 with Raspbian.
我遵循了 https://github.com/dotnet/core/blob/master/samples/RaspberryPiInstructions.md 和 https://github.com/dotnet/core/issues/447 :
在我的笔记本电脑上:
运行
mkdir helloworld
cd helloworld
dotnet new console
编辑 helloworld.csproj
<Project Sdk="Microsoft.NET.Sdk">
<PropertyGroup>
<OutputType>Exe</OutputType>
<TargetFramework>netcoreapp2.0</TargetFramework>
<RuntimeIdentifiers>win-arm;linux-arm</RuntimeIdentifiers>
</PropertyGroup>
</Project>
运行
dotnet publish -r linux-arm
:
运行 sudo apt-get install libc6 libcurl3 libgcc1 libgssapi-krb5-2 libicu52 liblttng-ust0 libssl1.0.0 libstdc ++ 6 libunwind8 libuuid1 zlib1g
然后复制。/bin / Debug / netcoreapp2.0 / linux-arm / publish
从我的笔记本电脑上
Then copy ./bin/Debug/netcoreapp2.0/linux-arm/publish
from my laptop
[ helloworld
的修改权限
运行 ./ helloworld