aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--pfinet/linux-src/include/net/route.h3
-rw-r--r--pfinet/pfinet.h7
-rw-r--r--pfinet/route.h42
3 files changed, 9 insertions, 43 deletions
diff --git a/pfinet/linux-src/include/net/route.h b/pfinet/linux-src/include/net/route.h
index 40aabdf6..e9ca2fee 100644
--- a/pfinet/linux-src/include/net/route.h
+++ b/pfinet/linux-src/include/net/route.h
@@ -20,6 +20,9 @@
* as published by the Free Software Foundation; either version
* 2 of the License, or (at your option) any later version.
*/
+
+#include_next <net/route.h>
+
#ifndef _ROUTE_H
#define _ROUTE_H
diff --git a/pfinet/pfinet.h b/pfinet/pfinet.h
index f8a1dd8d..df8da526 100644
--- a/pfinet/pfinet.h
+++ b/pfinet/pfinet.h
@@ -29,7 +29,12 @@
#include <sys/mman.h>
#include <sys/socket.h>
#include <pthread.h>
-#include "route.h"
+
+/* Unfortunately the Linux source also uses <net/route.h>.
+ * Here we want the glibc-provided one only */
+#define _ROUTE_H
+#include <net/route.h>
+#undef _ROUTE_H
extern pthread_mutex_t global_lock;
extern pthread_mutex_t net_bh_lock;
diff --git a/pfinet/route.h b/pfinet/route.h
deleted file mode 100644
index 00beb6c1..00000000
--- a/pfinet/route.h
+++ /dev/null
@@ -1,42 +0,0 @@
-/*
- Copyright (C) 2022 Free Software Foundation, Inc.
-
- This file is part of the GNU Hurd.
-
- The GNU Hurd is free software; you can redistribute it and/or
- modify it under the terms of the GNU General Public License as
- published by the Free Software Foundation; either version 2, or (at
- your option) any later version.
-
- The GNU Hurd is distributed in the hope that it will be useful, but
- WITHOUT ANY WARRANTY; without even the implied warranty of
- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- General Public License for more details.
-
- You should have received a copy of the GNU General Public License
- along with this program; if not, write to the Free Software
- Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111, USA. */
-
-#ifndef ROUTE_H_
-#define ROUTE_H_
-
-#include <sys/socket.h>
-#include <netinet/in.h>
-#include <arpa/inet.h>
-#include <net/if.h>
-
-typedef struct ifrtreq {
- char ifname[IFNAMSIZ];
- in_addr_t rt_dest;
- in_addr_t rt_mask;
- in_addr_t rt_gateway;
- int rt_flags;
- int rt_metric;
- int rt_mtu;
- int rt_window;
- int rt_irtt;
- int rt_tos;
- int rt_class;
-} ifrtreq_t;
-
-#endif