openwrt 內核編譯紀要

錯誤1:error: linux/netfilter/xt_DSCP.h No such file or directory

解決辦法:自己編寫xt_DSCP.h部分代碼

內容如下:

#ifndef _XT_DSCP_TARGET_H

#define _XT_DSCP_TARGET_H

#include <linux/netfilter/xt_dscp.h>

#include <linux/types.h>/* target info */

struct xt_DSCP_info {  

__u8 dscp;};

struct xt_tos_target_info {  

__u8 tos_value;  

__u8 tos_mask;};

#endif /* _XT_DSCP_TARGET_H */

錯誤2:linux/netfilter/xt_mark.h No such file or directory

解決辦法:自己編寫xt_mark.h 部分代碼

內容如下:

1 #ifndef _XT_MARK_H
2 #define _XT_MARK_H
3 
4 #include <linux/types.h>
5 
6 structxt_mark_tginfo2 {
7  __u32 mark, mask;
8 };
9 
11  __u32 mark, mask;
12  __u8 invert;
13 };
14 
15 #endif/*_XT_MARK_H*/

錯誤3:linux/netfilter/xt_connmark.h:No such file or directory

解決辦法:自己編寫xt_connmark.h

1 #ifndef _XT_CONNMARK_H
2 #define _XT_CONNMARK_H
3 
4 #include <linux/types.h>
5 
6 /* Copyright (C) 2002,2004 MARA Systems AB <http://www.marasystems.com>
7  * by Henrik Nordstrom <[email protected]>
8  *
9  * This program is free software; you can redistribute it and/or modify
10  * it under the terms of the GNU General Public License as published by
11  * the Free Software Foundation; either version 2 of the License, or
12  * (at your option) any later version.
13  */
14 
15 enum {
19 };
20 
23  __u8 mode;
24 };
25 
27  __u32 mark, mask;
28  __u8 invert;
29 };
30 
31 #endif/*_XT_CONNMARK_H*/

錯誤4:No rule to make target 'net/netfilter/xt_TCPMSS.c',needed by 'net/netfilter/xt_TCPMSS.o'

在谷歌上找到了源嗎,添加進去https://android.googlesource.com/kernel/common/+/051966c0c644a1c96092d4206e00704ade813c9a/net/netfilter/xt_TCPMSS.c



錯誤5:

arch/arm/boot/dts/omap2.dtsi:11:35: fatal error: dt-bindings/gpio/gpio.h: No such file or directory
compilation terminated.
解決辦法:
$ cd arch/arm/boot/dts/include/
$ rm dt-bindings
$ ln -s ../../../../../include/dt-bindings .

..........................................................................................................................................................................................................................................................







發表評論
所有評論
還沒有人評論,想成為第一個評論的人麼? 請在上方評論欄輸入並且點擊發布.
相關文章