Skip to content
This repository has been archived by the owner on Jan 23, 2023. It is now read-only.

Add new rids for Linux ARM32 #712

Merged
merged 1 commit into from
Dec 20, 2016
Merged

Add new rids for Linux ARM32 #712

merged 1 commit into from
Dec 20, 2016

Conversation

hqueue
Copy link
Member

@hqueue hqueue commented Dec 2, 2016

Main issue: #725

Current approach

  • Add two RID for Linux ARM to dotnet-host-build: ubuntu.14.04-arm, ubuntu.16. 04-arm (139d22d, ba91959)
  • Update *.builds and *.pkgproj for corehost nupkgs (4836b7a)
  • Update dotnet-host-build to skip tests for Linux ARM, since it's cross building. (ec9e54f)
  • Build nuget packages for the host and Microsoft.NETCore.App metapackage (4d6e435)
  • Update dotnet-host-build to support when cross crossgen is available (TODO later)

Old approach

I'm trying to build dotnet for rpi3 (ubuntu16.04-arm) and I've added new rid "ubuntu.16.04-arm" to dotnet-host-build as a start point. I will also update CMake rules for corehost.

Is this a right step to enable building dotnet for ARM ?
Looking for an advice and any comment is appreciated.

@dnfclas
Copy link

dnfclas commented Dec 2, 2016

Hi @hqueue, I'm your friendly neighborhood .NET Foundation Pull Request Bot (You can call me DNFBOT). Thanks for your contribution!
You've already signed the contribution license agreement. Thanks!

The agreement was validated by .NET Foundation and real humans are currently evaluating your PR.

TTYL, DNFBOT;

@gkhanna79
Copy link
Member

Making this change involves bunch of pre-reqs:

  1. CoreCLR repo should be able to build and publish nuget packages for Linux Arm, which is being explored in github.com/First step to create nuget packages for ARM32/Linux coreclr#8421.
  2. Once they are published, similar change is required in CoreFX repo as well.
  3. Once both the above are publishing packages, then you can enable Core-Setup for a similar change. To bring this up, have a look at Enable WinArm32 build #526 where I brought up WinArm32 support.

@gkhanna79 gkhanna79 added the * NO MERGE * The PR is not ready for merge yet (see discussion for detailed reasons) label Dec 2, 2016
@hqueue
Copy link
Member Author

hqueue commented Dec 2, 2016

@gkhanna79 Thank you for a quick response :) We will follow steps as you told us.

@hqueue hqueue changed the title [WIP] Add new rid "ubuntu.16.04-arm" [WIP] Add new rid for ARM32 Dec 15, 2016
@hqueue hqueue changed the title [WIP] Add new rid for ARM32 [WIP] Add new rid for Linux ARM32 Dec 15, 2016
@hqueue
Copy link
Member Author

hqueue commented Dec 15, 2016

@gkhanna79 PTAL. There are two missing parts.
(1) We didn't update crossgen related part, since cross crossgen for Linux/ARM32 is not available yet from CoreCLR.
(2) Do we need to update InstallerTargets including Msi ?

@jyoungyun @idkiller @hseok-oh @chunseoklee PTAL

@@ -30,6 +30,8 @@ public class CompileTargets
{ "osx.10.11-x64", "osx.10.10-x64" },
{ "ubuntu.14.04-x64", "ubuntu.14.04-x64" },
{ "ubuntu.16.04-x64", "ubuntu.16.04-x64" },
{ "ubuntu.14.04-arm", "ubuntu.14.04-arm" },
{ "ubuntu.16.04-arm", "ubuntu.16.04-arm" },
{ "ubuntu.16.10-x64", "ubuntu.16.10-x64" },

This comment was marked as spam.

This comment was marked as spam.

@@ -105,7 +105,8 @@ private static List<string> RunDotnetTestOnTestProjects(BuildTargetContext c, Do
bool fIsCrossArch = false;
if (!String.IsNullOrEmpty(rid))
{
if ((String.Compare(rid, "win8-arm", true) == 0) || (String.Compare(rid, "win10-arm64", true) == 0))
if ((String.Compare(rid, "win8-arm", true) == 0) || (String.Compare(rid, "win10-arm64", true) == 0)

This comment was marked as spam.

This comment was marked as spam.

@gkhanna79
Copy link
Member

@hqueue The change looks fine to me.

We didn't update crossgen related part

Can you please add a TODO comment for the same in the code?

Do we need to update InstallerTargets including Msi ?

No, we will produce an archive file for Linux Arm32 that will get listed in the DailyBuilds section in Readme.md.

Have you tried building for Ubuntu 14.04 and 16.04?

@hqueue
Copy link
Member Author

hqueue commented Dec 16, 2016

@gkhanna79 PTAL. I've applied your feedback. Thank you for the feedback :)

I've tested it with ubuntu 14.04 and it seems work as expected, i.e. successfully build nupkgs for corehosts and failed at later passes.
For example, ./build.sh --env-vars TARGETPLATFORM=arm,TARGETRID=ubuntu.14.04-arm,CROSS=1

Please merge this if there is no critical problem, because other developer is also working on the further packaging process.

@hqueue hqueue changed the title [WIP] Add new rid for Linux ARM32 Add new rid for Linux ARM32 Dec 16, 2016
@gkhanna79
Copy link
Member

The change looks good to me but please see my comment at #814 (comment).

@hqueue
Copy link
Member Author

hqueue commented Dec 19, 2016

@gkhanna79 PTAL. We merged PR #814 and this PR here with a new commit written by @jyoungyun.

@hqueue
Copy link
Member Author

hqueue commented Dec 19, 2016

@gkhanna79 @jyoungyun I've rebased with upstream :)

@@ -44,7 +61,10 @@ if [ "$(uname -s)" == "Darwin" ]; then
__targets_param="TargetsOSX=true"
else
__targets_param="TargetsLinux=true"
init_distro_name

This comment was marked as spam.

@hqueue
Copy link
Member Author

hqueue commented Dec 19, 2016

@gkhanna79 We've tested this PR with locally built CoreCLR(ubuntu.14.04-arm) and CoreFX(ubuntu.14.04-arm) and generate tarballs for ubuntu.14.04-arm. What's the next step? One step I think is that we have to publish CoreCLR and CoreFX for ubuntu.14.04-arm to some servers for downloading from core-setup.
How about merging this PR and continue working on remaining pahases in new PRs ?, because other remaining jobs are being discussed in the main issue #725.

cc: @jyoungyun

@gkhanna79
Copy link
Member

@hqueue @jyoungyun The changes LGTM. Can you please rebase the commits to a single one and then I can merge this PR?

One step I think is that we have to publish CoreCLR and CoreFX for ubuntu.14.04-arm to some servers for downloading from core-setup.

This will be done automatically once we enable the support for pipeline build for building Linux Arm32. To do so, we will first need to enable it for CoreCLR, publish the packages and then do the same for CoreFX and finally, Core-setup.

@hqueue
Copy link
Member Author

hqueue commented Dec 20, 2016

@gkhanna79 PTAL. I've squashed commits.

cc: @jyoungyun

Add new rid "ubuntu.16.04-arm"
Signed-off-by: Hyung-Kyu Choi <hk0110.choi@samsung.com>

Add new rid "ubuntu.14.04-arm"
Add new rid "ubuntu.14.04-arm", because CoreCLR and CoreFX
for ARM32 use rid "ubuntu.14.04-arm" as default.
Signed-off-by: Hyung-Kyu Choi <hk0110.choi@samsung.com>

Add ubuntu.14.04-arm and ubuntu.16.04-arm
Add new rids to *.builds and *.pkgproj files
Signed-off-by: Hyung-Kyu Choi <hk0110.choi@samsung.com>

Add Linux ARM32 support in PublishTargets.cs
1. Add version file name for Linux ARM32.
2. Add directory name for Linux ARM32.
Signed-off-by: Hyung-Kyu Choi <hk0110.choi@samsung.com>

Skip host test for Linux ARM32
We skip host test for ubuntu.14.04-arm and ubuntu.16.04-arm
, because we are cross building.
Signed-off-by: Hyung-Kyu Choi <hk0110.choi@samsung.com>

Add ubuntu.14.04-arm instead of ubuntu.16.10-arm
It was typo bug.
Signed-off-by: Hyung-Kyu Choi <hk0110.choi@samsung.com>

Add TODO-ARM-Crossgen comments
Signed-off-by: Hyung-Kyu Choi <hk0110.choi@samsung.com>

Refactoring: Introduce IsCrossArch helper function
Signed-off-by: Hyung-Kyu Choi <hk0110.choi@samsung.com>

Add '--rid' option to pkg/pack.sh on Linux
To support cross build, the pack.sh uses '--rid' option
instead of '/etc/os-release' file.
Signed-off-by: Jiyoung Yun <jy910.yun@samsung.com>
@hqueue hqueue changed the title Add new rid for Linux ARM32 Add new rids for Linux ARM32 Dec 20, 2016
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
* NO MERGE * The PR is not ready for merge yet (see discussion for detailed reasons)
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants