Skip to content

Commit c0efba7

Browse files
committed
2 parents 5809941 + 535ba8a commit c0efba7

File tree

2 files changed

+8
-6
lines changed

2 files changed

+8
-6
lines changed

make-linux.mk

Lines changed: 7 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -79,7 +79,7 @@ endif
7979
ifeq ($(ZT_SYNOLOGY), 1)
8080
override CFLAGS+=-fPIC
8181
override CXXFLAGS+=-fPIC
82-
override DEFS+=-D__SYNOLOGY__
82+
override DEFS+=-D__SYNOLOGY__
8383
endif
8484

8585
ifeq ($(ZT_TRACE),1)
@@ -111,6 +111,12 @@ ifeq ($(CC_MACH),amd64)
111111
endif
112112
ifeq ($(CC_MACH),powerpc64le)
113113
ZT_ARCHITECTURE=8
114+
override DEFS+=-DZT_NO_TYPE_PUNNING
115+
endif
116+
ifeq ($(CC_MACH),powerpc)
117+
ZT_ARCHITECTURE=8
118+
override DEFS+=-DZT_NO_TYPE_PUNNING
119+
override DEFS+=-DZT_NO_CAPABILITIES
114120
endif
115121
ifeq ($(CC_MACH),ppc64le)
116122
ZT_ARCHITECTURE=8
@@ -199,10 +205,6 @@ ifeq ($(CC_MACH),mips64el)
199205
ZT_ARCHITECTURE=6
200206
override DEFS+=-DZT_NO_TYPE_PUNNING
201207
endif
202-
ifeq ($(CC_MACH),powerpc64le)
203-
ZT_ARCHITECTURE=7
204-
override DEFS+=-DZT_NO_TYPE_PUNNING
205-
endif
206208

207209
# Fail if system architecture could not be determined
208210
ifeq ($(ZT_ARCHITECTURE),999)

one.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -972,7 +972,7 @@ static void _sighandlerQuit(int sig)
972972
#endif
973973

974974
// Drop privileges on Linux, if supported by libc etc. and "zerotier-one" user exists on system
975-
#ifdef __LINUX__
975+
#if defined(__LINUX__) && !defined(ZT_NO_CAPABILITIES)
976976
#ifndef PR_CAP_AMBIENT
977977
#define PR_CAP_AMBIENT 47
978978
#define PR_CAP_AMBIENT_IS_SET 1

0 commit comments

Comments
 (0)