1 # Copyright (C) 2013-2015 Czech Technical University in Prague
4 # - Michal Sojka <sojkam1@fel.cvut.cz>
6 # This document contains proprietary information belonging to Czech
7 # Technical University in Prague. Passing on and copying of this
8 # document, and communication of its contents is not permitted
9 # without prior written authorization.
11 # File : Makefile.rules.posix
13 # This file contains variables and rules specific for compilation for
16 makefile_rules_posix_dir := $(patsubst %/,%,$(dir $(lastword $(MAKEFILE_LIST))))
18 ifeq ($(filter TARGET_CFLAGS,$(.VARIABLES)),)
19 $(error "Makefile.config must be included before this file")
26 # Include definition of $(rpp_lib_INCLUDES)
27 include $(makefile_rules_posix_dir)/../Makefile.var
29 # Include UPPERCASE function
30 include $(makefile_rules_dir)/../common.mk
32 RPP_CFLAGS = $(rpp_lib_INCLUDES:%=-I$(makefile_rules_posix_dir)/../%) $(TARGET_CFLAGS) -DTARGET_$(call UPPERCASE,$(TARGET))
35 -MD -MF $@.dep -MP -MT $@
37 RPP_COMPILE_CMD = $(CC) -c $(RPP_CFLAGS) $(RPP_MAKE_CFLAGS) -o $@ $<
40 RPP_LIB_DIR = $(makefile_rules_posix_dir)/$(TARGET)/$(BUILD_DIR)
42 RPP_LDFLAGS = -L$(RPP_LIB_DIR)
44 RPP_LDLIBS = -l:rpp-lib.lib $(TARGET_LDLIBS) -lpthread
46 $(RPP_LIB_DIR)/rpp-lib.lib: