[nos-bbs] JNOS tun - fails to compile
Maiko Langelaar
maiko at pcs.mb.ca
Fri Jul 20 20:43:14 EDT 2018
Jay,
Try this out, replace your tun.c with this one below :
http://www.langelaar.net/jnos2/archive/news/tun_sp2l.c
First item in the JNOS page news section.
I'm going sailing now (on the road), gone all weekend. Good luck.
Maiko
On Fri, 20 Jul 2018, Jay Nugent wrote:
> Greetings fellopw NOSers,
> It has been a very long time since I have needed to compile JNOS, and I
> think I need a little help.
>
> I did an RSYNC to grab the latest source from Maiko's site. The compile
> goes along fine until it encounters the first incidence of TUN.C at which
> point I get a few ERRORS and then it exits without creating an executable.
>
> Here is the output of that last lille bitof the compile:
>
> --------------------------------------------------------------------
> gcc -DUNIX -g3 -DDEBUG -Wall -c -o devparam.o devparam.c
> gcc -DUNIX -g3 -DDEBUG -Wall -c -o md5.o md5.c
> gcc -DUNIX -g3 -DDEBUG -Wall -c -o tun.o tun.c
> In file included from netuser.h:38:0,
> from tcp.h:26,
> from iface.h:25,
> from tun.c:26:
> socket.h:85:21: error: expected identifier before numeric constant
> #define SOCK_STREAM 0
> ^
> In file included from /usr/include/x86_64-linux-gnu/sys/socket.h:33:0,
> from /usr/include/linux/if.h:27,
> from tun.c:41:
> /usr/include/x86_64-linux-gnu/bits/socket.h:174:8: error: redefinition of
> ‘struct sockaddr’
> struct sockaddr
> ^~~~~~~~
> In file included from socket.h:22:0,
> from netuser.h:38,
> from tcp.h:26,
> from iface.h:25,
> from tun.c:26:
> sockaddr.h:13:8: note: originally defined here
> struct sockaddr {
> ^~~~~~~~
> <builtin>: recipe for target 'tun.o' failed
> make: *** [tun.o] Error 1
> root at SkyLake2:~/jnos-source#
> -----------------------------------------------------------------
>
> The target machine is 64-bit running Debian Stretch/sid 4.13.0-45-generic.
>
>
> If I understand this correctly, JNOS brings along the TUN code and it is
> not provided by the Linux distro? I thought that it came with Linux but each
> machine I have tested CANNOT find the 'tun' device when I attempt to do an
> 'ifconfig tun0 192.168.100.100'.
>
> I don't find any Step-By-Step on Maiko's site that walks us through
> creating/installing a 'tun' device.
>
>
> Any help is welcome!
>
> --- Jay Nugent WB8TKL
> Ypsilanti, Michigan
>
>
> () ascii ribbon campaign in
> /\ support of plain text e-mail
>
> o Averaging at least 3 days of MTBWTF!?!?!?
> o The solution for long term Internet growth is IPv6.
>
More information about the nos-bbs
mailing list