Include some compilation fixes for Debian Lenny distribution (circa 2008); these will probably break compilation on more recent systems

This commit is contained in:
Michele Bini 2014-02-12 17:28:52 +01:00
parent a6fc36085e
commit faed393afb
4 changed files with 32 additions and 11 deletions

View File

@ -5,12 +5,7 @@
#ifndef _IPT_CONNTRACK_H #ifndef _IPT_CONNTRACK_H
#define _IPT_CONNTRACK_H #define _IPT_CONNTRACK_H
#if 0 #include <linux/netfilter_ipv4/ipt_conntrack.h>
#include <linux/netfilter_ipv4/ip_conntrack.h>
#else
#include <linux/netfilter/nf_conntrack_common.h>
#include <linux/netfilter/nf_conntrack_tuple_common.h>
#endif
/* backwards compatibility crap. only exists in userspace - HW */ /* backwards compatibility crap. only exists in userspace - HW */
#include <linux/version.h> #include <linux/version.h>
@ -27,6 +22,10 @@
#define IP_CT_DIR_MAX 2 #define IP_CT_DIR_MAX 2
#endif #endif
#ifndef IP_CT_DIR_MAX
#define IP_CT_DIR_MAX 2
#endif
#define IPT_CONNTRACK_STATE_BIT(ctinfo) (1 << ((ctinfo)%IP_CT_IS_REPLY+1)) #define IPT_CONNTRACK_STATE_BIT(ctinfo) (1 << ((ctinfo)%IP_CT_IS_REPLY+1))
#define IPT_CONNTRACK_STATE_INVALID (1 << 0) #define IPT_CONNTRACK_STATE_INVALID (1 << 0)

View File

@ -59,14 +59,12 @@ static const char *hooknames[]
#endif #endif
}; };
#if 0
/* Convenience structures */ /* Convenience structures */
struct ipt_error_target struct ipt_error_target
{ {
STRUCT_ENTRY_TARGET t; STRUCT_ENTRY_TARGET t;
char error[TABLE_MAXNAMELEN]; char error[TABLE_MAXNAMELEN];
}; };
#endif
struct chain_head; struct chain_head;
struct rule_head; struct rule_head;

View File

@ -1,11 +1,37 @@
#ifndef MARK_H #ifndef MARK_H
#define MARK_H #define MARK_H
/* Original inclusions from netsukuku 0.0.9b */
#if 0
#include "libiptc/libiptc.h" #include "libiptc/libiptc.h"
#include <linux/netfilter/nf_conntrack_common.h> #include <linux/netfilter_ipv4/ip_conntrack.h>
#include <linux/netfilter_ipv4/ip_conntrack_tuple.h>
#include "libiptc/ipt_conntrack.h" #include "libiptc/ipt_conntrack.h"
#include "libiptc/ipt_connmark.h" #include "libiptc/ipt_connmark.h"
#include "libiptc/ipt_CONNMARK.h" #include "libiptc/ipt_CONNMARK.h"
#endif
#if 1
#include "libiptc/libiptc.h"
#if 1
#include <linux/netfilter/nf_conntrack_common.h>
#endif
#if 0
#include <linux/netfilter_ipv4/ipt_conntrack_tuple.h>
#endif
#include "libiptc/ipt_conntrack.h"
#include "libiptc/ipt_connmark.h"
#include "libiptc/ipt_CONNMARK.h"
#endif
/* 2010 fixes for debian package */
#if 0
#include "libiptc/libiptc.h"
#include <linux/netfilter/nf_conntrack_common.h>
#include <linux/netfilter_ipv4/ipt_conntrack.h>
#include <linux/netfilter_ipv4/ipt_connmark.h>
#include <linux/netfilter_ipv4/ipt_CONNMARK.h>
#endif
#define MANGLE_TABLE "mangle" #define MANGLE_TABLE "mangle"
#define FILTER_TABLE "filter" #define FILTER_TABLE "filter"

View File

@ -1,5 +1,3 @@
#include <netinet/in.h>
#include "includes.h" #include "includes.h"
#include "ntkresolv.h" #include "ntkresolv.h"