Browse Source

build/solaris: create ioctl_solaris.h

Signed-off-by: David Lamparter <equinox@opensourcerouting.org>
David Lamparter 3 years ago
parent
commit
285ed0c62a
4 changed files with 33 additions and 3 deletions
  1. 2 1
      zebra/Makefile.am
  2. 1 2
      zebra/if_ioctl_solaris.c
  3. 1 0
      zebra/ioctl_solaris.c
  4. 29 0
      zebra/ioctl_solaris.h

+ 2 - 1
zebra/Makefile.am

@@ -39,7 +39,8 @@ testzebra_SOURCES = test_main.c zebra_rib.c interface.c connected.c debug.c \
 noinst_HEADERS = \
 	connected.h ioctl.h rib.h rt.h zserv.h redistribute.h debug.h rtadv.h \
 	interface.h ipforward.h irdp.h router-id.h kernel_socket.h \
-	rt_netlink.h zebra_fpm.h zebra_fpm_private.h
+	rt_netlink.h zebra_fpm.h zebra_fpm_private.h \
+	ioctl_solaris.h
 
 zebra_LDADD = $(otherobj) ../lib/libzebra.la $(LIBCAP)
 

+ 1 - 2
zebra/if_ioctl_solaris.c

@@ -33,10 +33,9 @@
 #include "vrf.h"
 
 #include "zebra/interface.h"
+#include "zebra/ioctl_solaris.h"
 #include "zebra/rib.h"
 
-void lifreq_set_name (struct lifreq *, const char *);
-int if_get_flags_direct (const char *, uint64_t *, unsigned int af);
 static int if_get_addr (struct interface *, struct sockaddr *, const char *);
 static void interface_info_ioctl (struct interface *);
 extern struct zebra_privs_t zserv_privs;

+ 1 - 0
zebra/ioctl_solaris.c

@@ -32,6 +32,7 @@
 #include "zebra/rib.h"
 #include "zebra/rt.h"
 #include "zebra/interface.h"
+#include "zebra/ioctl_solaris.h"
 
 extern struct zebra_privs_t zserv_privs;
 

+ 29 - 0
zebra/ioctl_solaris.h

@@ -0,0 +1,29 @@
+/*
+ * Interface looking up by ioctl () on Solaris.
+ * Copyright (C) 1999 Kunihiro Ishiguro
+ *
+ * This file is part of Quagga.
+ *
+ * Quagga 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.
+ *
+ * Quagga 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 Quagga; see the file COPYING.  If not, write to the Free
+ * Software Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
+ * 02111-1307, USA.
+ */
+
+#ifndef _ZEBRA_IF_IOCTL_SOLARIS_H
+#define _ZEBRA_IF_IOCTL_SOLARIS_H
+
+void lifreq_set_name (struct lifreq *, const char *);
+int if_get_flags_direct (const char *, uint64_t *, unsigned int af);
+
+#endif /* _ZEBRA_IF_IOCTL_SOLARIS_H */