From nobody Tue Apr 30 02:50:19 2024 Delivered-To: importer@patchew.org Authentication-Results: mx.zohomail.com; dkim=fail; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=fail(p=none dis=none) header.from=redhat.com ARC-Seal: i=1; a=rsa-sha256; t=1600464230; cv=none; d=zohomail.com; s=zohoarc; b=O3o+aqgYorfVW0HvzoI13R2beZ2H8w7e3VmOz3PKyqYSNJi8b+bYZUylyj2vmZLNWmKVlP7f/f4CWg/3cQVwzseHt5fLFkaK/MgSxELRn3tOCrFqNLu5wd44XinPVaVlEAOCem5YCAprr9zW1uc78rUg3RxrgBZ7W0tR8rra3KE= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1600464230; h=Content-Type:Content-Transfer-Encoding:Cc:Date:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:To; bh=7fg4TsMMjf7HRn66+a8X8Q8KFOO8EknVqk/C/btKAjw=; b=gToOWCJynQ5fi2oL7Q75a0RUz3zD65lfAtqjcbdlwFNjRNcKWSR8ZBCWSCqZgb5oEaBlhM3bHtmRwj9jJ46kyVdYXyQI5wwQd6e/l5FisMEiT8qCz6SPtqOvy80qwkDYj8qGS5LJ82w5/gSIO+fO65Wt6DTbzKEA4ZgO6W3X07s= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=fail; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=fail header.from= (p=none dis=none) header.from= Return-Path: Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 1600464230022140.80220443568317; Fri, 18 Sep 2020 14:23:50 -0700 (PDT) Received: from localhost ([::1]:58962 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1kJNrA-0005YB-Cm for importer@patchew.org; Fri, 18 Sep 2020 17:23:48 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:48752) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1kJNIv-00034b-19 for qemu-devel@nongnu.org; Fri, 18 Sep 2020 16:48:25 -0400 Received: from us-smtp-delivery-124.mimecast.com ([63.128.21.124]:21634) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.90_1) (envelope-from ) id 1kJNIs-0006RY-Ne for qemu-devel@nongnu.org; Fri, 18 Sep 2020 16:48:24 -0400 Received: from mimecast-mx01.redhat.com (mimecast-mx01.redhat.com [209.132.183.4]) (Using TLS) by relay.mimecast.com with ESMTP id us-mta-306-QykwkBsFNUmYTrRFby1aFA-1; Fri, 18 Sep 2020 16:48:13 -0400 Received: from smtp.corp.redhat.com (int-mx02.intmail.prod.int.phx2.redhat.com [10.5.11.12]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx01.redhat.com (Postfix) with ESMTPS id E761510A7AE2; Fri, 18 Sep 2020 20:48:12 +0000 (UTC) Received: from localhost (unknown [10.36.110.14]) by smtp.corp.redhat.com (Postfix) with ESMTP id 6276E61177; Fri, 18 Sep 2020 20:48:10 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1600462102; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=7fg4TsMMjf7HRn66+a8X8Q8KFOO8EknVqk/C/btKAjw=; b=RwkCACPdvTduOiz4kgNXl+cK6ZDqvaKzX1Q2rkLn8P6qOhBScURhv/QcSq/K7nj+wmeeYZ +rceAN/4ScD4rtmh8I89MU06t1bL0/ZPc3o3Er0dq4Va2zLe5UbkB//xVD0NIEfBasXT+5 yqphJLVx2y7rNfguEfzDcvn5b/V7/RU= X-MC-Unique: QykwkBsFNUmYTrRFby1aFA-1 From: marcandre.lureau@redhat.com To: qemu-devel@nongnu.org Subject: [PATCH 1/6] meson: convert pc-bios/s390-ccw Date: Sat, 19 Sep 2020 00:47:54 +0400 Message-Id: <20200918204759.225810-2-marcandre.lureau@redhat.com> In-Reply-To: <20200918204759.225810-1-marcandre.lureau@redhat.com> References: <20200918204759.225810-1-marcandre.lureau@redhat.com> MIME-Version: 1.0 X-Scanned-By: MIMEDefang 2.79 on 10.5.11.12 Authentication-Results: relay.mimecast.com; auth=pass smtp.auth=CUSA124A263 smtp.mailfrom=marcandre.lureau@redhat.com X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Received-SPF: pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; envelope-from=qemu-devel-bounces+importer=patchew.org@nongnu.org; helo=lists.gnu.org; Received-SPF: pass client-ip=63.128.21.124; envelope-from=marcandre.lureau@redhat.com; helo=us-smtp-delivery-124.mimecast.com X-detected-operating-system: by eggs.gnu.org: First seen = 2020/09/18 00:20:40 X-ACL-Warn: Detected OS = Linux 2.2.x-3.x [generic] [fuzzy] X-Spam_score_int: -50 X-Spam_score: -5.1 X-Spam_bar: ----- X-Spam_report: (-5.1 / 5.0 requ) BAYES_00=-1.9, DKIMWL_WL_HIGH=-2.999, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, RCVD_IN_MSPIKE_H5=0.001, RCVD_IN_MSPIKE_WL=0.001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=unavailable autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Paolo Bonzini , qemu-s390x@nongnu.org, Thomas Huth , =?UTF-8?q?Marc-Andr=C3=A9=20Lureau?= Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org Sender: "Qemu-devel" X-ZohoMail-DKIM: fail (Header signature does not verify) From: Marc-Andr=C3=A9 Lureau Use a fake subproject: this is a simple workaround to avoid the incompatible flags (such as gprof) that are set globally for the rest of QEMU. Signed-off-by: Marc-Andr=C3=A9 Lureau --- configure | 2 - pc-bios/meson.build | 4 + pc-bios/s390-ccw/Makefile | 62 ------------ pc-bios/s390-ccw/meson.build | 177 +++++++++++++++++++++++++++++++++++ pc-bios/s390-ccw/netboot.mak | 62 ------------ subprojects/s390-ccw | 1 + 6 files changed, 182 insertions(+), 126 deletions(-) delete mode 100644 pc-bios/s390-ccw/Makefile create mode 100644 pc-bios/s390-ccw/meson.build delete mode 100644 pc-bios/s390-ccw/netboot.mak create mode 120000 subprojects/s390-ccw diff --git a/configure b/configure index 7564479008..3a8733c9be 100755 --- a/configure +++ b/configure @@ -6462,7 +6462,6 @@ fi if test "$cpu" =3D "s390x" ; then write_c_skeleton if compile_prog "-march=3Dz900" ""; then - roms=3D"$roms s390-ccw" # SLOF is required for building the s390-ccw firmware on s390x, # since it is using the libnet code from SLOF for network booting. if test -e "${source_path}/.git" ; then @@ -7863,7 +7862,6 @@ LINKS=3D"Makefile" LINKS=3D"$LINKS tests/tcg/lm32/Makefile" LINKS=3D"$LINKS tests/tcg/Makefile.target" LINKS=3D"$LINKS pc-bios/optionrom/Makefile" -LINKS=3D"$LINKS pc-bios/s390-ccw/Makefile" LINKS=3D"$LINKS roms/seabios/Makefile" LINKS=3D"$LINKS pc-bios/qemu-icon.bmp" LINKS=3D"$LINKS .gdbinit scripts" # scripts needed by relative path in .gd= binit diff --git a/pc-bios/meson.build b/pc-bios/meson.build index a0d21be432..e5139b3ef5 100644 --- a/pc-bios/meson.build +++ b/pc-bios/meson.build @@ -91,3 +91,7 @@ endif =20 subdir('descriptors') subdir('keymaps') + +if host_machine.cpu_family() =3D=3D 's390x' and cc.has_argument('-march=3D= z900') + subproject('s390-ccw') +endif diff --git a/pc-bios/s390-ccw/Makefile b/pc-bios/s390-ccw/Makefile deleted file mode 100644 index 3eb785048a..0000000000 --- a/pc-bios/s390-ccw/Makefile +++ /dev/null @@ -1,62 +0,0 @@ -all: build-all -# Dummy command so that make thinks it has done something - @true - -include ../../config-host.mak -CFLAGS =3D -O2 -g - -quiet-command =3D $(if $(V),$1,$(if $(2),@printf " %-7s %s\n" $2 $3 && $1= , @$1)) -cc-option =3D $(if $(shell $(CC) $1 -S -o /dev/null -xc /dev/null > /dev/n= ull \ - 2>&1 && echo OK), $1, $2) - -VPATH_SUFFIXES =3D %.c %.h %.S %.m %.mak %.sh %.rc Kconfig% %.json.in -set-vpath =3D $(if $1,$(foreach PATTERN,$(VPATH_SUFFIXES),$(eval vpath $(P= ATTERN) $1))) -$(call set-vpath, $(SRC_PATH)/pc-bios/s390-ccw) - -# Flags for dependency generation -QEMU_DGFLAGS =3D -MMD -MP -MT $@ -MF $(@D)/$(*F).d - -%.o: %.c - $(call quiet-command,$(CC) $(QEMU_CFLAGS) $(QEMU_DGFLAGS) $(CFLAGS) \ - -c -o $@ $<,"CC","$(TARGET_DIR)$@") - -%.o: %.S - $(call quiet-command,$(CCAS) $(QEMU_CFLAGS) $(QEMU_DGFLAGS) $(CFLAGS) \ - -c -o $@ $<,"CCAS","$(TARGET_DIR)$@") - -.PHONY : all clean build-all - -OBJECTS =3D start.o main.o bootmap.o jump2ipl.o sclp.o menu.o \ - virtio.o virtio-scsi.o virtio-blkdev.o libc.o cio.o dasd-ipl.o - -QEMU_CFLAGS :=3D -Wall $(filter -W%, $(QEMU_CFLAGS)) -QEMU_CFLAGS +=3D -ffreestanding -fno-delete-null-pointer-checks -msoft-flo= at -QEMU_CFLAGS +=3D -march=3Dz900 -fPIE -fno-strict-aliasing -QEMU_CFLAGS +=3D -fno-asynchronous-unwind-tables -QEMU_CFLAGS +=3D $(call cc-option, $(QEMU_CFLAGS), -fno-stack-protector) -LDFLAGS +=3D -Wl,-pie -nostdlib - -build-all: s390-ccw.img s390-netboot.img - -s390-ccw.elf: $(OBJECTS) - $(call quiet-command,$(CC) $(LDFLAGS) -o $@ $(OBJECTS),"BUILD","$(TARGET_= DIR)$@") - -STRIP ?=3D strip - -s390-ccw.img: s390-ccw.elf - $(call quiet-command,$(STRIP) --strip-unneeded $< -o $@,"STRIP","$(TARGET= _DIR)$@") - -$(OBJECTS): Makefile - -ifneq ($(wildcard $(SRC_PATH)/roms/SLOF/lib/libnet),) -include $(SRC_PATH)/pc-bios/s390-ccw/netboot.mak -else -s390-netboot.img: - @echo "s390-netboot.img not built since roms/SLOF/ is not available." -endif - -ALL_OBJS =3D $(sort $(OBJECTS) $(NETOBJS) $(LIBCOBJS) $(LIBNETOBJS)) --include $(ALL_OBJS:%.o=3D%.d) - -clean: - rm -f *.o *.d *.img *.elf *~ *.a diff --git a/pc-bios/s390-ccw/meson.build b/pc-bios/s390-ccw/meson.build new file mode 100644 index 0000000000..0de5400287 --- /dev/null +++ b/pc-bios/s390-ccw/meson.build @@ -0,0 +1,177 @@ +project('s390-ccw') + +strip =3D find_program('strip') +cc =3D meson.get_compiler('c') +link_args =3D ['-Wl,-pie', '-nostdlib'] + +# FIXME: find a better way to check/enable slof +slof =3D '../../roms/SLOF' +has_slof =3D cc.has_header('libnet/tftp.h', args: '-I' + meson.current_sou= rce_dir() / slof / 'lib') + +s390_cargs =3D [ + '-ffreestanding', + '-fno-delete-null-pointer-checks', + '-msoft-float', + '-march=3Dz900', + '-fPIE', + '-fno-strict-aliasing', + '-fno-asynchronous-unwind-tables', + cc.get_supported_arguments('-fno-stack-protector') +] + +s390_incs =3D [] + +s390_srcs =3D [ + 'bootmap.c', + 'cio.c', + 'dasd-ipl.c', + 'jump2ipl.c', + 'libc.c', + 'main.c', + 'menu.c', + 'sclp.c', + 'start.S', + 'virtio-blkdev.c', + 'virtio-scsi.c', + 'virtio.c', +] + +if has_slof + s390_srcs +=3D [ + 'netmain.c', + 'virtio-net.c', + ] + s390_incs +=3D include_directories(slof / 'lib/libnet') + s390_incs +=3D include_directories(slof / 'lib/libc/include') + s390_cargs +=3D '-nostdinc' +endif + +s390_lib =3D static_library( + 's390', s390_srcs, + c_args: s390_cargs, + include_directories: s390_incs, +) + +s390_ccw_elf =3D executable( + 's390-ccw.elf', + link_args: link_args, + objects: s390_lib.extract_objects([ + 'bootmap.c', + 'cio.c', + 'dasd-ipl.c', + 'jump2ipl.c', + 'libc.c', + 'main.c', + 'menu.c', + 'sclp.c', + 'start.S', + 'virtio-blkdev.c', + 'virtio-scsi.c', + 'virtio.c', + ]), +) + +custom_target( + 's390-ccw.img', + output: 's390-ccw.img', + input: s390_ccw_elf, + command: [strip, '--strip-unneeded', '@INPUT@', '-o', '@OUTPUT@'], + build_by_default: true, +) + +if has_slof + slof_ctype =3D slof / 'lib/libc/ctype' + slof_str =3D slof / 'lib/libc/string' + slof_stdlib =3D slof / 'lib/libc/stdlib' + slof_stdio =3D slof / 'lib/libc/stdio' + + s390_libc =3D static_library( + 's390-libc', files( + slof_ctype / 'isdigit.c', + slof_ctype / 'isxdigit.c', + slof_ctype / 'toupper.c', + slof_str / 'strcat.c', + slof_str / 'strchr.c', + slof_str / 'strrchr.c', + slof_str / 'strcpy.c', + slof_str / 'strlen.c', + slof_str / 'strncpy.c', + slof_str / 'strcmp.c', + slof_str / 'strncmp.c', + slof_str / 'strcasecmp.c', + slof_str / 'strncasecmp.c', + slof_str / 'strstr.c', + slof_str / 'memset.c', + slof_str / 'memcpy.c', + slof_str / 'memmove.c', + slof_str / 'memcmp.c', + slof_stdlib / 'atoi.c', + slof_stdlib / 'atol.c', + slof_stdlib / 'strtoul.c', + slof_stdlib / 'strtol.c', + slof_stdlib / 'rand.c', + slof_stdlib / 'malloc.c', + slof_stdlib / 'free.c', + slof_stdio / 'sprintf.c', + slof_stdio / 'snprintf.c', + slof_stdio / 'vfprintf.c', + slof_stdio / 'vsnprintf.c', + slof_stdio / 'vsprintf.c', + slof_stdio / 'fprintf.c', + slof_stdio / 'printf.c', + slof_stdio / 'putc.c', + slof_stdio / 'puts.c', + slof_stdio / 'putchar.c', + slof_stdio / 'stdchnls.c', + slof_stdio / 'fileno.c', + slof / 'slof/sbrk.c', + ), + c_args: s390_cargs, + include_directories: s390_incs, + ) + + slof_libnet =3D slof / 'lib/libnet' + s390_libnet =3D static_library( + 's390-libnet', files( + slof_libnet / 'args.c', + slof_libnet / 'dhcp.c', + slof_libnet / 'dns.c', + slof_libnet / 'icmpv6.c', + slof_libnet / 'ipv6.c', + slof_libnet / 'tcp.c', + slof_libnet / 'udp.c', + slof_libnet / 'bootp.c', + slof_libnet / 'dhcpv6.c', + slof_libnet / 'ethernet.c', + slof_libnet / 'ipv4.c', + slof_libnet / 'ndp.c', + slof_libnet / 'tftp.c', + slof_libnet / 'pxelinux.c', + ), + c_args: [s390_cargs, '-DDHCPARCH=3D0x1F'], + include_directories: s390_incs, + ) + + s390_netboot_elf =3D executable( + 's390-netboot.elf', + link_with: [s390_libc, s390_libnet], + link_args: [link_args, '-Ttext=3D0x7800000'], + objects: s390_lib.extract_objects([ + 'cio.c', + 'jump2ipl.c', + 'netmain.c', + 'sclp.c', + 'start.S', + 'virtio-net.c', + 'virtio.c', + ]), + ) + + custom_target( + 's390-netboot.img', + output: 's390-netboot.img', + input: s390_netboot_elf, + command: [strip, '--strip-unneeded', '@INPUT@', '-o', '@OUTPUT@'], + build_by_default: true, + ) +endif diff --git a/pc-bios/s390-ccw/netboot.mak b/pc-bios/s390-ccw/netboot.mak deleted file mode 100644 index 577c023afe..0000000000 --- a/pc-bios/s390-ccw/netboot.mak +++ /dev/null @@ -1,62 +0,0 @@ - -SLOF_DIR :=3D $(SRC_PATH)/roms/SLOF - -NETOBJS :=3D start.o sclp.o cio.o virtio.o virtio-net.o jump2ipl.o netmain= .o - -LIBC_INC :=3D -nostdinc -I$(SLOF_DIR)/lib/libc/include -LIBNET_INC :=3D -I$(SLOF_DIR)/lib/libnet - -NETLDFLAGS :=3D $(LDFLAGS) -Ttext=3D0x7800000 - -$(NETOBJS): QEMU_CFLAGS +=3D $(LIBC_INC) $(LIBNET_INC) - -s390-netboot.elf: $(NETOBJS) libnet.a libc.a - $(call quiet-command,$(CC) $(NETLDFLAGS) -o $@ $^,"BUILD","$(TARGET_DIR)$= @") - -s390-netboot.img: s390-netboot.elf - $(call quiet-command,$(STRIP) --strip-unneeded $< -o $@,"STRIP","$(TARGET= _DIR)$@") - -# libc files: - -LIBC_CFLAGS =3D $(QEMU_CFLAGS) $(CFLAGS) $(LIBC_INC) $(LIBNET_INC) \ - -MMD -MP -MT $@ -MF $(@:%.o=3D%.d) - -CTYPE_OBJS =3D isdigit.o isxdigit.o toupper.o -%.o : $(SLOF_DIR)/lib/libc/ctype/%.c - $(call quiet-command,$(CC) $(LIBC_CFLAGS) -c -o $@ $<,"CC","$(TARGET_DIR)= $@") - -STRING_OBJS =3D strcat.o strchr.o strrchr.o strcpy.o strlen.o strncpy.o \ - strcmp.o strncmp.o strcasecmp.o strncasecmp.o strstr.o \ - memset.o memcpy.o memmove.o memcmp.o -%.o : $(SLOF_DIR)/lib/libc/string/%.c - $(call quiet-command,$(CC) $(LIBC_CFLAGS) -c -o $@ $<,"CC","$(TARGET_DIR)= $@") - -STDLIB_OBJS =3D atoi.o atol.o strtoul.o strtol.o rand.o malloc.o free.o -%.o : $(SLOF_DIR)/lib/libc/stdlib/%.c - $(call quiet-command,$(CC) $(LIBC_CFLAGS) -c -o $@ $<,"CC","$(TARGET_DIR)= $@") - -STDIO_OBJS =3D sprintf.o snprintf.o vfprintf.o vsnprintf.o vsprintf.o fpri= ntf.o \ - printf.o putc.o puts.o putchar.o stdchnls.o fileno.o -%.o : $(SLOF_DIR)/lib/libc/stdio/%.c - $(call quiet-command,$(CC) $(LIBC_CFLAGS) -c -o $@ $<,"CC","$(TARGET_DIR)= $@") - -sbrk.o: $(SLOF_DIR)/slof/sbrk.c - $(call quiet-command,$(CC) $(LIBC_CFLAGS) -c -o $@ $<,"CC","$(TARGET_DIR)= $@") - -LIBCOBJS :=3D $(STRING_OBJS) $(CTYPE_OBJS) $(STDLIB_OBJS) $(STDIO_OBJS) sb= rk.o - -libc.a: $(LIBCOBJS) - $(call quiet-command,$(AR) -rc $@ $^,"AR","$(TARGET_DIR)$@") - -# libnet files: - -LIBNETOBJS :=3D args.o dhcp.o dns.o icmpv6.o ipv6.o tcp.o udp.o bootp.o \ - dhcpv6.o ethernet.o ipv4.o ndp.o tftp.o pxelinux.o -LIBNETCFLAGS =3D $(QEMU_CFLAGS) $(CFLAGS) $(LIBC_INC) $(LIBNET_INC) \ - -DDHCPARCH=3D0x1F -MMD -MP -MT $@ -MF $(@:%.o=3D%.d) - -%.o : $(SLOF_DIR)/lib/libnet/%.c - $(call quiet-command,$(CC) $(LIBNETCFLAGS) -c -o $@ $<,"CC","$(TARGET_DIR= )$@") - -libnet.a: $(LIBNETOBJS) - $(call quiet-command,$(AR) -rc $@ $^,"AR","$(TARGET_DIR)$@") diff --git a/subprojects/s390-ccw b/subprojects/s390-ccw new file mode 120000 index 0000000000..8a3120224b --- /dev/null +++ b/subprojects/s390-ccw @@ -0,0 +1 @@ +../pc-bios/s390-ccw \ No newline at end of file --=20 2.26.2 From nobody Tue Apr 30 02:50:19 2024 Delivered-To: importer@patchew.org Authentication-Results: mx.zohomail.com; dkim=fail; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=fail(p=none dis=none) header.from=redhat.com ARC-Seal: i=1; a=rsa-sha256; t=1600463906; cv=none; d=zohomail.com; s=zohoarc; b=Wo3C+xO2n3yFCnuS1RxYg76ohuRu52kjLNXFUJBQqXLTWASiVfwA9U5dGZvOCLNhXqV+wFqmurM3i76L8LeUujHwIQIFW92Vsjid/LOdju+cX8rcG78m0XgBfMExzribH5ILCA7H9hzYrFfo0pGxQNwSQDDjIp4xRd5fuNfg67M= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1600463906; h=Content-Type:Content-Transfer-Encoding:Cc:Date:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:To; bh=RgtxjQRSf4W9qU5Ip+wO9lc4JihTBmdZDwEbKvkqutE=; b=bS9YVkg4EWF6FzhLJZeSmrIiI5779UF5PFAiWKN5D3s2Zf5Ld7s7b3FCnfmG5nQa5K0Q4W7aA44+mUnwUnsAJFwU8Tcln4X/d0mmxtBcRX0fUuiH3Szet7dnNYQbKTPPFMQP8sfU9jgCUrlYKPJ6GMsyXgCxtlDXWejAwFfw5ps= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=fail; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=fail header.from= (p=none dis=none) header.from= Return-Path: Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 1600463906149934.128377240677; Fri, 18 Sep 2020 14:18:26 -0700 (PDT) Received: from localhost ([::1]:49932 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1kJNlv-0001e8-Do for importer@patchew.org; Fri, 18 Sep 2020 17:18:23 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:48780) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1kJNIw-00036O-Cb for qemu-devel@nongnu.org; Fri, 18 Sep 2020 16:48:26 -0400 Received: from us-smtp-delivery-124.mimecast.com ([216.205.24.124]:32977) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.90_1) (envelope-from ) id 1kJNIu-0006SF-Qb for qemu-devel@nongnu.org; Fri, 18 Sep 2020 16:48:26 -0400 Received: from mimecast-mx01.redhat.com (mimecast-mx01.redhat.com [209.132.183.4]) (Using TLS) by relay.mimecast.com with ESMTP id us-mta-509-5nkq1ViOOwi511R4HdoKWw-1; Fri, 18 Sep 2020 16:48:19 -0400 Received: from smtp.corp.redhat.com (int-mx02.intmail.prod.int.phx2.redhat.com [10.5.11.12]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx01.redhat.com (Postfix) with ESMTPS id EC49110A7AE6; Fri, 18 Sep 2020 20:48:18 +0000 (UTC) Received: from localhost (unknown [10.36.110.14]) by smtp.corp.redhat.com (Postfix) with ESMTP id EF1A260C11; Fri, 18 Sep 2020 20:48:17 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1600462104; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=RgtxjQRSf4W9qU5Ip+wO9lc4JihTBmdZDwEbKvkqutE=; b=IaYoB7qZvocPpAL/RiHlHDjJKJmOdQlq9xbRvp/O74fhwCNywRMF03uiig3St6AM9IhGQ8 2ls2LltsaA6y7kLkcNKBsOA6GOQQmx9wXAxGaceQ6sEpyzyCvIgGZXdBbkd36897DAE4fW WFtyk5DWwnZwQvu1ncKnaeyFke6FAB0= X-MC-Unique: 5nkq1ViOOwi511R4HdoKWw-1 From: marcandre.lureau@redhat.com To: qemu-devel@nongnu.org Subject: [PATCH 2/6] optionrom: make kvmapic.S compile with clang Date: Sat, 19 Sep 2020 00:47:55 +0400 Message-Id: <20200918204759.225810-3-marcandre.lureau@redhat.com> In-Reply-To: <20200918204759.225810-1-marcandre.lureau@redhat.com> References: <20200918204759.225810-1-marcandre.lureau@redhat.com> MIME-Version: 1.0 X-Scanned-By: MIMEDefang 2.79 on 10.5.11.12 Authentication-Results: relay.mimecast.com; auth=pass smtp.auth=CUSA124A263 smtp.mailfrom=marcandre.lureau@redhat.com X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Received-SPF: pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; envelope-from=qemu-devel-bounces+importer=patchew.org@nongnu.org; helo=lists.gnu.org; Received-SPF: pass client-ip=216.205.24.124; envelope-from=marcandre.lureau@redhat.com; helo=us-smtp-delivery-124.mimecast.com X-detected-operating-system: by eggs.gnu.org: First seen = 2020/09/18 01:32:10 X-ACL-Warn: Detected OS = Linux 2.2.x-3.x [generic] [fuzzy] X-Spam_score_int: -50 X-Spam_score: -5.1 X-Spam_bar: ----- X-Spam_report: (-5.1 / 5.0 requ) BAYES_00=-1.9, DKIMWL_WL_HIGH=-2.999, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, RCVD_IN_MSPIKE_H5=0.001, RCVD_IN_MSPIKE_WL=0.001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=unavailable autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Paolo Bonzini , qemu-s390x@nongnu.org, Thomas Huth , =?UTF-8?q?Marc-Andr=C3=A9=20Lureau?= Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org Sender: "Qemu-devel" X-ZohoMail-DKIM: fail (Header signature does not verify) From: Marc-Andr=C3=A9 Lureau Clang doesn't support specifying segment prefixes before the instruction, and requires specifying them on the address. Signed-off-by: Marc-Andr=C3=A9 Lureau --- pc-bios/optionrom/kvmvapic.S | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pc-bios/optionrom/kvmvapic.S b/pc-bios/optionrom/kvmvapic.S index aa17a402df..9a615549e6 100644 --- a/pc-bios/optionrom/kvmvapic.S +++ b/pc-bios/optionrom/kvmvapic.S @@ -104,7 +104,7 @@ mp_get_tpr_eax: reenable_vtpr push %ecx =20 - fs/movzbl pcr_cpu, %eax + movzbl %fs:pcr_cpu, %eax =20 mov vcpu_shift, %ecx ; fixup shl %cl, %eax @@ -178,7 +178,7 @@ mp_set_tpr: reenable_vtpr =20 mp_set_tpr_failed: - fs/movzbl pcr_cpu, %edx + movzbl %fs:pcr_cpu, %edx =20 mov vcpu_shift, %ecx ; fixup shl %cl, %edx --=20 2.26.2 From nobody Tue Apr 30 02:50:19 2024 Delivered-To: importer@patchew.org Authentication-Results: mx.zohomail.com; dkim=fail; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=fail(p=none dis=none) header.from=redhat.com ARC-Seal: i=1; a=rsa-sha256; t=1600464009; cv=none; d=zohomail.com; s=zohoarc; b=Slf3T8+aJ3C1fMqPeBrSfCOBFDFzMi1ZHwqVNGfIpfzcvGGsL8EaXUjX2Fk0oS0+uFcbCwR0Ec41act0JPl1fAOK7UrfA8l22V/VZJsQhPSSGT8EigflMBI3b6W0ahvM/Lps0DfGsISpqgnonHvK41xSmpvZaW8xTG55JoSpWUo= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1600464009; h=Content-Type:Content-Transfer-Encoding:Cc:Date:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:To; bh=Rg1vUGg+NQh0UsEWhYotEM8dC8ClGTsLqERdGE5uJ44=; b=K4M1+m71j0QnAk7ny0gMwtzLo/TwRWu1P0wEE1rdvX9GF/QyYVsC1lcrjuVpHm+XrUsDtGVfguZMqHnMhZqCa0wuPOrShVCoO2y0UYy5c/SqIZIR8XfKqzHA6Gtsd/pOwdKhIc2B7WMgHIuxZgHP7lGasdzij6Dqk8sGvDwZohA= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=fail; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=fail header.from= (p=none dis=none) header.from= Return-Path: Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 1600464009321281.70908077514787; Fri, 18 Sep 2020 14:20:09 -0700 (PDT) Received: from localhost ([::1]:53904 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1kJNnb-0003Ih-Uw for importer@patchew.org; Fri, 18 Sep 2020 17:20:08 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:48814) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1kJNJ5-0003BD-JK for qemu-devel@nongnu.org; Fri, 18 Sep 2020 16:48:35 -0400 Received: from us-smtp-delivery-124.mimecast.com ([63.128.21.124]:46411) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.90_1) (envelope-from ) id 1kJNJ3-0006TF-87 for qemu-devel@nongnu.org; Fri, 18 Sep 2020 16:48:35 -0400 Received: from mimecast-mx01.redhat.com (mimecast-mx01.redhat.com [209.132.183.4]) (Using TLS) by relay.mimecast.com with ESMTP id us-mta-576-Men7KVHGPbOIGiijL_DFUw-1; Fri, 18 Sep 2020 16:48:27 -0400 Received: from smtp.corp.redhat.com (int-mx07.intmail.prod.int.phx2.redhat.com [10.5.11.22]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx01.redhat.com (Postfix) with ESMTPS id E4AC618BA288; Fri, 18 Sep 2020 20:48:26 +0000 (UTC) Received: from localhost (unknown [10.36.110.14]) by smtp.corp.redhat.com (Postfix) with ESMTP id BE17510013C1; Fri, 18 Sep 2020 20:48:22 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1600462111; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=Rg1vUGg+NQh0UsEWhYotEM8dC8ClGTsLqERdGE5uJ44=; b=BV+FDtsuzKQ9i8hEUAwU/nIZVVeeEkOnuwuzQGheAdBoGUJynlSS3go8NO92ZovwURacS6 phL1vrrI8HjZGKu0vRMT/tmce6cOc7jzHTekEPgTKINgGmAhCl642HXFw1+sG7pHUUhvcG zncN1Tf+nOupb0BWt3SBt/8MffI8n2A= X-MC-Unique: Men7KVHGPbOIGiijL_DFUw-1 From: marcandre.lureau@redhat.com To: qemu-devel@nongnu.org Subject: [PATCH 3/6] meson: convert pc-bios/optionrom Date: Sat, 19 Sep 2020 00:47:56 +0400 Message-Id: <20200918204759.225810-4-marcandre.lureau@redhat.com> In-Reply-To: <20200918204759.225810-1-marcandre.lureau@redhat.com> References: <20200918204759.225810-1-marcandre.lureau@redhat.com> MIME-Version: 1.0 X-Scanned-By: MIMEDefang 2.84 on 10.5.11.22 Authentication-Results: relay.mimecast.com; auth=pass smtp.auth=CUSA124A263 smtp.mailfrom=marcandre.lureau@redhat.com X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Received-SPF: pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; envelope-from=qemu-devel-bounces+importer=patchew.org@nongnu.org; helo=lists.gnu.org; Received-SPF: pass client-ip=63.128.21.124; envelope-from=marcandre.lureau@redhat.com; helo=us-smtp-delivery-124.mimecast.com X-detected-operating-system: by eggs.gnu.org: First seen = 2020/09/18 00:20:40 X-ACL-Warn: Detected OS = Linux 2.2.x-3.x [generic] [fuzzy] X-Spam_score_int: -50 X-Spam_score: -5.1 X-Spam_bar: ----- X-Spam_report: (-5.1 / 5.0 requ) BAYES_00=-1.9, DKIMWL_WL_HIGH=-2.999, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, RCVD_IN_MSPIKE_H5=0.001, RCVD_IN_MSPIKE_WL=0.001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=unavailable autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Paolo Bonzini , qemu-s390x@nongnu.org, Thomas Huth , =?UTF-8?q?Marc-Andr=C3=A9=20Lureau?= Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org Sender: "Qemu-devel" X-ZohoMail-DKIM: fail (Header signature does not verify) From: Marc-Andr=C3=A9 Lureau Checking for linker emulation is a bit tricky with meson, since it actually tries to compile a file with a main(). I didn't bother to port the Darwin or SunOS check, as they are quite old, and not very specific to the compiler version/issue, so they might be outdated. Use a subproject: this is a simple workaround to avoid the incompatible flags (such as gprof) that are set globally for the rest of QEMU. Signed-off-by: Marc-Andr=C3=A9 Lureau --- configure | 16 -------- pc-bios/meson.build | 4 ++ pc-bios/optionrom/Makefile | 73 ----------------------------------- pc-bios/optionrom/meson.build | 73 +++++++++++++++++++++++++++++++++++ subprojects/optionrom | 1 + 5 files changed, 78 insertions(+), 89 deletions(-) delete mode 100644 pc-bios/optionrom/Makefile create mode 100644 pc-bios/optionrom/meson.build create mode 120000 subprojects/optionrom diff --git a/configure b/configure index 3a8733c9be..4e56edc70c 100755 --- a/configure +++ b/configure @@ -6441,22 +6441,7 @@ if test "$guest_agent_msi" =3D "yes"; then esac fi =20 -# Mac OS X ships with a broken assembler roms=3D -if { test "$cpu" =3D "i386" || test "$cpu" =3D "x86_64"; } && \ - test "$targetos" !=3D "Darwin" && test "$targetos" !=3D "SunOS" &&= \ - test "$softmmu" =3D yes ; then - # Different host OS linkers have different ideas about the name of the= ELF - # emulation. Linux and OpenBSD/amd64 use 'elf_i386'; FreeBSD uses the = _fbsd - # variant; OpenBSD/i386 uses the _obsd variant; and Windows uses i386p= e. - for emu in elf_i386 elf_i386_fbsd elf_i386_obsd i386pe; do - if "$ld" -verbose 2>&1 | grep -q "^[[:space:]]*$emu[[:space:]]*$";= then - ld_i386_emulation=3D"$emu" - roms=3D"optionrom" - break - fi - done -fi =20 # Only build s390-ccw bios if we're on s390x and the compiler has -march= =3Dz900 if test "$cpu" =3D "s390x" ; then @@ -7861,7 +7846,6 @@ DIRS=3D"$DIRS contrib/plugins/" LINKS=3D"Makefile" LINKS=3D"$LINKS tests/tcg/lm32/Makefile" LINKS=3D"$LINKS tests/tcg/Makefile.target" -LINKS=3D"$LINKS pc-bios/optionrom/Makefile" LINKS=3D"$LINKS roms/seabios/Makefile" LINKS=3D"$LINKS pc-bios/qemu-icon.bmp" LINKS=3D"$LINKS .gdbinit scripts" # scripts needed by relative path in .gd= binit diff --git a/pc-bios/meson.build b/pc-bios/meson.build index e5139b3ef5..d25585ca97 100644 --- a/pc-bios/meson.build +++ b/pc-bios/meson.build @@ -92,6 +92,10 @@ endif subdir('descriptors') subdir('keymaps') =20 +if host_machine.cpu_family() in ['x86', 'x86_64'] + subproject('optionrom') +endif + if host_machine.cpu_family() =3D=3D 's390x' and cc.has_argument('-march=3D= z900') subproject('s390-ccw') endif diff --git a/pc-bios/optionrom/Makefile b/pc-bios/optionrom/Makefile deleted file mode 100644 index 084fc10f05..0000000000 --- a/pc-bios/optionrom/Makefile +++ /dev/null @@ -1,73 +0,0 @@ -CURRENT_MAKEFILE :=3D $(realpath $(word $(words $(MAKEFILE_LIST)),$(MAKEFI= LE_LIST))) -SRC_DIR :=3D $(dir $(CURRENT_MAKEFILE)) -TOPSRC_DIR :=3D $(SRC_DIR)/../.. -VPATH =3D $(SRC_DIR) - -all: multiboot.bin linuxboot.bin linuxboot_dma.bin kvmvapic.bin pvh.bin -# Dummy command so that make thinks it has done something - @true - -include ../../config-host.mak -CFLAGS =3D -O2 -g - -quiet-command =3D $(if $(V),$1,$(if $(2),@printf " %-7s %s\n" $2 $3 && $1= , @$1)) -cc-option =3D $(if $(shell $(CC) $1 -c -o /dev/null -xc /dev/null >/dev/nu= ll 2>&1 && echo OK), $1, $2) - -override CFLAGS +=3D -march=3Di486 -Wall - -# Flags for dependency generation -override CPPFLAGS +=3D -MMD -MP -MT $@ -MF $(@D)/$(*F).d - -override CFLAGS +=3D $(filter -W%, $(QEMU_CFLAGS)) -override CFLAGS +=3D $(CFLAGS_NOPIE) -ffreestanding -I$(TOPSRC_DIR)/include -override CFLAGS +=3D $(call cc-option, -fno-stack-protector) -override CFLAGS +=3D $(call cc-option, -m16) - -ifeq ($(filter -m16, $(CFLAGS)),) -# Attempt to work around compilers that lack -m16 (GCC <=3D 4.8, clang <= =3D ??) -# On GCC we add -fno-toplevel-reorder to keep the order of asm blocks with -# respect to the rest of the code. clang does not have -fno-toplevel-reor= der, -# but it places all asm blocks at the beginning and we're relying on it for -# the option ROM header. So just force clang not to use the integrated -# assembler, which doesn't support .code16gcc. -override CFLAGS +=3D $(call cc-option, -fno-toplevel-reorder) -override CFLAGS +=3D $(call cc-option, -no-integrated-as) -override CFLAGS +=3D -m32 -include $(SRC_DIR)/code16gcc.h -endif - -Wa =3D -Wa, -override ASFLAGS +=3D -32 -override CFLAGS +=3D $(call cc-option, $(Wa)-32) - -LD_I386_EMULATION ?=3D elf_i386 -override LDFLAGS =3D -m $(LD_I386_EMULATION) -T $(SRC_DIR)/flat.lds -override LDFLAGS +=3D $(LDFLAGS_NOPIE) - -all: multiboot.bin linuxboot.bin linuxboot_dma.bin kvmvapic.bin pvh.bin - -pvh.img: pvh.o pvh_main.o - -%.o: %.S - $(call quiet-command,$(CPP) $(CPPFLAGS) -c -o - $< | $(AS) $(ASFLAGS) -o = $@,"AS","$@") - -%.o: %.c - $(call quiet-command,$(CC) $(CPPFLAGS) $(CFLAGS) -c $< -o $@,"CC","$@") - -%.img: %.o - $(call quiet-command,$(LD) $(LDFLAGS) -s -o $@ $^,"BUILD","$@") - -%.raw: %.img - $(call quiet-command,$(OBJCOPY) -O binary -j .text $< $@,"BUILD","$@") - -%.bin: %.raw - $(call quiet-command,$(PYTHON) $(TOPSRC_DIR)/scripts/signrom.py $< $@,"SI= GN","$@") - -include $(wildcard *.d) - -clean: - rm -f *.o *.d *.raw *.img *.bin *~ - -# suppress auto-removal of intermediate files -.SECONDARY: - -.PHONY: all clean diff --git a/pc-bios/optionrom/meson.build b/pc-bios/optionrom/meson.build new file mode 100644 index 0000000000..7d5314cd80 --- /dev/null +++ b/pc-bios/optionrom/meson.build @@ -0,0 +1,73 @@ +project('optionrom') + +cc =3D meson.get_compiler('c') +objcopy =3D find_program('objcopy') +signrom =3D find_program(meson.current_source_dir() / '../../scripts/signr= om.py') + +emu =3D '' +foreach e: ['elf_i386', 'elf_i386_fbsd', 'elf_i386_obsd', 'i386pe'] + if cc.has_multi_link_arguments('-nostdlib', '-Wl,-emain', '-m32', '-Wl,-= m' + e) + emu =3D e + break + endif +endforeach + +if emu =3D=3D '' + message('No suitable compiler/linker found to build optionrom') + subdir_done() +endif + +link_args =3D ['-nostdlib', '-m32', '-Wl,-m' + e] +link_args +=3D cc.get_supported_link_arguments('-Wl,--build-id=3Dnone') +if cc.has_multi_link_arguments('-fno-pie', '-no-pie') + link_args +=3D ['-no-pie'] +endif + +link_args +=3D '-Wl,-T' + meson.current_source_dir() / 'flat.lds' + +c_args =3D ['-O2', '-ffreestanding', '-march=3Di486'] +c_args +=3D cc.get_supported_arguments('-fno-pie', '-fno-stack-protector',= '-Wa,-32') +if cc.has_argument('-m16') + c_args +=3D '-m16' +else + # Attempt to work around compilers that lack -m16 (GCC <=3D 4.8, clang <= =3D ??) + # On GCC we add -fno-toplevel-reorder to keep the order of asm blocks wi= th + # respect to the rest of the code. clang does not have -fno-toplevel-re= order, + # but it places all asm blocks at the beginning and we're relying on it = for + # the option ROM header. So just force clang not to use the integrated + # assembler, which doesn't support .code16gcc. + c_args +=3D cc.get_supported_arguments('-fno-toplevel-reorder', '-no-int= egrated-as') + c_args +=3D ['-m32', '-include', meson.current_source_dir() / 'code16gcc= .h'] +endif + +foreach target, src: { + 'multiboot': ['multiboot.S'], + 'linuxboot_dma': ['linuxboot_dma.c'], + 'linuxboot': ['linuxboot.S'], + 'kvmvapic': ['kvmvapic.S'], + 'pvh': ['pvh.S', 'pvh_main.c'], + } + img =3D executable( + target + '.img', + src, + c_args: c_args, + include_directories: include_directories('../../include'), + link_args: link_args, + override_options: ['b_coverage=3Dfalse'], + ) + + raw =3D custom_target( + target + '.raw', + output: target + '.raw', + input: img, + command: [objcopy, '-O', 'binary', '-j', '.text', '@INPUT@', '@OUTPUT@= '], + ) + + bin =3D custom_target( + target + '.bin', + output: target + '.bin', + input: raw, + command: [signrom, '@INPUT@', '@OUTPUT@'], + build_by_default: true, + ) +endforeach diff --git a/subprojects/optionrom b/subprojects/optionrom new file mode 120000 index 0000000000..0bd7ed1798 --- /dev/null +++ b/subprojects/optionrom @@ -0,0 +1 @@ +../pc-bios/optionrom \ No newline at end of file --=20 2.26.2 From nobody Tue Apr 30 02:50:19 2024 Delivered-To: importer@patchew.org Authentication-Results: mx.zohomail.com; dkim=fail; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=fail(p=none dis=none) header.from=redhat.com ARC-Seal: i=1; a=rsa-sha256; t=1600463429; cv=none; d=zohomail.com; s=zohoarc; b=iP0zBjdUt64lvUCOnUDcmMAu9CvU/geH65O3J1Imhs6Gwig/HoAxGZpTQINC8/cBjtMBy1T1dOWUwxyuk8tBC0G05mXRQrSVc1B0TGrXzrnyjyzcpg3a6kSMax/Wj8K6Lmtyidnpjpq0XgGLzLIOzoP9KQ8TBVaKMS+aLS21VH0= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1600463429; h=Content-Type:Content-Transfer-Encoding:Cc:Date:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:To; bh=zvFv1j+LUHE70KrYKy1UKr/5aVj0KpVcurmkUc+3HJs=; b=HbzMxL4WQDJFZkGLukC55tbg7XvHAPRCYZERaPoXh1LoWPtVtucO5j3K3gEQEplSP7d4shzIjUKbSGmH22uMb22+oGV4mKi3RZVbTbn3+J7rVhLHOAmGme7J0h7HToM1lmY9YpfsMfcPRX8vPpyr2dziGMDeOhyR2risZgH/Xts= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=fail; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=fail header.from= (p=none dis=none) header.from= Return-Path: Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 1600463429005361.9319498584392; Fri, 18 Sep 2020 14:10:29 -0700 (PDT) Received: from localhost ([::1]:59056 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1kJNeD-0001zL-Ka for importer@patchew.org; Fri, 18 Sep 2020 17:10:25 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:48848) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1kJNJJ-0003K2-B2 for qemu-devel@nongnu.org; Fri, 18 Sep 2020 16:48:50 -0400 Received: from us-smtp-delivery-124.mimecast.com ([216.205.24.124]:47516) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.90_1) (envelope-from ) id 1kJNJD-0006Tw-PU for qemu-devel@nongnu.org; Fri, 18 Sep 2020 16:48:45 -0400 Received: from mimecast-mx01.redhat.com (mimecast-mx01.redhat.com [209.132.183.4]) (Using TLS) by relay.mimecast.com with ESMTP id us-mta-577-cKyohpSJNH-dknVPVxmYiQ-1; Fri, 18 Sep 2020 16:48:40 -0400 Received: from smtp.corp.redhat.com (int-mx02.intmail.prod.int.phx2.redhat.com [10.5.11.12]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx01.redhat.com (Postfix) with ESMTPS id C81231018F63; Fri, 18 Sep 2020 20:48:35 +0000 (UTC) Received: from localhost (unknown [10.36.110.14]) by smtp.corp.redhat.com (Postfix) with ESMTP id DD6A460C07; Fri, 18 Sep 2020 20:48:31 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1600462123; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=zvFv1j+LUHE70KrYKy1UKr/5aVj0KpVcurmkUc+3HJs=; b=KA+sAby4jBnxdGyCCLBSYtBGbp5wjQ4mSWR0iVKHeFeXwzcZpmeZdPq9gP9BUT/tTHYjAO bBNYvY9byHXrdQ+QWB5AgIqPkElcDqCD6f2fwBPMa6cf/0QRAa4d6YR0EpzcFN9LNHWmk8 CMgwJBhXrPTRiOlzv9Np29HyP7A673g= X-MC-Unique: cKyohpSJNH-dknVPVxmYiQ-1 From: marcandre.lureau@redhat.com To: qemu-devel@nongnu.org Subject: [PATCH 4/6] build-sys: remove no longer needed ROMS variable Date: Sat, 19 Sep 2020 00:47:57 +0400 Message-Id: <20200918204759.225810-5-marcandre.lureau@redhat.com> In-Reply-To: <20200918204759.225810-1-marcandre.lureau@redhat.com> References: <20200918204759.225810-1-marcandre.lureau@redhat.com> MIME-Version: 1.0 X-Scanned-By: MIMEDefang 2.79 on 10.5.11.12 Authentication-Results: relay.mimecast.com; auth=pass smtp.auth=CUSA124A263 smtp.mailfrom=marcandre.lureau@redhat.com X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Received-SPF: pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; envelope-from=qemu-devel-bounces+importer=patchew.org@nongnu.org; helo=lists.gnu.org; Received-SPF: pass client-ip=216.205.24.124; envelope-from=marcandre.lureau@redhat.com; helo=us-smtp-delivery-124.mimecast.com X-detected-operating-system: by eggs.gnu.org: First seen = 2020/09/18 01:32:10 X-ACL-Warn: Detected OS = Linux 2.2.x-3.x [generic] [fuzzy] X-Spam_score_int: -50 X-Spam_score: -5.1 X-Spam_bar: ----- X-Spam_report: (-5.1 / 5.0 requ) BAYES_00=-1.9, DKIMWL_WL_HIGH=-2.999, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, RCVD_IN_MSPIKE_H5=0.001, RCVD_IN_MSPIKE_WL=0.001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=unavailable autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Paolo Bonzini , qemu-s390x@nongnu.org, Thomas Huth , =?UTF-8?q?Marc-Andr=C3=A9=20Lureau?= Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org Sender: "Qemu-devel" X-ZohoMail-DKIM: fail (Header signature does not verify) From: Marc-Andr=C3=A9 Lureau Signed-off-by: Marc-Andr=C3=A9 Lureau --- Makefile | 9 --------- configure | 3 --- 2 files changed, 12 deletions(-) diff --git a/Makefile b/Makefile index 7c60b9dcb8..cb23123606 100644 --- a/Makefile +++ b/Makefile @@ -180,16 +180,7 @@ slirp/all: .git-submodule-status CC=3D"$(CC)" AR=3D"$(AR)" LD=3D"$(LD)" RANLIB=3D"$(RANLIB)" \ CFLAGS=3D"$(QEMU_CFLAGS) $(CFLAGS)" LDFLAGS=3D"$(QEMU_LDFLAGS)") =20 -ROM_DIRS =3D $(addprefix pc-bios/, $(ROMS)) -ROM_DIRS_RULES=3D$(foreach t, all clean, $(addsuffix /$(t), $(ROM_DIRS))) -# Only keep -O and -g cflags -.PHONY: $(ROM_DIRS_RULES) -$(ROM_DIRS_RULES): - $(call quiet-command,$(MAKE) $(SUBDIR_MAKEFLAGS) -C $(dir $@) V=3D"$(V)" = TARGET_DIR=3D"$(dir $@)" $(notdir $@),) - .PHONY: recurse-all recurse-clean -recurse-all: $(addsuffix /all, $(ROM_DIRS)) -recurse-clean: $(addsuffix /clean, $(ROM_DIRS)) =20 ###################################################################### =20 diff --git a/configure b/configure index 4e56edc70c..fa9b44328b 100755 --- a/configure +++ b/configure @@ -6441,8 +6441,6 @@ if test "$guest_agent_msi" =3D "yes"; then esac fi =20 -roms=3D - # Only build s390-ccw bios if we're on s390x and the compiler has -march= =3Dz900 if test "$cpu" =3D "s390x" ; then write_c_skeleton @@ -7397,7 +7395,6 @@ else QEMU_INCLUDES=3D"-iquote ${source_path}/tcg/${ARCH} $QEMU_INCLUDES" fi =20 -echo "ROMS=3D$roms" >> $config_host_mak echo "MAKE=3D$make" >> $config_host_mak echo "PYTHON=3D$python" >> $config_host_mak echo "SPHINX_BUILD=3D$sphinx_build" >> $config_host_mak --=20 2.26.2 From nobody Tue Apr 30 02:50:19 2024 Delivered-To: importer@patchew.org Authentication-Results: mx.zohomail.com; dkim=fail; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=fail(p=none dis=none) header.from=redhat.com ARC-Seal: i=1; a=rsa-sha256; t=1600463585; cv=none; d=zohomail.com; s=zohoarc; b=fVHzSznbE2/FhTK2eAOMUmjgIfWddhYLZdwd97P0K1nISN318SvijNKD49R17BPUsrDBw8LNa4kwh5/PwM2/N13ihNdi2MkCXsA2burmDSShsTa42yl3tn11EkrNMDxfDHl7/JKH4PVqGZaHgOgt0f5ww/zfsOxXXXg0zoSAgXQ= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1600463585; h=Content-Type:Content-Transfer-Encoding:Cc:Date:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:To; bh=y2xkPIiGLF7ORKyIunpyc83WIGvp5DV6GxTj2UktYvs=; b=jk1Ry/v6tPWruSu42gX8DYoy6iFh3mZD0Y1ssCEe+M5dwNK6CjZ4TplIwPIBjl6utRcZyvUgBg+lPN+sMQREefMbWVfIWvOItLNvnZLuqu+kiR0cJ+8mGo0nvC4m2OPtEg3IVaV6UHFqZGU7vNO4UzFRVzUBOiMrz9yZEKQFNZI= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=fail; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=fail header.from= (p=none dis=none) header.from= Return-Path: Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 16004635854131012.0440536677797; Fri, 18 Sep 2020 14:13:05 -0700 (PDT) Received: from localhost ([::1]:37828 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1kJNgm-0004yj-3Z for importer@patchew.org; Fri, 18 Sep 2020 17:13:04 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:48890) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1kJNJO-0003L4-PX for qemu-devel@nongnu.org; Fri, 18 Sep 2020 16:48:56 -0400 Received: from us-smtp-delivery-124.mimecast.com ([63.128.21.124]:25147) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.90_1) (envelope-from ) id 1kJNJJ-0006U5-3A for qemu-devel@nongnu.org; Fri, 18 Sep 2020 16:48:52 -0400 Received: from mimecast-mx01.redhat.com (mimecast-mx01.redhat.com [209.132.183.4]) (Using TLS) by relay.mimecast.com with ESMTP id us-mta-188-wJZFsArZMXK_D-WUzPQ93g-1; Fri, 18 Sep 2020 16:48:42 -0400 Received: from smtp.corp.redhat.com (int-mx07.intmail.prod.int.phx2.redhat.com [10.5.11.22]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx01.redhat.com (Postfix) with ESMTPS id 3CFC888EF2D; Fri, 18 Sep 2020 20:48:41 +0000 (UTC) Received: from localhost (unknown [10.36.110.14]) by smtp.corp.redhat.com (Postfix) with ESMTP id 39DA3100164C; Fri, 18 Sep 2020 20:48:39 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1600462124; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=y2xkPIiGLF7ORKyIunpyc83WIGvp5DV6GxTj2UktYvs=; b=M9Yhgxa+gwtklVxaDMamHzUM3nnzwJLt4zvD4hdrvZFWHcJwtkONO0xpFuWgmzWBVdsbqR Gn/TF5OV8+10PizzYgl8R4EFZzTe5eHjy7Ih8sgCJKpSr3XEw/u17dAGGxRjIS+U9z6RgN 7604wSmwsz3lEiP4rKpjpNfq1v80z/I= X-MC-Unique: wJZFsArZMXK_D-WUzPQ93g-1 From: marcandre.lureau@redhat.com To: qemu-devel@nongnu.org Subject: [PATCH 5/6] build-sys: remove recurse-* rules Date: Sat, 19 Sep 2020 00:47:58 +0400 Message-Id: <20200918204759.225810-6-marcandre.lureau@redhat.com> In-Reply-To: <20200918204759.225810-1-marcandre.lureau@redhat.com> References: <20200918204759.225810-1-marcandre.lureau@redhat.com> MIME-Version: 1.0 X-Scanned-By: MIMEDefang 2.84 on 10.5.11.22 Authentication-Results: relay.mimecast.com; auth=pass smtp.auth=CUSA124A263 smtp.mailfrom=marcandre.lureau@redhat.com X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Received-SPF: pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; envelope-from=qemu-devel-bounces+importer=patchew.org@nongnu.org; helo=lists.gnu.org; Received-SPF: pass client-ip=63.128.21.124; envelope-from=marcandre.lureau@redhat.com; helo=us-smtp-delivery-124.mimecast.com X-detected-operating-system: by eggs.gnu.org: First seen = 2020/09/18 00:20:40 X-ACL-Warn: Detected OS = Linux 2.2.x-3.x [generic] [fuzzy] X-Spam_score_int: -50 X-Spam_score: -5.1 X-Spam_bar: ----- X-Spam_report: (-5.1 / 5.0 requ) BAYES_00=-1.9, DKIMWL_WL_HIGH=-2.999, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, RCVD_IN_MSPIKE_H5=0.001, RCVD_IN_MSPIKE_WL=0.001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=unavailable autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Paolo Bonzini , qemu-s390x@nongnu.org, Thomas Huth , =?UTF-8?q?Marc-Andr=C3=A9=20Lureau?= Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org Sender: "Qemu-devel" X-ZohoMail-DKIM: fail (Header signature does not verify) From: Marc-Andr=C3=A9 Lureau Signed-off-by: Marc-Andr=C3=A9 Lureau --- Makefile | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/Makefile b/Makefile index cb23123606..4728fcf1bd 100644 --- a/Makefile +++ b/Makefile @@ -135,13 +135,12 @@ Makefile: ; configure: ; =20 .PHONY: all clean distclean install \ - recurse-all dist msi FORCE + dist msi FORCE =20 SUBDIR_MAKEFLAGS=3D$(if $(V),,--no-print-directory --quiet) =20 include $(SRC_PATH)/tests/Makefile.include =20 -all: recurse-all Makefile: $(addsuffix /all, $(SUBDIRS)) =20 # LIBFDT_lib=3D"": avoid breaking existing trees with objects requiring -f= PIC @@ -180,11 +179,9 @@ slirp/all: .git-submodule-status CC=3D"$(CC)" AR=3D"$(AR)" LD=3D"$(LD)" RANLIB=3D"$(RANLIB)" \ CFLAGS=3D"$(QEMU_CFLAGS) $(CFLAGS)" LDFLAGS=3D"$(QEMU_LDFLAGS)") =20 -.PHONY: recurse-all recurse-clean - ###################################################################### =20 -clean: recurse-clean ninja-clean clean-ctlist +clean: ninja-clean clean-ctlist if test -f ninjatool; then ./ninjatool $(if $(V),-v,) -t clean; fi # avoid old build problems by removing potentially incorrect old files rm -f config.mak op-i386.h opc-i386.h gen-op-i386.h op-arm.h opc-arm.h ge= n-op-arm.h --=20 2.26.2 From nobody Tue Apr 30 02:50:19 2024 Delivered-To: importer@patchew.org Authentication-Results: mx.zohomail.com; dkim=fail; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=fail(p=none dis=none) header.from=redhat.com ARC-Seal: i=1; a=rsa-sha256; t=1600466628; cv=none; d=zohomail.com; s=zohoarc; b=Xl8YMg0nfjAlVg26OuWHByihwH5yV/p4zCu5jw+91N5lDVdY/GPyZhaa/sZnlPFek/NkOvPTbj6YTZWqjgpKqIaXtG4Itch/Ys0LO2VXd4TbWHIlwg27GNnQQ3BDr3xpREahgFeqHSEk4lhl5I/4BSQSndWyHOTkr4wGEqAR7yc= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1600466628; h=Content-Type:Content-Transfer-Encoding:Cc:Date:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:To; bh=ItsJU/Dhvavx+vu0tFfDepkCUg9sXvnudkLYoCPPh+Q=; b=e1BY9KQxC9mPuetqQbC2I8+FtYpOrsyLORnGNvUb6TaGpdO43VlOlk9zOnnxK7Mtxqc6ecSgbXRkw1t9h8oWEBPDfK02VbejXej63UMExYaqH5OU2zyMTcMntlg+fQJKeUPeNmynRyygrzqLF4ahUA4ImmfmITIy8Z7vTpHhYkU= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=fail; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=fail header.from= (p=none dis=none) header.from= Return-Path: Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 1600466628389358.25801382389443; Fri, 18 Sep 2020 15:03:48 -0700 (PDT) Received: from localhost ([::1]:49726 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1kJOTq-000333-Ns for importer@patchew.org; Fri, 18 Sep 2020 18:03:46 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:48904) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1kJNJR-0003Lh-GN for qemu-devel@nongnu.org; Fri, 18 Sep 2020 16:49:03 -0400 Received: from us-smtp-delivery-124.mimecast.com ([63.128.21.124]:27270) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.90_1) (envelope-from ) id 1kJNJO-0006Uf-Oe for qemu-devel@nongnu.org; Fri, 18 Sep 2020 16:48:57 -0400 Received: from mimecast-mx01.redhat.com (mimecast-mx01.redhat.com [209.132.183.4]) (Using TLS) by relay.mimecast.com with ESMTP id us-mta-142-5-ujRE9BPAqJ6X8bKDziHQ-1; Fri, 18 Sep 2020 16:48:49 -0400 Received: from smtp.corp.redhat.com (int-mx04.intmail.prod.int.phx2.redhat.com [10.5.11.14]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx01.redhat.com (Postfix) with ESMTPS id BFB11805EE2; Fri, 18 Sep 2020 20:48:48 +0000 (UTC) Received: from localhost (unknown [10.36.110.14]) by smtp.corp.redhat.com (Postfix) with ESMTP id 3E70D5D9E4; Fri, 18 Sep 2020 20:48:44 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1600462133; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=ItsJU/Dhvavx+vu0tFfDepkCUg9sXvnudkLYoCPPh+Q=; b=L7+bPsNpMV+gWzta0QJDLygM2J44JOQSeDf5yBwtHb6ZD3HGTgI7Wb9ASZ/yfQx4X1FgdM DySz0nOz0T0HnaeZh/twpNfOST1RfduDiQ9MZy+p73+uMP/TgeT6D+su2yCmTPayQyRMcN knLNrDEwLgZGhaj/g+cP9quxt5DSlYc= X-MC-Unique: 5-ujRE9BPAqJ6X8bKDziHQ-1 From: marcandre.lureau@redhat.com To: qemu-devel@nongnu.org Subject: [PATCH 6/6] meson: replace pc-bios/Makefile Date: Sat, 19 Sep 2020 00:47:59 +0400 Message-Id: <20200918204759.225810-7-marcandre.lureau@redhat.com> In-Reply-To: <20200918204759.225810-1-marcandre.lureau@redhat.com> References: <20200918204759.225810-1-marcandre.lureau@redhat.com> MIME-Version: 1.0 X-Scanned-By: MIMEDefang 2.79 on 10.5.11.14 Authentication-Results: relay.mimecast.com; auth=pass smtp.auth=CUSA124A263 smtp.mailfrom=marcandre.lureau@redhat.com X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Received-SPF: pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; envelope-from=qemu-devel-bounces+importer=patchew.org@nongnu.org; helo=lists.gnu.org; Received-SPF: pass client-ip=63.128.21.124; envelope-from=marcandre.lureau@redhat.com; helo=us-smtp-delivery-124.mimecast.com X-detected-operating-system: by eggs.gnu.org: First seen = 2020/09/18 00:20:40 X-ACL-Warn: Detected OS = Linux 2.2.x-3.x [generic] [fuzzy] X-Spam_score_int: -50 X-Spam_score: -5.1 X-Spam_bar: ----- X-Spam_report: (-5.1 / 5.0 requ) BAYES_00=-1.9, DKIMWL_WL_HIGH=-2.999, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, RCVD_IN_MSPIKE_H5=0.001, RCVD_IN_MSPIKE_WL=0.001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=unavailable autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Paolo Bonzini , qemu-s390x@nongnu.org, Thomas Huth , =?UTF-8?q?Marc-Andr=C3=A9=20Lureau?= Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org Sender: "Qemu-devel" X-ZohoMail-DKIM: fail (Header signature does not verify) From: Marc-Andr=C3=A9 Lureau Add an alias target "update-dtb" to recompile the device-tree "sources" to the "blob" format. Signed-off-by: Marc-Andr=C3=A9 Lureau --- pc-bios/Makefile | 19 ------------------- pc-bios/meson.build | 12 ++++++++++++ 2 files changed, 12 insertions(+), 19 deletions(-) delete mode 100644 pc-bios/Makefile diff --git a/pc-bios/Makefile b/pc-bios/Makefile deleted file mode 100644 index 315288df84..0000000000 --- a/pc-bios/Makefile +++ /dev/null @@ -1,19 +0,0 @@ -# -# NOTE: only compilable with x86 cross compile tools -# -include ../config-host.mak - -DEFINES=3D - -TARGETS=3D - -all: $(TARGETS) - -%.o: %.S - $(CC) $(DEFINES) -c -o $@ $< - -%.dtb: %.dts - dtc -I dts -O dtb -o $@ $< - -clean: - rm -f $(TARGETS) *.o *~ diff --git a/pc-bios/meson.build b/pc-bios/meson.build index d25585ca97..f004df7a4d 100644 --- a/pc-bios/meson.build +++ b/pc-bios/meson.build @@ -92,6 +92,18 @@ endif subdir('descriptors') subdir('keymaps') =20 +dtc =3D find_program('dtc', required: false) +if dtc.found() + t =3D [] + foreach f: ['bamboo.dts', 'canyonlands.dts', 'petalogix-ml605.dts', 'pet= alogix-s3adsp1800.dts'] + t +=3D custom_target(f, + input: f, + output: '@BASENAME@' + '.dtb', + command: [dtc, '-I', 'dts', '-O', 'dtb', '-o', '@OU= TPUT@', '@INPUT@']) + endforeach + alias_target('update-dtb', t) +endif + if host_machine.cpu_family() in ['x86', 'x86_64'] subproject('optionrom') endif --=20 2.26.2