From beaae0b94577301d3fc880c4ba3a9e3dbcd631d0 Mon Sep 17 00:00:00 2001 From: Mark Pizzolato Date: Sat, 21 Jul 2018 03:00:36 -0700 Subject: [PATCH] makefile: Allow building shared memory applications --- makefile | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/makefile b/makefile index 43209091..4b086a74 100644 --- a/makefile +++ b/makefile @@ -332,6 +332,12 @@ ifeq ($(WIN32),) #*nix Environments (&& cygwin) $(info using semaphore: $(call find_include,semaphore)) endif endif + ifneq (,$(call find_include,sys/mman)) + ifneq (,$(shell grep shm_open $(call find_include,sys/mman))) + OS_CCDEFS += -DHAVE_SHM_OPEN + $(info using mman: $(call find_include,sys/mman)) + endif + endif ifneq (,$(call find_include,dlfcn)) ifneq (,$(call find_lib,dl)) OS_CCDEFS += -DHAVE_DLOPEN=$(LIBEXT)