]> git.ipfire.org Git - thirdparty/linux.git/commitdiff
objtool: Include libsubcmd headers directly from source tree
authorJosh Poimboeuf <jpoimboe@kernel.org>
Sun, 12 Apr 2026 17:59:42 +0000 (10:59 -0700)
committerJosh Poimboeuf <jpoimboe@kernel.org>
Tue, 5 May 2026 04:16:04 +0000 (21:16 -0700)
Instead of installing libsubcmd headers to a build output directory and
including from there, include directly from tools/lib/ where they
already exist.  This fixes clangd indexing which otherwise can't find
libsubcmd headers.

Acked-by: Song Liu <song@kernel.org>
Signed-off-by: Josh Poimboeuf <jpoimboe@kernel.org>
tools/objtool/Makefile

index b71d1886022e9b3d9fde52bf73bd502aa20d173e..a4484fd22a96d1ce98dbfb827174d2c593734a91 100644 (file)
@@ -58,7 +58,7 @@ INCLUDES := -I$(srctree)/tools/include \
            -I$(srctree)/tools/arch/$(SRCARCH)/include  \
            -I$(srctree)/tools/objtool/include \
            -I$(srctree)/tools/objtool/arch/$(SRCARCH)/include \
-           -I$(LIBSUBCMD_OUTPUT)/include
+           -I$(srctree)/tools/lib
 
 OBJTOOL_CFLAGS  := -std=gnu11 -fomit-frame-pointer -O2 -g $(WARNINGS)  \
                   $(INCLUDES) $(LIBELF_FLAGS) $(LIBXXHASH_CFLAGS) $(HOSTCFLAGS)
@@ -135,7 +135,7 @@ $(LIBSUBCMD): fixdep $(LIBSUBCMD_OUTPUT) FORCE
        $(Q)$(MAKE) -C $(LIBSUBCMD_DIR) O=$(LIBSUBCMD_OUTPUT) \
                DESTDIR=$(LIBSUBCMD_OUTPUT) prefix= subdir= \
                $(HOST_OVERRIDES) EXTRA_CFLAGS="$(OBJTOOL_CFLAGS)" \
-               $@ install_headers
+               $@
 
 $(LIBSUBCMD)-clean:
        $(call QUIET_CLEAN, libsubcmd)