Add support for OpenBSD

This commit is contained in:
Rafal Kupiec 2018-07-20 22:20:47 +02:00
parent 100971a37a
commit efceb9d12b
Signed by: belliash
GPG Key ID: 4E829243E0CFE6B4
1 changed files with 9 additions and 3 deletions

View File

@ -4,7 +4,7 @@ CFLAGS = -fPIC -Iinclude -I. -W -Wunused -Wall
# Additional CFLAGS for debug build
DFLAGS = -O0 -g
# Addditional CFLAGS for stable build
# Addditional CFLAGS for release build
RFLAGS = -O3 -s
# Flags to pass to the linker
@ -43,6 +43,13 @@ ifeq "$(PLATFORM)" "Linux"
ESUFFIX :=
LSUFFIX := .so
endif
ifeq "$(PLATFORM)" "OpenBSD"
CC := clang
MD := mkdir -p
RM := rm -rfv
ESUFFIX :=
LSUFFIX := .so
endif
ifeq "$(PLATFORM)" "Windows"
CC := gcc
MD := md
@ -65,7 +72,7 @@ SAPI := $(subst /,,$(subst sapi/,,$(dir $(wildcard sapi/*/))))
.SUFFIXES:
.PHONY: clean debug release test
.PHONY: clean debug release style test
debug: export CFLAGS := $(CFLAGS) $(DFLAGS)
debug: engine sapi module
@ -102,4 +109,3 @@ $(SAPI):
clean:
$(RM) $(BUILD_DIR)