From ee90976cd6e33da5e77737bf7dd1e54b5101a58c Mon Sep 17 00:00:00 2001 From: Dirk Zimoch Date: Thu, 25 Jun 2020 16:26:43 +0200 Subject: [PATCH] fix problems with OS dependent headers: 1. find the correct one, 2. install default --- App/tools/driver.makefile | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/App/tools/driver.makefile b/App/tools/driver.makefile index b127e0f..4e9f78a 100644 --- a/App/tools/driver.makefile +++ b/App/tools/driver.makefile @@ -873,7 +873,10 @@ vpath %Record.dbd ${DBD_PATH} vpath menu%.dbd ${DBD_PATH} # Find header files to install. -vpath %.h $(addprefix ../,$(sort $(dir $(filter-out /%,${HDRS}) ${SRCS}))) $(sort $(dir $(filter /%,${HDRS}))) +# Order is important! First OS dependent, then os default, then others +vpath %.h $(sort $(filter %/os/$(OS_CLASS)/,$(dir ${HDRS}))) +vpath %.h $(sort $(filter %/os/default/,$(dir ${HDRS}))) +vpath %.h $(sort $(dir ${HDRS} $(filter-out /%,${SRCS}))) PRODUCTS = ${MODULELIB} ${MODULEDBD} ${DEPFILE} MODULEINFOS: @@ -984,6 +987,10 @@ ${INSTALL_BINS}: $(addprefix ../,$(filter-out /%,${BINS})) $(filter /%,${BINS}) @echo "Installing binaries $^ to $(@D)" $(INSTALL) -d -m555 $^ $(@D) +$(INSTALL_INCLUDE)/os/default/% : % + $(ECHO) "Installing os dependent include file $@" + @$(INSTALL) -d -m $(INSTALL_PERMISSIONS) $< $(@D) + # Create SNL code from st/stt file. # (RULES.Vx only allows ../%.st, 3.14 has no .st rules at all.) # Important to have %.o: %.st and %.o: %.stt rule before %.o: %.c rule!