From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mail-wr1-f52.google.com (mail-wr1-f52.google.com [209.85.221.52]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id B8810168 for ; Sat, 8 Jan 2022 11:08:29 +0000 (UTC) Received: by mail-wr1-f52.google.com with SMTP id l25so5314211wrb.13 for ; Sat, 08 Jan 2022 03:08:29 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=sender:date:from:to:cc:subject:message-id:references:mime-version :content-disposition:in-reply-to; bh=QEd7jShQk1ml/OyAi/kpMudTLo3rO1TWVpy7f9K8afc=; b=bMgpN08rni6AurnSOUKC9hTpgCbtphQymgTmu+WqvnMnSiD88yJYICu51fRcP6Q5LU ZeLmWdmsQcj71iv//LrobynxxsVgN88HwmnvHu9ZuK744sikFEKVvoCpGe/gESYJflAg 3kZK/W9LumTPVAgLJ9xK40y4MoYEZuepKrzS9SYbfuwk+JKIY8LeoRPDiuIdD6p7y4i/ MFnsXgM9McX3pHsHZ0TcRLdQOuSD8GYoq+1zsVGNifB7vkpvKdMHIPApQ5MkGuiNnh6v L+9lOoTJi4+15cvANwgqCloJQPRUwY5iE3oq3tBfdZmKZN/O5iYZ1EvXWtEpX7bzQ3A7 3IwA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:sender:date:from:to:cc:subject:message-id :references:mime-version:content-disposition:in-reply-to; bh=QEd7jShQk1ml/OyAi/kpMudTLo3rO1TWVpy7f9K8afc=; b=sw0MDRpsyYmI8rOxb4/CQSmdNh9Nd28JKex/EO/ksS8xXrjDsOQaLqS53wFsEGoX3W HC2ndbtPEgENBrnemMtkr9CWsyN/6uvvXcVeBjCRvWCzza7YzFoxMxwBUZXtCmILXObJ vGyVWVdMBcATHGvsfLk5lO6ZvlFQFh0cH9hCYPf//Kwgi3U3jUBhGhvFiL4Alp4IlJd1 O0POp3Q2wexWY16If+Y6DlJE53HIK+mWbmvjJGj4opOWLOkivMR/o44UoM9qqVGySEmX txMMDEvboXXAwAfTsxWyi94Q+VRuUsxzVgAGZX0ZR5kagigpEpCaNBW2EHpG2TQMfyv+ 6FnA== X-Gm-Message-State: AOAM530c+EYICV6WNvOtIO0CxY/GU420Dcuhn8KL68uaXigc2kf3e39W Kus/CmI1plEAqk6bJk8Ev8E= X-Google-Smtp-Source: ABdhPJwnsz6GcODYiRzSMmaPUkZdoCsUYOGKtkSZsehdoKS7bUE4455GcXP3luYqUcXtqbLpkH0DPA== X-Received: by 2002:a5d:53c2:: with SMTP id a2mr13050516wrw.154.1641640107930; Sat, 08 Jan 2022 03:08:27 -0800 (PST) Received: from gmail.com (84-236-113-171.pool.digikabel.hu. [84.236.113.171]) by smtp.gmail.com with ESMTPSA id m6sm1535455wrx.36.2022.01.08.03.08.26 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 08 Jan 2022 03:08:27 -0800 (PST) Sender: Ingo Molnar Date: Sat, 8 Jan 2022 12:08:24 +0100 From: Ingo Molnar To: Nathan Chancellor Cc: Linus Torvalds , linux-kernel@vger.kernel.org, linux-arch@vger.kernel.org, Andrew Morton , Peter Zijlstra , Thomas Gleixner , Greg Kroah-Hartman , "David S. Miller" , Ard Biesheuvel , Josh Poimboeuf , Jonathan Corbet , Al Viro , llvm@lists.linux.dev Subject: [PATCH] FIX: headers/deps: uapi/headers: Create usr/include/uapi symbolic link Message-ID: References: Precedence: bulk X-Mailing-List: llvm@lists.linux.dev List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: * Nathan Chancellor wrote: > 2. Build failures with CONFIG_UAPI_HEADER_TEST=y and O=... > > This was originally reproduced with allmodconfig but this is a simpler > reproducer I think. > > $ make -skj"$(nproc)" ARCH=x86_64 O=.build/x86_64 defconfig > > $ scripts/config --file .build/x86_64/.config -e HEADERS_INSTALL -e UAPI_HEADER_TEST > > $ make -skj"$(nproc)" ARCH=x86_64 O=.build/x86_64 olddefconfig usr/ The simplified & scripted reproducer is very useful, thanks a ton! > In file included from : > ./usr/include/linux/rds.h:38:10: fatal error: uapi/linux/sockios.h: No such file or directory > 38 | #include > | ^~~~~~~~~~~~~~~~~~~~~~ > compilation terminated. > make[4]: *** [/home/nathan/cbl/src/linux-fast-headers/usr/include/Makefile:106: usr/include/linux/rds.hdrtest] Error 1 > In file included from ./usr/include/linux/qrtr.h:5, > from : > ./usr/include/linux/socket.h:5:10: fatal error: uapi/linux/socket_types.h: No such file or directory > 5 | #include > | ^~~~~~~~~~~~~~~~~~~~~~~~~~~ > compilation terminated. > In file included from ./usr/include/linux/in.h:24, > from ./usr/include/linux/nfs_mount.h:12, > from : > ./usr/include/linux/socket.h:5:10: fatal error: uapi/linux/socket_types.h: No such file or directory > 5 | #include > | ^~~~~~~~~~~~~~~~~~~~~~~~~~~ > compilation terminated. > make[4]: *** [/home/nathan/cbl/src/linux-fast-headers/usr/include/Makefile:106: usr/include/linux/qrtr.hdrtest] Error 1 > make[4]: *** [/home/nathan/cbl/src/linux-fast-headers/usr/include/Makefile:106: usr/include/linux/nfs_mount.hdrtest] Error 1 > ... > > I don't see this when just building in the tree. I am guessing that > commit f989e243f1f4 ("headers/deps: uapi/headers: Create > usr/include/uapi symbolic link") needs to account for this? Yeah. Here's my second attempt that creates the symlink as the header-install make process, as it should - also pushed out into sched/headers. (My Makefile-fu isn't overly powerful though, so this is just an attempt.) This fix will be backmerged into f989e243f1f4 in -v2. Thanks, Ingo =========================> From: Ingo Molnar Date: Sat, 8 Jan 2022 12:05:57 +0100 Subject: [PATCH] FIX: f989e243f1f4 headers/deps: uapi/headers: Create usr/include/uapi symbolic link --- scripts/Makefile.headersinst | 3 +++ usr/include/uapi | 1 - 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/scripts/Makefile.headersinst b/scripts/Makefile.headersinst index 029d85bb0b23..8ac831458143 100644 --- a/scripts/Makefile.headersinst +++ b/scripts/Makefile.headersinst @@ -78,6 +78,9 @@ existing-headers := $(filter $(old-headers), $(all-headers)) -include $(foreach f,$(existing-headers),$(dir $(f)).$(notdir $(f)).cmd) +# link the namespace: +LINK := $(shell ln -sf ../include $(objtree)/$(dst)/uapi) + PHONY += FORCE FORCE: diff --git a/usr/include/uapi b/usr/include/uapi deleted file mode 120000 index f5030fe88998..000000000000 --- a/usr/include/uapi +++ /dev/null @@ -1 +0,0 @@ -../include \ No newline at end of file