Don't compile programs using fork() on MMU-less systems

Systems that lack a MMU cannot use fork() to create the child process.
The patch does not compile the affected programs on MMU-less systems.

Co-developed-by: Marc Kleine-Budde <mkl@pengutronix.de>
Signed-off-by: Marc Kleine-Budde <mkl@pengutronix.de>
Signed-off-by: Dario Binacchi <dario.binacchi@amarulasolutions.com>
This commit is contained in:
Dario Binacchi
2023-05-08 18:30:50 +02:00
parent e44db7366b
commit 5ed3b4ded6
6 changed files with 77 additions and 9 deletions
+13 -3
View File
@@ -45,6 +45,8 @@ MAKEFLAGS := -k
CFLAGS := -O2 -Wall -Wno-parentheses
HAVE_FORK := $(shell ./check_cc.sh "$(CC)" fork_test.c)
CPPFLAGS += \
-I. \
-Iinclude \
@@ -66,10 +68,14 @@ PROGRAMS_ISOTP := \
isotpperf \
isotprecv \
isotpsend \
isotpserver \
isotpsniffer \
isotptun
ifeq ($(HAVE_FORK),1)
PROGRAMS_ISOTP += \
isotpserver
endif
PROGRAMS_J1939 := \
j1939acd \
j1939cat \
@@ -87,14 +93,12 @@ PROGRAMS := \
$(PROGRAMS_J1939) \
$(PROGRAMS_SLCAN) \
asc2log \
bcmserver \
can-calc-bit-timing \
canbusload \
candump \
canfdtest \
cangen \
cansequence \
canlogserver \
canplayer \
cansend \
cansniffer \
@@ -103,6 +107,12 @@ PROGRAMS := \
mcp251xfd-dump \
slcanpty
ifeq ($(HAVE_FORK),1)
PROGRAMS += \
canlogserver \
bcmserver
endif
all: $(PROGRAMS)
clean: