plk/biber

Provide build version for linux_aarch64

Closed this issue · 8 comments

I would like to help provide a linux_aarch64 build version of biber for the latest release 2.18.
I already built it (as I needed it myself) and would like to provide it back, however, I would ask for some guidence.

The build process uses one of the official Docker images for Perl, https://hub.docker.com/_/perl, version 5.36.0 (on top of Debian Buster).
Following the instruction of the documentation, I adopted the linux_aarch64-musl build script and run it in Docker and tested the binary on a seperate machine with the two testfiles test.{bib,bcf}.

I'm a bit puzzled with the upload process on CTAN as a biber-linux package already exists (obviously).
What would be the best next step? Does it make sense, at all?
For example, also adding other ARM versions (armhf; armel has already a build script).

plk commented

Greetings, and thank you for the offer. I'll gladly accept any offers to provide builds for platforms that don't have one yet. In the first instance, please see here, which should give you all the information you need about CTAN and the build/release process but feel free to ask for clarification here as the process is relatively new.

https://github.com/plk/biber/blob/dev/BUILDERS.README

Simon,

I provide the linux-musl_x86_64 build. See also https://github.com/krumeich/biber-alpine. If you're interested in an exchange of experiences with building biber in Docker for the linux-musl metaplatform, get in touch.

Hi together,

thanks for the nice answers, and the offer from @krumeich.

A quick write up how I built the aarch64 executable using Docker, Perl 5.36.0, and Debian Buster (to have an old enough glibc to handle a broader spectrum of OS):

   docker run -it --rm -v "$PWD":/usr/src/biber -w /usr/src/biber perl:5.36.0-buster /bin/bash

Next, I prepare the build and build biber (c.f. my pull request for the build script):

  cpan Module::Build PAR::Packer CPAN::DistnameInfo &&
         # We need to force the installation, else we will not have all files correctly in their respective places.
         cpan -f Unicode::Collate::Locale && \
     perl Build installdeps && \
         # Needs be run *after* installdeps
     echo "/usr/local/lib" > /etc/ld.so.conf.d/biber.conf && ldconfig && \
     perl Build test && \
     perl Build install && \
     cd dist/linux_aarch64 && bash ./build.sh

I run the test from BUILDERS.README on an EC2 instance with Ubuntu 20.04 / Focal and on a Raspberry 4 with Debian Buster.

Next, I would orientate myself at Alexander's repository and prepare the whole build process in it.

This looks good, Simon! When you look at my Dockerfile you'll see that I prepare the build environment with all its Perl modules beforehand and pack it into an image. This saves a lot of time (ca. 15-20 minutes per build), because only the actual biber compile is done in the container.

Hey, @sbrass, any progress on the arm64 build? Do you need a hand?

Thanks @krumeich for remembering me!
I've already started to adapt your Docker setup in late September, but got stuck somewhere in-between.

Let me put everything together once, and see what went wrong.

Hey everybody,

I replicated the setup from @krumeich to provide a consistent build environment, c.f. https://github.com/sbrass/biber-linux-aarch64.
You can find a compressed archive under https://nextcloud.phibra.de/s/RqZQxZe9nojitiQ for inspection.

If everything seems correct, I would upload it to ctan.
Cheers!

Excellent, Simon! I'm very glad that I can finally get my linux-aarch64 based Docker image to work. This was the only missing piece.

BTW, now that you are the second person on the planet to use this build workflow: if you have any suggestions on improvement, do let me know.