diff options
author | Anes Belfodil | 2019-12-04 11:51:39 -0500 |
---|---|---|
committer | Anes Belfodil | 2019-12-04 11:51:39 -0500 |
commit | 15521614aa74ae78bc22740b179698aa765a49b0 (patch) | |
tree | bb5a392c025f7e1bab5775b38546d55e687eeb11 | |
parent | 33a86b6e0cd6a1368e278218cf6bcb549aef1925 (diff) | |
download | aur-15521614aa74ae78bc22740b179698aa765a49b0.tar.gz |
Delegate binfmt responsibility to binfmt-qemu-static package
-rw-r--r-- | .SRCINFO | 6 | ||||
-rw-r--r-- | PKGBUILD | 78 | ||||
-rw-r--r-- | qemu.binfmt | 24 |
3 files changed, 7 insertions, 101 deletions
@@ -1,22 +1,20 @@ pkgbase = qemu-user-static-bin pkgdesc = A generic and open source machine emulator, statically linked pkgver = 4.1 - pkgrel = 1 + pkgrel = 2 url = http://wiki.qemu.org arch = x86_64 arch = i686 arch = aarch64 license = GPL2 license = LGPL2.1 - makedepends = perl + depends = binfmt-qemu-static provides = qemu-user-static provides = qemu-user conflicts = qemu-user-static conflicts = qemu-user source = qemu-user-static_4.1-1+b4_amd64.deb::http://ftp.debian.org/debian/pool/main/q/qemu/qemu-user-static_4.1-1+b4_amd64.deb - source = qemu.binfmt sha256sums = 2015a082c6cc474b258638ebd6877dad9f96667d0cd88440b47e7d30a34370a9 - sha256sums = 0c1e998022f3306946cd66678f363b10d93b1309c5bbc9f0e6064080a3b604f9 pkgname = qemu-user-static-bin @@ -2,14 +2,14 @@ _pkgname=qemu-user-static pkgdesc='A generic and open source machine emulator, statically linked' pkgver=4.1 pkgadditver=1+b4 -pkgrel=1 +pkgrel=2 pkgname=$_pkgname-bin arch=('x86_64' 'i686' 'aarch64') url="http://wiki.qemu.org" license=('GPL2' 'LGPL2.1') -depends=() -makedepends=('perl') +depends=('binfmt-qemu-static') +makedepends=() provides=("$_pkgname" "qemu-user") conflicts=("$_pkgname" "qemu-user") @@ -30,11 +30,9 @@ fi source=( "$_debsrc::http://ftp.debian.org/debian/pool/main/q/qemu/$_debsrc" - "qemu.binfmt" # http://src.fedoraproject.org/rpms/qemu/raw/master/f/qemu.binfmt ) sha256sums=( "$_csum" - '0c1e998022f3306946cd66678f363b10d93b1309c5bbc9f0e6064080a3b604f9' ) prepare() { @@ -45,80 +43,14 @@ prepare() { build() { cd build tar -xJf ../data.tar.xz -C . - create_binfmts } package() { cd build mkdir -p "$pkgdir"/usr/bin/ - mkdir -p "$pkgdir"/usr/share/man/man1 - mkdir -p "$pkgdir"/usr/lib/binfmt.d - cp usr/bin/qemu-*-static "$pkgdir"/usr/bin/ - cp usr/lib/binfmt.d/qemu-*-static.conf "$pkgdir"/usr/lib/binfmt.d/ - cp usr/share/man/man1/qemu-*-static.1.gz "$pkgdir"/usr/share/man/man1/ -} - -create_binfmts() { - rm -Rf usr/lib/binfmt.d - mkdir -p usr/lib/binfmt.d - - # Qemu upstream now has a script to create the binfmt - # configurations, in ./scripts/qemu-binfmt-conf.sh. We - # should switch to it, rather than parsing the old - # Fedora configuration manually. - for i in \ - aarch64 \ - alpha \ - armeb \ - arm \ - cris \ - i386 \ - i486 \ - m68k \ - microblazeel \ - microblaze \ - mips64el \ - mips64 \ - mipsel \ - mips \ - ppc64abi32 \ - ppc64le \ - ppc64 \ - ppc \ - s390x \ - sh4eb \ - sh4 \ - sparc32plus \ - sparc64 \ - sparc \ - x86_64; do - - # Skip emulator of target machine (and dependents) - if [ "$CARCH" = "$i" ]; then - continue - elif [ "$CARCH" = "x86_64" ]; then - if [ "$i" = "i386" ] || - [ "$i" = "i486" ] || - [ "$i" = "x86_64" ]; then - continue - fi - elif [ "$CARCH" = "i686" ]; then - if [ "$i" = "i386" ] || - [ "$i" = "i486" ]; then - continue - fi - fi - - CFG=$(grep "^:qemu-$i:" "${srcdir}/qemu.binfmt" | tr -d '\n') - if [ -z "$CFG" ]; then - continue - fi - - echo -E -n "$CFG" >"usr/lib/binfmt.d/qemu-$i-static.conf" - perl -i -p -e "s/bin\/qemu-([^:]+):\$/bin\/qemu-\1-static:F/" \ - "usr/lib/binfmt.d/qemu-$i-static.conf" - done + mkdir -p "$pkgdir"/usr/share/man/man1 + cp usr/share/man/man1/qemu-*-static.1.gz "$pkgdir"/usr/share/man/man1/ } diff --git a/qemu.binfmt b/qemu.binfmt deleted file mode 100644 index 36b380f7792d..000000000000 --- a/qemu.binfmt +++ /dev/null @@ -1,24 +0,0 @@ -:qemu-aarch64:M::\x7fELF\x02\x01\x01\x00\x00\x00\x00\x00\x00\x00\x00\x00\x02\x00\xb7\x00:\xff\xff\xff\xff\xff\xff\xff\x00\x00\x00\x00\x00\x00\x00\x00\x00\xfe\xff\xff\xff:/usr/bin/qemu-aarch64: -:qemu-alpha:M::\x7fELF\x02\x01\x01\x00\x00\x00\x00\x00\x00\x00\x00\x00\x02\x00\x26\x90:\xff\xff\xff\xff\xff\xff\xff\x00\x00\x00\x00\x00\x00\x00\x00\x00\xfe\xff\xff\xff:/usr/bin/qemu-alpha: -:qemu-armeb:M::\x7fELF\x01\x02\x01\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x02\x00\x28:\xff\xff\xff\xff\xff\xff\xff\x00\x00\x00\x00\x00\x00\x00\x00\x00\xff\xfe\xff\xff:/usr/bin/qemu-armeb: -:qemu-arm:M::\x7fELF\x01\x01\x01\x00\x00\x00\x00\x00\x00\x00\x00\x00\x02\x00\x28\x00:\xff\xff\xff\xff\xff\xff\xff\x00\x00\x00\x00\x00\x00\x00\x00\x00\xfe\xff\xff\xff:/usr/bin/qemu-arm: -:qemu-cris:M::\x7fELF\x01\x01\x01\x00\x00\x00\x00\x00\x00\x00\x00\x00\x02\x00\x4c\x00:\xff\xff\xff\xff\xff\xff\xff\x00\x00\x00\x00\x00\x00\x00\x00\x00\xfe\xff\xff\xff:/usr/bin/qemu-cris: -:qemu-i386:M::\x7fELF\x01\x01\x01\x00\x00\x00\x00\x00\x00\x00\x00\x00\x02\x00\x03\x00:\xff\xff\xff\xff\xff\xff\xff\x00\x00\x00\x00\x00\x00\x00\x00\x00\xfe\xff\xff\xff:/usr/bin/qemu-i386: -:qemu-i486:M::\x7fELF\x01\x01\x01\x00\x00\x00\x00\x00\x00\x00\x00\x00\x02\x00\x06\x00:\xff\xff\xff\xff\xff\xff\xff\x00\x00\x00\x00\x00\x00\x00\x00\x00\xfe\xff\xff\xff:/usr/bin/qemu-i386: -:qemu-m68k:M::\x7fELF\x01\x02\x01\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x02\x00\x04:\xff\xff\xff\xff\xff\xff\xff\x00\x00\x00\x00\x00\x00\x00\x00\x00\xff\xfe\xff\xff:/usr/bin/qemu-m68k: -:qemu-microblazeel:M::\x7fELF\x01\x01\x01\x00\x00\x00\x00\x00\x00\x00\x00\x00\x02\x00\xab\xba:\xff\xff\xff\xff\xff\xff\xff\x00\x00\x00\x00\x00\x00\x00\x00\x00\xfe\xff\xff\xff:/usr/bin/qemu-microblazeel: -:qemu-microblaze:M::\x7fELF\x01\x02\x01\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x02\xba\xab:\xff\xff\xff\xff\xff\xff\xff\x00\x00\x00\x00\x00\x00\x00\x00\x00\xff\xfe\xff\xff:/usr/bin/qemu-microblaze: -:qemu-mips64el:M::\x7fELF\x02\x01\x01\x00\x00\x00\x00\x00\x00\x00\x00\x00\x02\x00\x08\x00:\xff\xff\xff\xff\xff\xff\xff\x00\x00\x00\x00\x00\x00\x00\x00\x00\xfe\xff\xff\xff:/usr/bin/qemu-mips64el: -:qemu-mips64:M::\x7fELF\x02\x02\x01\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x02\x00\x08:\xff\xff\xff\xff\xff\xff\xff\x00\x00\x00\x00\x00\x00\x00\x00\x00\xff\xfe\xff\xff:/usr/bin/qemu-mips64: -:qemu-mipsel:M::\x7fELF\x01\x01\x01\x00\x00\x00\x00\x00\x00\x00\x00\x00\x02\x00\x08\x00:\xff\xff\xff\xff\xff\xff\xff\x00\x00\x00\x00\x00\x00\x00\x00\x00\xfe\xff\xff\xff:/usr/bin/qemu-mipsel: -:qemu-mips:M::\x7fELF\x01\x02\x01\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x02\x00\x08:\xff\xff\xff\xff\xff\xff\xff\x00\x00\x00\x00\x00\x00\x00\x00\x00\xff\xfe\xff\xff:/usr/bin/qemu-mips: -:qemu-ppc64abi32:M::\x7fELF\x01\x02\x01\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x02\x00\x15:\xff\xff\xff\xff\xff\xff\xff\x00\x00\x00\x00\x00\x00\x00\x00\x00\xff\xfe\xff\xff:/usr/bin/qemu-ppc64abi32: -:qemu-ppc64le:M::\x7fELF\x02\x01\x01\x00\x00\x00\x00\x00\x00\x00\x00\x00\x02\x00\x15\x00:\xff\xff\xff\xff\xff\xff\xff\x00\x00\x00\x00\x00\x00\x00\x00\x00\xfe\xff\xff\xff:/usr/bin/qemu-ppc64le: -:qemu-ppc64:M::\x7fELF\x02\x02\x01\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x02\x00\x15:\xff\xff\xff\xff\xff\xff\xff\x00\x00\x00\x00\x00\x00\x00\x00\x00\xff\xfe\xff\xff:/usr/bin/qemu-ppc64: -:qemu-ppc:M::\x7fELF\x01\x02\x01\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x02\x00\x14:\xff\xff\xff\xff\xff\xff\xff\x00\x00\x00\x00\x00\x00\x00\x00\x00\xff\xfe\xff\xff:/usr/bin/qemu-ppc: -:qemu-s390x:M::\x7fELF\x02\x02\x01\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x02\x00\x16:\xff\xff\xff\xff\xff\xff\xff\x00\x00\x00\x00\x00\x00\x00\x00\x00\xff\xfe\xff\xff:/usr/bin/qemu-s390x: -:qemu-sh4eb:M::\x7fELF\x01\x02\x01\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x02\x00\x2a:\xff\xff\xff\xff\xff\xff\xff\x00\x00\x00\x00\x00\x00\x00\x00\x00\xff\xfe\xff\xff:/usr/bin/qemu-sh4eb: -:qemu-sh4:M::\x7fELF\x01\x01\x01\x00\x00\x00\x00\x00\x00\x00\x00\x00\x02\x00\x2a\x00:\xff\xff\xff\xff\xff\xff\xff\x00\x00\x00\x00\x00\x00\x00\x00\x00\xfe\xff\xff\xff:/usr/bin/qemu-sh4: -:qemu-sparc32plus:M::\x7fELF\x01\x02\x01\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x02\x00\x12:\xff\xff\xff\xff\xff\xff\xff\x00\x00\x00\x00\x00\x00\x00\x00\x00\xff\xfe\xff\xff:/usr/bin/qemu-sparc32plus: -:qemu-sparc64:M::\x7fELF\x02\x02\x01\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x02\x00\x2b:\xff\xff\xff\xff\xff\xff\xff\x00\x00\x00\x00\x00\x00\x00\x00\x00\xff\xfe\xff\xff:/usr/bin/qemu-sparc64: -:qemu-sparc:M::\x7fELF\x01\x02\x01\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x02\x00\x02:\xff\xff\xff\xff\xff\xff\xff\x00\x00\x00\x00\x00\x00\x00\x00\x00\xff\xfe\xff\xff:/usr/bin/qemu-sparc: |