wok-6.x annotate qemu/receipt @ rev 24500
Add some current_version
author | Pascal Bellard <pascal.bellard@slitaz.org> |
---|---|
date | Sat Feb 19 19:01:32 2022 +0000 (2022-02-19) |
parents | e919c5a2742d |
children | 8acc87b18a99 |
rev | line source |
---|---|
pascal@438 | 1 # SliTaz package receipt. |
pascal@438 | 2 |
pascal@438 | 3 PACKAGE="qemu" |
pascal@17629 | 4 VERSION="2.0.2" |
pascal@438 | 5 CATEGORY="misc" |
pascal@438 | 6 SHORT_DESC="General-purpose full virtualizer for x86 hardware." |
pascal@438 | 7 MAINTAINER="pascal.bellard@slitaz.org" |
pascal@15002 | 8 LICENSE="GPL2" |
pankso@13346 | 9 TARBALL="$PACKAGE-$VERSION.tar.bz2" |
pankso@12978 | 10 WEB_SITE="http://qemu.org" |
pankso@12978 | 11 WGET_URL="http://wiki.qemu.org/download/$TARBALL" |
pascal@23938 | 12 UEFIZIP="OVMF-IA32-r15214.zip OVMF-X64-r15214.zip" |
pascal@19446 | 13 EXTRA_SOURCE_FILES="$UEFIZIP" |
pascal@14528 | 14 TAGS="virtualization emulator" |
pascal@438 | 15 |
pascal@18000 | 16 DEPENDS="alsa-lib gnutls libsdl bluez libtasn1 libsasl vde2 libcurl ncurses \ |
pascal@23680 | 17 attr util-linux-uuid libgio glib libusb zlib liblzma" |
pankso@10623 | 18 BUILD_DEPENDS="gettext perl alsa-lib-dev gnutls-dev libsdl-dev bluez-dev \ |
pascal@15643 | 19 libtasn1-dev vde2-dev curl-dev attr-dev util-linux-uuid-dev libgio-dev \ |
pascal@23680 | 20 glib-dev autoconf automake libtool bison flex libusb-dev ncurses-dev xz-dev file" |
pankso@10623 | 21 |
pascal@24348 | 22 # What is the latest version available today? |
pascal@24348 | 23 current_version() |
pascal@24348 | 24 { |
pascal@24384 | 25 wget -O - $WEB_SITE 2>/dev/null | sed '/tar..z/!d;s|.*">||;s|</.*||;q' |
pascal@24348 | 26 } |
pascal@24348 | 27 |
pascal@438 | 28 # Rules to configure and make the package. |
pascal@438 | 29 compile_rules() |
pascal@438 | 30 { |
pascal@20212 | 31 sed -i 's|uname -m|echo i486|' roms/openbios/utils/devbios/Makefile* |
pascal@23938 | 32 mkdir -p $DESTDIR/usr/share/qemu/ia32 $DESTDIR/usr/share/qemu/x64 |
pascal@19446 | 33 |
pascal@23937 | 34 for i in $UEFIZIP ; do |
pascal@23937 | 35 [ -s $SOURCES_REPOSITORY/$i ] || wget -P $SOURCES_REPOSITORY \ |
pascal@23937 | 36 $SF_MIRROR/project/edk2/OVMF/$i |
pascal@23937 | 37 unzip $SOURCES_REPOSITORY/$i OVMF.fd -d \ |
pascal@23937 | 38 $DESTDIR/usr/share/qemu/$(echo $i | sed 's|OVMF-\(.*\)-.*|\1|;y|AIX|aix|') |
pascal@23937 | 39 done |
pascal@19446 | 40 |
pascal@17989 | 41 patch -p0 < $stuff/cloop.u |
erjo@6068 | 42 |
pankso@10623 | 43 TARGET="i386-softmmu, x86_64-softmmu, \ |
pascal@23938 | 44 arm-softmmu, ppc-softmmu, mips-softmmu, mipsel-softmmu" |
pankso@12978 | 45 |
pascal@18000 | 46 export LDFLAGS="$LDFLAGS -Wl,--copy-dt-needed-entries" |
pankso@10623 | 47 #--cross-prefix= --host-cc= |
pankso@10623 | 48 ./configure \ |
pankso@3171 | 49 --prefix=/usr \ |
pankso@12978 | 50 --sysconfdir=/etc \ |
pankso@10623 | 51 --enable-sdl \ |
pascal@18000 | 52 --enable-curses \ |
pascal@19735 | 53 --disable-attr \ |
pankso@10623 | 54 --audio-drv-list=alsa,oss \ |
pankso@10623 | 55 --target-list="$TARGET" \ |
pankso@10623 | 56 --cc=$BUILD_SYSTEM-gcc && |
pankso@10623 | 57 make && make DESTDIR=$DESTDIR install |
pascal@438 | 58 } |
pascal@438 | 59 |
pascal@438 | 60 # Rules to gen a SliTaz package suitable for Tazpkg. |
pascal@438 | 61 genpkg_rules() |
pascal@438 | 62 { |
erjo@6068 | 63 mkdir -p $fs/usr/bin $fs/usr/share |
pankso@10626 | 64 |
pankso@12978 | 65 # /etc/qemu is for x86_64 |
pankso@12978 | 66 #cp -a $install/etc $fs |
pankso@12978 | 67 |
pankso@12978 | 68 cp -a $install/usr/bin/qemu-*-i386 $fs/usr/bin |
pankso@12978 | 69 cp -a $install/usr/bin/qemu-ga $fs/usr/bin |
pankso@12978 | 70 cp -a $install/usr/bin/qemu-io $fs/usr/bin |
pankso@12978 | 71 cp -a $install/usr/bin/qemu-img $fs/usr/bin |
pankso@12978 | 72 cp -a $install/usr/bin/qemu-nbd $fs/usr/bin |
pankso@12978 | 73 |
pankso@12978 | 74 cp -a $install/usr/share/qemu $fs/usr/share |
pascal@19960 | 75 cp -a $src/docs $install/usr/share/doc |
pankso@12978 | 76 |
erjo@6068 | 77 # Remove unneeded bios binaries |
erjo@6068 | 78 rm -f $fs/usr/share/qemu/*ppc* |
erjo@6068 | 79 rm -f $fs/usr/share/qemu/*sparc* |
pankso@12978 | 80 |
pankso@12978 | 81 # Create qemu symlink |
pankso@12978 | 82 cd $fs/usr/bin && ln -s qemu-system-i386 $PACKAGE |
pascal@438 | 83 } |