.NET 7이 이제 Linux on Power (ppc64le)에서도 지원됩니다. 즉 ppc64le 아키텍처의 Power 서버에서는 C# 언어도 지원하게 되었습니다. 이로써 microservices app 개발에 사용되는 5개 프로그래밍 언어가 모두 ppc64le에서 지원됩니다.
2021년 Stack Overflow에서의 개발자 설문에 따르면 .NET framework은 전업 개발자들에게 있어서 가장 중요한 프레임웍 및 라이브러리입니다.
관련 발표는 아래 URL에서 좀 더 자세히 보실 수 있습니다.
또한 .NET 7 ppc64le는 이미 고객 reference가 있습니다. 독일의 컴퓨터 설계 관련 기업인 SKM Informatik GmbH인데, 이 기업의 요청으로 .NET 7의 ppc64le 지원이 시작되었다고 합니다.
https://www.ibm.com/downloads/cas/29RYARBY
.NET 7은 github에 그 source code가 공개되니 직접 build 하셔도 됩니다만, .NET 7 for ppc64le는 Openshift container 이미지로 제공되고 또 RHEL 8.7 또는 RHEL 9.1에서 YUM repository를 통해서도 제공됩니다.
.NET 7 관련된 패키지들은 yum 명령어를 통해 패키지로 아래 예와 같이 설치하실 수 있습니다.
[cecuser@p1274-pvm1 ~]$ hostnamectl
Static hostname: p1274-pvm1
Icon name: computer-vm
Chassis: vm
Machine ID: e5e70adcd98c4b56b00cc49cbf093412
Boot ID: 36e5448112b5432c91f40abe413cb05a
Virtualization: powervm
Operating System: Red Hat Enterprise Linux 8.7 (Ootpa)
CPE OS Name: cpe:/o:redhat:enterprise_linux:8::baseos
Kernel: Linux 4.18.0-372.9.1.el8.ppc64le
Architecture: ppc64-le
[cecuser@p1274-pvm1 ~]$ yum list | grep dotnet
dotnet.ppc64le 7.0.100-1.el8_7 rhel-8-for-ppc64le-appstream-rpms
dotnet-apphost-pack-7.0.ppc64le 7.0.0-1.el8_7 rhel-8-for-ppc64le-appstream-rpms
dotnet-host.ppc64le 7.0.0-1.el8_7 rhel-8-for-ppc64le-appstream-rpms
dotnet-hostfxr-7.0.ppc64le 7.0.0-1.el8_7 rhel-8-for-ppc64le-appstream-rpms
dotnet-runtime-7.0.ppc64le 7.0.0-1.el8_7 rhel-8-for-ppc64le-appstream-rpms
dotnet-sdk-7.0.ppc64le 7.0.100-1.el8_7 rhel-8-for-ppc64le-appstream-rpms
dotnet-sdk-7.0-source-built-artifacts.ppc64le 7.0.100-1.el8_7 codeready-builder-for-rhel-8-ppc64le-rpms
dotnet-targeting-pack-7.0.ppc64le 7.0.0-1.el8_7 rhel-8-for-ppc64le-appstream-rpms
dotnet-templates-7.0.ppc64le 7.0.100-1.el8_7 rhel-8-for-ppc64le-appstream-rpms
[cecuser@p1274-pvm1 ~]$ sudo yum install dotnet-sdk-7.0
Updating Subscription Management repositories.
Last metadata expiration check: 23:10:11 ago on Tue 06 Dec 2022 03:10:01 AM EST.
Dependencies resolved.
===================================================================================================
Package Arch Version Repository Size
===================================================================================================
Installing:
dotnet-sdk-7.0 ppc64le 7.0.100-1.el8_7 rhel-8-for-ppc64le-appstream-rpms 53 M
Installing dependencies:
aspnetcore-runtime-7.0 ppc64le 7.0.0-1.el8_7 rhel-8-for-ppc64le-appstream-rpms 2.8 M
aspnetcore-targeting-pack-7.0 ppc64le 7.0.0-1.el8_7 rhel-8-for-ppc64le-appstream-rpms 1.6 M
dotnet-apphost-pack-7.0 ppc64le 7.0.0-1.el8_7 rhel-8-for-ppc64le-appstream-rpms 100 k
dotnet-host ppc64le 7.0.0-1.el8_7 rhel-8-for-ppc64le-appstream-rpms 190 k
dotnet-hostfxr-7.0 ppc64le 7.0.0-1.el8_7 rhel-8-for-ppc64le-appstream-rpms 175 k
dotnet-runtime-7.0 ppc64le 7.0.0-1.el8_7 rhel-8-for-ppc64le-appstream-rpms 7.8 M
dotnet-targeting-pack-7.0 ppc64le 7.0.0-1.el8_7 rhel-8-for-ppc64le-appstream-rpms 2.9 M
dotnet-templates-7.0 ppc64le 7.0.100-1.el8_7 rhel-8-for-ppc64le-appstream-rpms 3.1 M
netstandard-targeting-pack-2.1 ppc64le 7.0.100-1.el8_7 rhel-8-for-ppc64le-appstream-rpms 1.5 M
Transaction Summary
===================================================================================================
Install 10 Packages
Total download size: 73 M
Installed size: 311 M
Is this ok [y/N]: y
...
Installed:
aspnetcore-runtime-7.0-7.0.0-1.el8_7.ppc64le
aspnetcore-targeting-pack-7.0-7.0.0-1.el8_7.ppc64le
dotnet-apphost-pack-7.0-7.0.0-1.el8_7.ppc64le
dotnet-host-7.0.0-1.el8_7.ppc64le
dotnet-hostfxr-7.0-7.0.0-1.el8_7.ppc64le
dotnet-runtime-7.0-7.0.0-1.el8_7.ppc64le
dotnet-sdk-7.0-7.0.100-1.el8_7.ppc64le
dotnet-targeting-pack-7.0-7.0.0-1.el8_7.ppc64le
dotnet-templates-7.0-7.0.100-1.el8_7.ppc64le
netstandard-targeting-pack-2.1-7.0.100-1.el8_7.ppc64le
Complete!
설치는 위와 같이 매우 간단합니다. 이제 "Hello, World!"를 프린트하는 샘플 프로그램을 돌려보도록 하겠습니다.
[cecuser@p1274-pvm1 ~]$ dotnet
Usage: dotnet [options]
Usage: dotnet [path-to-application]
Options:
-h|--help Display help.
--info Display .NET information.
--list-sdks Display the installed SDKs.
--list-runtimes Display the installed runtimes.
path-to-application:
The path to an application .dll file to execute.
[cecuser@p1274-pvm1 ~]$ dotnet new console -o MyApp -f net7.0
Welcome to .NET 7.0!
---------------------
SDK Version: 7.0.100
----------------
Installed an ASP.NET Core HTTPS development certificate.
To trust the certificate run 'dotnet dev-certs https --trust' (Windows and macOS only).
Learn about HTTPS: https://aka.ms/dotnet-https
----------------
Write your first app: https://aka.ms/dotnet-hello-world
Find out what's new: https://aka.ms/dotnet-whats-new
Explore documentation: https://aka.ms/dotnet-docs
Report issues and find source on GitHub: https://github.com/dotnet/core
Use 'dotnet --help' to see available commands or visit: https://aka.ms/dotnet-cli
--------------------------------------------------------------------------------------
The template "Console App" was created successfully.
Processing post-creation actions...
Restoring /home/cecuser/MyApp/MyApp.csproj:
Determining projects to restore...
Restored /home/cecuser/MyApp/MyApp.csproj (in 200 ms).
Restore succeeded.
[cecuser@p1274-pvm1 ~]$ cd MyApp
[cecuser@p1274-pvm1 MyApp]$ ls -la
total 12
drwxrwxr-x. 3 cecuser cecuser 55 Dec 7 02:24 .
drwx------. 23 cecuser cecuser 4096 Dec 7 02:24 ..
-rw-rw-r--. 1 cecuser cecuser 239 Dec 7 02:24 MyApp.csproj
drwxrwxr-x. 2 cecuser cecuser 168 Dec 7 02:24 obj
-rw-rw-r--. 1 cecuser cecuser 103 Dec 7 02:24 Program.cs
[cecuser@p1274-pvm1 MyApp]$ cat Program.cs
// See https://aka.ms/new-console-template for more information
Console.WriteLine("Hello, World!");
[cecuser@p1274-pvm1 MyApp]$ dotnet run
Hello, World!
[cecuser@p1274-pvm1 MyApp]$ ls -ltr
total 8
-rw-rw-r--. 1 cecuser cecuser 239 Dec 7 02:24 MyApp.csproj
-rw-rw-r--. 1 cecuser cecuser 103 Dec 7 02:24 Program.cs
drwxrwxr-x. 3 cecuser cecuser 181 Dec 7 02:26 obj
drwxrwxr-x. 3 cecuser cecuser 19 Dec 7 02:26 bin
[cecuser@p1274-pvm1 MyApp]$ ls -ltr bin/Debug/net7.0
total 168
-rw-rw-r--. 1 cecuser cecuser 10828 Dec 7 02:26 MyApp.pdb
-rw-rw-r--. 1 cecuser cecuser 4608 Dec 7 02:26 MyApp.dll
-rwxr-xr-x. 1 cecuser cecuser 139488 Dec 7 02:26 MyApp
-rw-rw-r--. 1 cecuser cecuser 385 Dec 7 02:26 MyApp.deps.json
-rw-rw-r--. 1 cecuser cecuser 139 Dec 7 02:26 MyApp.runtimeconfig.json
[cecuser@p1274-pvm1 MyApp]$ ./bin/Debug/net7.0/MyApp
Hello, World!
다만 아래의 MS 홈페이지의 .NET download 사이트에서는 ppc64le 관련 패키지는 별도로 제공되지 않네요.
https://devblogs.microsoft.com/dotnet/announcing-dotnet-7/