Unfortunately, PR #789 breaks the possibility to compile coturn in Oracle Solaris 11.4 (SRU 48). It is caused by the fact that LOG_FTP is not defined in Oracle Solaris' "/usr/include/sys/syslog.h".
They define the following syslog facility codes:
```
#define LOG_KERN (0<<3) /* kernel messages */
#define LOG_USER (1<<3) /* random user-level messages */
#define LOG_MAIL (2<<3) /* mail system */
#define LOG_DAEMON (3<<3) /* system daemons */
#define LOG_AUTH (4<<3) /* security/authorization messages */
#define LOG_SYSLOG (5<<3) /* messages generated internally by syslogd */
#define LOG_LPR (6<<3) /* line printer subsystem */
#define LOG_NEWS (7<<3) /* netnews subsystem */
#define LOG_UUCP (8<<3) /* uucp subsystem */
#define LOG_AUTHPRIV (10<<3) /* sensitive/private security/auth messages */
#define LOG_AUDIT (13<<3) /* audit subsystem */
#define LOG_CRON (15<<3) /* cron/at subsystem */
/* other codes through 15 reserved for system use */
#define LOG_LOCAL0 (16<<3) /* reserved for local use */
#define LOG_LOCAL1 (17<<3) /* reserved for local use */
#define LOG_LOCAL2 (18<<3) /* reserved for local use */
#define LOG_LOCAL3 (19<<3) /* reserved for local use */
#define LOG_LOCAL4 (20<<3) /* reserved for local use */
#define LOG_LOCAL5 (21<<3) /* reserved for local use */
#define LOG_LOCAL6 (22<<3) /* reserved for local use */
#define LOG_LOCAL7 (23<<3) /* reserved for local use */
```
So omitting LOG_FTP should fix this for Solaris. As I really doubt that it is needed, I hereby submit a PR which omits LOG_FTP for all operating systems. Other Solaris derivatives (OpenIndiana Hipster, OmniOS) don't seem to be affected, I've checked and found that in their recent versions, LOG_FTP is defined. FreeBSD does also define LOG_FTP.
systemd is not available on macOS - should be disabled in CMake
Test plan:
- Run cmake in a clean folder
- Run make
- Observe that compilation error about missing include `<systemd/sd-daemon.h>` is gone
macOS does not have `pthread_barrier_*` so need to define `TURN_NO_THREAD_BARRIERS` as a workaround
Fixes#946
Tests plan:
- run cmake to generate make files
- run make to build turnserver
- run `examples/run_tests.sh` and pass successfully