ManagedRoute uses ioctl to add/remove routes on Linux
Added LinuxNetLink to talk to the rtnetlink socket for adding interfaces, addresses routes. Not yet complete. Can currently monitor changes on the system.
This commit is contained in:
@@ -17,6 +17,10 @@ DESTDIR?=
|
||||
|
||||
include objects.mk
|
||||
ONE_OBJS+=osdep/LinuxEthernetTap.o
|
||||
ONE_OBJS+=osdep/LinuxNetLink.o
|
||||
|
||||
NLTEST_OBJS+=osdep/LinuxNetLink.o
|
||||
NLTEST_OBJS+=nltest.o
|
||||
|
||||
# Auto-detect miniupnpc and nat-pmp as well and use system libs if present,
|
||||
# otherwise build into binary as done on Mac and Windows.
|
||||
@@ -55,8 +59,8 @@ ifeq ($(ZT_SANITIZE),1)
|
||||
SANFLAGS+=-fsanitize=address -DASAN_OPTIONS=symbolize=1
|
||||
endif
|
||||
ifeq ($(ZT_DEBUG),1)
|
||||
override CFLAGS+=-Wall -Wno-deprecated -Werror -g -pthread $(INCLUDES) $(DEFS)
|
||||
override CXXFLAGS+=-Wall -Wno-deprecated -Werror -g -std=c++11 -pthread $(INCLUDES) $(DEFS)
|
||||
override CFLAGS+=-Wall -Wno-deprecated -g -pthread $(INCLUDES) $(DEFS)
|
||||
override CXXFLAGS+=-Wall -Wno-deprecated -g -std=c++11 -pthread $(INCLUDES) $(DEFS)
|
||||
ZT_TRACE=1
|
||||
STRIP?=echo
|
||||
# The following line enables optimization for the crypto code, since
|
||||
@@ -307,6 +311,9 @@ debug: FORCE
|
||||
make ZT_DEBUG=1 one
|
||||
make ZT_DEBUG=1 selftest
|
||||
|
||||
nltest: $(NLTEST_OBJS)
|
||||
$(CXX) $(CXXFLAGS) $(LDFLAGS) -o nltest $(NLTEST_OBJS) $(LDLIBS)
|
||||
|
||||
# Note: keep the symlinks in /var/lib/zerotier-one to the binaries since these
|
||||
# provide backward compatibility with old releases where the binaries actually
|
||||
# lived here. Folks got scripts.
|
||||
|
||||
Reference in New Issue
Block a user