bpf.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] bpfilter: Fix build error with CONFIG_BPFILTER_UMH
@ 2020-10-14  9:17 YueHaibing
  2020-10-15 16:37 ` Jakub Kicinski
  0 siblings, 1 reply; 8+ messages in thread
From: YueHaibing @ 2020-10-14  9:17 UTC (permalink / raw)
  To: davem, kuba, ast, daniel, kafai, songliubraving, yhs, andrii,
	john.fastabend, kpsingh, masahiroy
  Cc: netdev, bpf, linux-kernel, YueHaibing

IF CONFIG_BPFILTER_UMH is set, building fails:

In file included from /usr/include/sys/socket.h:33:0,
                 from net/bpfilter/main.c:6:
/usr/include/bits/socket.h:390:10: fatal error: asm/socket.h: No such file or directory
 #include <asm/socket.h>
          ^~~~~~~~~~~~~~
compilation terminated.
scripts/Makefile.userprogs:43: recipe for target 'net/bpfilter/main.o' failed
make[2]: *** [net/bpfilter/main.o] Error 1

Add missing include path to fix this.

Signed-off-by: YueHaibing <yuehaibing@huawei.com>
---
 net/bpfilter/Makefile | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/net/bpfilter/Makefile b/net/bpfilter/Makefile
index cdac82b8c53a..389ea76ccc0b 100644
--- a/net/bpfilter/Makefile
+++ b/net/bpfilter/Makefile
@@ -5,7 +5,7 @@
 
 userprogs := bpfilter_umh
 bpfilter_umh-objs := main.o
-userccflags += -I $(srctree)/tools/include/ -I $(srctree)/tools/include/uapi
+userccflags += -I $(srctree)/tools/include/ -I $(srctree)/tools/include/uapi -I usr/include/
 
 ifeq ($(CONFIG_BPFILTER_UMH), y)
 # builtin bpfilter_umh should be linked with -static
-- 
2.17.1


^ permalink raw reply related	[flat|nested] 8+ messages in thread

end of thread, other threads:[~2020-10-16  6:19 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-10-14  9:17 [PATCH] bpfilter: Fix build error with CONFIG_BPFILTER_UMH YueHaibing
2020-10-15 16:37 ` Jakub Kicinski
2020-10-15 18:53   ` Alexei Starovoitov
2020-10-15 18:56     ` Jakub Kicinski
2020-10-15 19:03       ` Alexei Starovoitov
2020-10-15 19:26         ` Jakub Kicinski
2020-10-15 19:57           ` Alexei Starovoitov
2020-10-16  6:18             ` Yuehaibing

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).