]> rtime.felk.cvut.cz Git - omk.git/blobdiff - snippets/vxworks
Documented srcdir variable
[omk.git] / snippets / vxworks
index d1f40961fb8c43747fd4c3fcf5b9cc7dda6f2df3..c494ba0c00244aece014694775928d34306402a1 100644 (file)
 # xxx_SOURCES      .. list of specific target sources
 # INCLUDES         .. additional include directories and defines for user-space
 
+ifndef WRENV
+$(error $(shell $(call canttest,WRENV is not defined in config.target)))
+endif
+ifndef WRPACKAGE
+$(error $(shell $(call canttest,WRPACKAGE is not defined in config.target)))
+endif
+ifndef CPU
+$(error $(shell $(call canttest,CPU is not defined in config.target)))
+endif
+ifndef TOOL
+$(error $(shell $(call canttest,TOOL is not defined in config.target)))
+endif
+
+BUILD_DIR_NAME = _build/$(CPU)$(TOOL)
+COMPILED_DIR_NAME = _compiled/$(CPU)$(TOOL)
+GROUP_DIR_NAME =
+
+
+USER_INCLUDE_DIR := $(MAKERULES_DIR)/$(COMPILED_DIR_NAME)/include
+USER_LIB_DIR     := $(MAKERULES_DIR)/$(COMPILED_DIR_NAME)/lib
+USER_UTILS_DIR   := $(MAKERULES_DIR)/$(COMPILED_DIR_NAME)/bin-utils
+USER_TESTS_DIR   := $(MAKERULES_DIR)/$(COMPILED_DIR_NAME)/bin-tests
+USER_BIN_DIR     := $(MAKERULES_DIR)/$(COMPILED_DIR_NAME)/bin
+USER_BUILD_DIR   := $(MAKERULES_DIR)/$(BUILD_DIR_NAME)/rtp
+
+# Note the use of "recursive" =. That's because RELATIVE_DIR is
+# sometimes defined later in 'base'.
+USER_OBJS_DIR    = $(USER_BUILD_DIR)/$(RELATIVE_DIR)
+LOCAL_BUILD_DIR  = $(USER_OBJS_DIR)
+
 .PHONY: check-dir
 
 # Some support to serialize some targets for parallel make
@@ -25,6 +55,15 @@ kernel-modpost-pass: kernel-mod-pass
 kernel-pass: kernel-mod-pass kernel-modpost-pass
 
 override OMK_SERIALIZE_INCLUDED = y
+MAKEOVERRIDES := $(filter-out OMK_SERIALIZE_INCLUDED=n,$(MAKEOVERRIDES))
+endif
+
+# Checks for OMK tester
+ifdef OMK_TESTSROOT
+default-config-pass-check include-pass-check:
+library-pass-check binary-pass-check:
+       @[ -x "$(shell which $(CC))" ] || $(call canttest,Cannot file compiler: $(CC))
+       @[ -x "$(WRENV)" ] || $(call canttest,Cannot execute wrenv script)
 endif