libgit2 / libgit2sharp.nativebinaries

MIT License
28 stars 62 forks source link

Add linux-arm64 RID builds #99

Closed omajid closed 4 years ago

omajid commented 5 years ago

The normal approach is to take the oldest OS supported and use that to make linux-$ARCH RID packages. Here, we use ubuntu 16.04.

This commit makes the following changes:

Add a new dockerfile for linux-arm64, which is actually just a copy of Dockerfile.ubuntu.16.04-arm64. This is so we can build linux-arm64 RID packages in CI.

Add a dllmap for mapping from armv8 (which is what mono calls arm64/aarch64 - see https://www.mono-project.com/docs/advanced/pinvoke/dllmap/) to the linux-arm64 RID.

Also fix build.libgit2.sh to handle building natively on arm64. I used this to build libgit2, using ./build.libgit2.sh, on RHEL 8 on arm64.

omajid commented 5 years ago

Some open questions:

  1. Is there a way I can verify the built libgit2 works end-to-end?

  2. What is the process of getting this released?

  3. Once CI systmes (eg https://github.com/Microsoft/azure-pipelines-agent/issues/1521#issuecomment-424466976) start supporting arm64, maybe we might want to do native builds on arm64 instead of cross compilation?

omajid commented 4 years ago

Closing because https://github.com/libgit2/libgit2sharp/pull/1714 does it much better.