Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update to v2.9 #21

Closed
luxas opened this issue Apr 28, 2017 · 8 comments
Closed

Update to v2.9 #21

luxas opened this issue Apr 28, 2017 · 8 comments

Comments

@luxas
Copy link

luxas commented Apr 28, 2017

Hi, I'm a big fan of your QEMU builds, thank you!

Now that v2.9.0 was released this week, would you mind upgrading to the latest version?
Cheers!

@lafin
Copy link
Contributor

lafin commented Apr 29, 2017

Sure, we are waiting update a deb packages http://ftp.debian.org/debian/pool/main/q/qemu/.

@hurricanehrndz
Copy link

hurricanehrndz commented May 14, 2017

@lafin, how about instead of debs, the rpms from openSUSE Tumbleweed are used. The rpm can be extracted using rpm2cpio. The builds are static anyhow so any package from any distro should do.

@moul
Copy link
Member

moul commented May 14, 2017 via email

@hurricanehrndz
Copy link

Here is my container that was inspired by yours:
https://github.com/MediaBrowser/Emby.Build/tree/master/docker-containers/qemu-builder/register

You might also want to checkout this code that I use in my make files

 repo := http://download.opensuse.org/tumbleweed/repo/oss/suse/x86_64
      $(eval rpm_name := $(shell curl -s $(repo)/ --list-only | grep qemu-linux | sed -n s%".*>\(qemu-linux-.*rpm\)</a>.*"%"\1"%p | tail -1))
    curl -L $(repo)/$(rpm_name) -o /var/tmp/$(IMG_NAME)_$(ARCH)/qemu-linux-user.rpm
    @ if [[ $(ARCH) ==  "armv7l" ]]; then \
        rpm2cpio /var/tmp/$(IMG_NAME)_$(ARCH)/qemu-linux-user.rpm | cpio -D /var/tmp/$(IMG_NAME)_$(ARCH)/ -idmv "*qemu-arm" "*qemu-arm-*"; \
      fi
    @ if [[ $(ARCH) ==  "aarch64" ]]; then \
        rpm2cpio /var/tmp/$(IMG_NAME)_$(ARCH)/qemu-linux-user.rpm | cpio -D /var/tmp/$(IMG_NAME)_$(ARCH)/ -idmv "*qemu-aarch*"; \
      fi
    sed -i '/ENV/,/RUN/ {s/^$$/COPY usr \/usr/}' /var/tmp/$(IMG_NAME)_$(ARCH)/Dockerfile
    @ if [[ ! -e /proc/sys/fs/binfmt_misc/arm || ! -e /proc/sys/fs/binfmt_misc/aarch64 ]]; then \
        docker run --rm --privileged emby/qemu-builder:register; \
      fi

Hopefully the above give you enough code to proceed

@hurricanehrndz
Copy link

Sorry just noticed it was still on 2.8, it is rolling release so it might be a bit faster at updating.

@lafin lafin closed this as completed May 21, 2017
@luxas
Copy link
Author

luxas commented May 29, 2017

Thanks @lafin 👍

@frivoire
Copy link

frivoire commented Jun 6, 2017

Hello,

It seems that this update to 2.9.0 can cause some issues :
==> those new builds aren't static anymore

Here is what I've tested:

flo@flopc:~$ wget -q https://github.com/multiarch/qemu-user-static/releases/download/v2.8.4/qemu-aarch64-static -O - |file -
/dev/stdin: ELF 64-bit LSB executable, x86-64, version 1 (GNU/Linux), statically linked, for GNU/Linux 2.6.32, BuildID[sha1]=91fb924228a0814f7ae7d13947cb1f13c02fa36f, stripped
flo@flopc:~$ wget -q https://github.com/multiarch/qemu-user-static/releases/download/v2.9.0/qemu-aarch64 -O - |file -
/dev/stdin: ELF 64-bit LSB shared object, x86-64, version 1 (GNU/Linux), dynamically linked, interpreter /lib64/ld-linux-x86-64.so.2, for GNU/Linux 2.6.32, BuildID[sha1]=48894fc6b031f7dfecf8ac90b6f420dd8d94b34f, stripped

And in https://github.com/multiarch/qemu-user-static/releases/tag/v2.9.0, several files are named "-static" but are not :

  • qemu-aarch64-static.tar.gz
  • x86_64_qemu-aarch64-static.tar.gz

Those 2 contain the same binary than qemu-aarch64 (tested above).

The change (static -> dynamic) seems to come from this commit:
6226ce5

I believe that this repo should still provide static builds (as it did until 2.8.4).
For now, can we stick to debian (even if still on 2.8) ? Or try to use builds from another distrib (as suggested by hurricanehrndz) ?

Thanks !

@superseed
Copy link

superseed commented Jun 6, 2017

It also seems that on Arch, the only static version of qemu-user is in the AUR.

Fedora does have a 2.9 version of qemu-user-static:

$ wget https://kojipkgs.fedoraproject.org//packages/qemu/2.9.0/1.fc27/x86_64/qemu-user-static-2.9.0-1.fc27.x86_64.rpm
--2017-06-06 11:28:34--  https://kojipkgs.fedoraproject.org//packages/qemu/2.9.0/1.fc27/x86_64/qemu-user-static-2.9.0-1.fc27.x86_64.rpm
Resolving kojipkgs.fedoraproject.org... 209.132.181.16, 209.132.181.15
Connecting to kojipkgs.fedoraproject.org|209.132.181.16|:443... connected.
HTTP request sent, awaiting response... 200 OK
Length: 33586054 (32M) [application/x-rpm]
Saving to: ‘qemu-user-static-2.9.0-1.fc27.x86_64.rpm’

qemu-user-static-2.9.0-1.fc27.x86_64.rpm      100%[==============================================================================================>]  32.03M  6.16MB/s    in 14s

2017-06-06 11:28:49 (2.27 MB/s) - ‘qemu-user-static-2.9.0-1.fc27.x86_64.rpm’ saved [33586054/33586054]

$ rpm2cpio qemu-user-static-2.9.0-1.fc27.x86_64.rpm | cpio -dimv
[------ snip ✂ ------]

$ file usr/bin/qemu-aarch64-static
usr/bin/qemu-aarch64-static: ELF 64-bit LSB executable, x86-64, version 1 (GNU/Linux), statically linked, for GNU/Linux 2.6.32, BuildID[sha1]=aea83dc036f4efaa10d104bbdebdcd4a4be33987, stripped

This is for rawhide but apparently f26 also has it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

6 participants