From patchwork Mon Mar 16 16:15:26 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Laurent Vivier X-Patchwork-Id: 1255662 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=nongnu.org (client-ip=209.51.188.17; helo=lists.gnu.org; envelope-from=qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org; receiver=) Authentication-Results: ozlabs.org; dmarc=none (p=none dis=none) header.from=vivier.eu Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 48h2sW2dFNz9sRR for ; Tue, 17 Mar 2020 04:11:59 +1100 (AEDT) Received: from localhost ([::1]:43237 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1jDtHR-0007hg-8H for incoming@patchwork.ozlabs.org; Mon, 16 Mar 2020 13:11:57 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:41379) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1jDsQI-0008Ck-Av for qemu-devel@nongnu.org; Mon, 16 Mar 2020 12:17:04 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1jDsQG-0005is-9k for qemu-devel@nongnu.org; Mon, 16 Mar 2020 12:17:02 -0400 Received: from mout.kundenserver.de ([212.227.126.135]:58777) by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1jDsQF-0005YK-U5 for qemu-devel@nongnu.org; Mon, 16 Mar 2020 12:17:00 -0400 Received: from localhost.localdomain ([82.252.135.106]) by mrelayeu.kundenserver.de (mreue012 [212.227.15.167]) with ESMTPSA (Nemesis) id 1MGgRW-1j8uKv3Fnm-00Dnbh; Mon, 16 Mar 2020 17:16:20 +0100 From: Laurent Vivier To: qemu-devel@nongnu.org Subject: [PULL 14/38] linux-user: introduce parameters to generate syscall_nr.h Date: Mon, 16 Mar 2020 17:15:26 +0100 Message-Id: <20200316161550.336150-15-laurent@vivier.eu> X-Mailer: git-send-email 2.24.1 In-Reply-To: <20200316161550.336150-1-laurent@vivier.eu> References: <20200316161550.336150-1-laurent@vivier.eu> MIME-Version: 1.0 X-Provags-ID: V03:K1:04D9jpp5Jxz6iBsjonAr6GKhTALGknq+EQKLql4B8xYydCedLSZ 1JkDexlQa3569QLopFe8p8kHuKA5oUjj0L5tU6ghUMUNnCUd6p2fYbR2rZg8vuwL+fi4J2Q 6/OPdabpoA/ncalBSgbT/i0wT44Np/wtVmkY+sV9QFFDUcVSTFdeRzltwqk6nAfQ7S/Udhy UJGXi4ggZikMNAKWm4rwQ== X-UI-Out-Filterresults: notjunk:1; V03:K0:VYX4WaDV9WU=:cOGmEbrtQ9D7cIS/kXJ/Im 43IbGSs5h1QQfDnSUMdZGSsk0hfrkXPvbazi6a5oiv+GcW4lM9yi/rGOrOO2oyG97fZ5zev2/ uuHA7TUjLJZ0ZRG6ahwM1OI2UkP1CPMJ1tuiaR3CTs+Zpl+uGL7cagt+/sH/GtO5nP42B9rYg qotLajJkOD0Vi77Zvp9RDGaXUamnL9bWX9IERCAKDEgd8HlQXadxU6BREwKj2CiYpQ5QuYbim nXZEvcY9I2NUektozkQegjxXbbBmT3RpdDhlbCRQxyYKW6p7YJ1RT1WzIMi87Yzvud1TqFicG sGTCBm9sac7rNZc9H6lnPeFBSYSp/FhlgsecZSArK7hQXuO7yBU71i06w8YlTAbrMRHkiOwZp /thX/uCnD3QMKKFk1hDTbW59Px/SMuMrHpQ561dploxy+yLZoezGcqPnOlsUo+eRK/RBPWCg5 P4AZXNDDMGoCBBP0lhaOUTRUTh2kkxNV8IYdJPbczku1sGC1koXI1uedJuntb72plgQWbfqBH Tkeyyspgwz8xzQN/cSm+C4Ks1ZpO7qL5vf9vOG5DLqJqgkrkNvDBCJj4uH+pNwbbaw1Tre+y3 IH2GOYqmKzqxMGPme3TFjnf7zRJzNZezuGfEa7MOyAXxswBtOH440F2Nxh2VCadrb8j1yF7+x hvAAQ6F5ZaB9z9zkQRGWoP01A762Ew5/SbjNOSFfWSnmVJ/zvW+WbxfiJfg2oRdcrWxU0FGb6 6faZSHXZ7RbwFd/svNpZxoV39IQIVNSiBgrZKNHxCPNirz6Tbh7sn9q514x7fCzu9SEpWVTOc Cvc0YJRLQ/MHBoaDMFIGYd4/1XFJKm+TzdY3U7+YiTyfqjcq1l4iBDcUVzr4YuoigzCn77w X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 212.227.126.135 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: Taylor Simpson , Riku Voipio , Richard Henderson , Laurent Vivier Errors-To: qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org Sender: "Qemu-devel" This will be used when we'll import syscall.tbl from the kernel Add a script to remove all the dependencies to syscall_nr.h that point to source directory and not to the build directory. The list of arch will be update while the generated files are added. Signed-off-by: Laurent Vivier Reviewed-by: Richard Henderson Reviewed-by: Taylor Simpson Message-Id: <20200310103403.3284090-2-laurent@vivier.eu> Signed-off-by: Laurent Vivier --- Makefile.target | 3 ++- configure | 14 ++++++++++++++ 2 files changed, 16 insertions(+), 1 deletion(-) diff --git a/Makefile.target b/Makefile.target index 2d43dc586a10..cb3a6fa5e704 100644 --- a/Makefile.target +++ b/Makefile.target @@ -128,7 +128,8 @@ ifdef CONFIG_LINUX_USER QEMU_CFLAGS+=-I$(SRC_PATH)/linux-user/$(TARGET_ABI_DIR) \ -I$(SRC_PATH)/linux-user/host/$(ARCH) \ - -I$(SRC_PATH)/linux-user + -I$(SRC_PATH)/linux-user \ + -Ilinux-user/$(TARGET_ABI_DIR) obj-y += linux-user/ obj-y += gdbstub.o thunk.o diff --git a/configure b/configure index cbf864bff1be..39e55a1ecf06 100755 --- a/configure +++ b/configure @@ -1887,6 +1887,17 @@ fi # Remove old dependency files to make sure that they get properly regenerated rm -f */config-devices.mak.d +# Remove syscall_nr.h to be sure they will be regenerated in the build +# directory, not in the source directory +for arch in ; do + # remove the file if it has been generated in the source directory + rm -f "${source_path}/linux-user/${arch}/syscall_nr.h" + # remove the dependency files + find . -name "*.d" \ + -exec grep -q "${source_path}/linux-user/${arch}/syscall_nr.h" {} \; \ + -exec rm {} \; +done + if test -z "$python" then error_exit "Python not found. Use --python=/path/to/python" @@ -7931,6 +7942,9 @@ echo "TARGET_ABI_DIR=$TARGET_ABI_DIR" >> $config_target_mak if [ "$HOST_VARIANT_DIR" != "" ]; then echo "HOST_VARIANT_DIR=$HOST_VARIANT_DIR" >> $config_target_mak fi +if [ "$TARGET_SYSTBL_ABI" != "" ]; then + echo "TARGET_SYSTBL_ABI=$TARGET_SYSTBL_ABI" >> $config_target_mak +fi if supported_xen_target $target; then echo "CONFIG_XEN=y" >> $config_target_mak