add OpenBSD support

- use default compiler (clang) instead of gcc
- add required header file
- fix for clang's isdigit() return value
pull/162/head
SASANO Takayoshi 6 years ago
parent 2f239d6746
commit 2f26d3a94a

@ -41,6 +41,8 @@
#include <fstream>
#include <algorithm>
#include <arpa/inet.h>
#include <sys/socket.h>
#include <netinet/in.h>
////////////////////////////////////////////////////////////////////////////////////////
// defines

@ -1,4 +1,4 @@
CC=g++
CC=c++
CFLAGS=-c -std=c++11 -pthread
LDFLAGS=-std=c++11 -pthread
SOURCES=$(wildcard *.cpp)

@ -41,6 +41,8 @@
#include <fstream>
#include <algorithm>
#include <arpa/inet.h>
#include <sys/socket.h>
#include <netinet/in.h>
////////////////////////////////////////////////////////////////////////////////////////
// defines

@ -1,4 +1,4 @@
CC=g++
CC=c++
CFLAGS=-c -std=c++11 -pthread
LDFLAGS=-std=c++11 -pthread
SOURCES=$(wildcard *.cpp)

@ -152,7 +152,10 @@ bool CDmridDir::IsValidDmrid(const char *sz)
ok = true;
for ( size_t i = 0; (i < n) && ok; i++ )
{
ok &= ::isdigit(sz[i]);
if ( !::isdigit(sz[i]) )
{
ok = false;
}
}
}
return ok;

@ -41,6 +41,8 @@
#include <fstream>
#include <algorithm>
#include <arpa/inet.h>
#include <sys/socket.h>
#include <netinet/in.h>
////////////////////////////////////////////////////////////////////////////////////////
// defines

@ -1,4 +1,4 @@
CC=g++
CC=c++
CFLAGS=-c -std=c++11 -pthread
LDFLAGS=-std=c++11 -pthread
SOURCES=$(wildcard *.cpp)

Loading…
Cancel
Save

Powered by TurnKey Linux.