108 lines
2.8 KiB
Makefile
108 lines
2.8 KiB
Makefile
#
|
|
# (c) 2010, SWD Embedded Systems Limited, http://www.kpda.ru
|
|
#
|
|
|
|
ifndef QCONFIG
|
|
QCONFIG=qconfig.mk
|
|
endif
|
|
include $(QCONFIG)
|
|
|
|
define PINFO
|
|
PINFO DESCRIPTION=
|
|
endef
|
|
|
|
EXTRA_SILENT_VARIANTS = $(subst -, ,$(SECTION))
|
|
|
|
ifeq ($(NAME),)
|
|
NAME=$(PROJECT)-$(SECTION)
|
|
endif
|
|
|
|
CCVFLAG_fixed=-DDISP_FIXED_POINT
|
|
|
|
DEVGDRVROOT=$(shell $(PWD_HOST) | sed 's!\/devg.*!\/devg!')/$(shell $(PWD_HOST) | sed 's!.*\/devg[^\/]*\/!!' | sed 's!\/.*!!')
|
|
|
|
include $(MKFILES_ROOT)/qmacros.mk
|
|
|
|
-include $(PROJECT_ROOT)/roots.mk
|
|
|
|
#
|
|
# Set this as the default, each devg's pinfo.mk can override if needed.
|
|
#
|
|
SHARED_LIBS=ffb disputilS
|
|
|
|
include $(PROJECT_ROOT)/$(SECTION)/pinfo.mk
|
|
|
|
|
|
USEFILE := ../../../$(SECTION).use
|
|
CONFIG_PATH := $(PROJECT_ROOT)/$(SECTION)/config
|
|
|
|
|
|
#EXTRA_INCVPATH += $(if $(USE_INSTALL_ROOT),$(INSTALL_ROOT_$(OS)),$(USE_ROOT_$(OS)))/usr/include/graphics
|
|
EXTRA_INCVPATH += $(PROJECT_ROOT)/public/graphics
|
|
EXTRA_INCVPATH += $(PROJECT_ROOT)/public
|
|
EXTRA_INCVPATH += $(PROJECT_ROOT)/private
|
|
EXTRA_INCVPATH += $(PROJECT_ROOT)/private/drm
|
|
EXTRA_INCVPATH += $(PROJECT_ROOT)/private/linux
|
|
EXTRA_INCVPATH += $(PROJECT_ROOT)/private/linux/include
|
|
EXTRA_INCVPATH += $(PROJECT_ROOT)/private/linux/include/uapi
|
|
EXTRA_INCVPATH += $(PROJECT_ROOT)/private/linux/arch/$(CPU)
|
|
EXTRA_INCVPATH += $(PROJECT_ROOT)/private/linux/arch/$(CPU)/include
|
|
EXTRA_INCVPATH += $(PROJECT_ROOT)/private/linux/arch/$(CPU)/include/uapi
|
|
|
|
ifneq ($(OS), qnx4)
|
|
ifneq ($(COMPOUND_VARIANT),dll)
|
|
ifneq ($(COMPOUND_VARIANT),dll.g)
|
|
SHARED_LIBDIR = $(OS)/$(CPU)/so.$(patsubst dll.%,%,$(COMPOUND_VARIANT))
|
|
STATIC_LIBDIR = $(OS)/$(CPU)/a.shared.$(patsubst dll.%,%,$(COMPOUND_VARIANT))
|
|
else
|
|
SHARED_LIBDIR = $(OS)/$(CPU)/so.g
|
|
STATIC_LIBDIR = $(OS)/$(CPU)/a.shared.g
|
|
endif
|
|
else
|
|
SHARED_LIBDIR = $(OS)/$(CPU)/so
|
|
STATIC_LIBDIR = $(OS)/$(CPU)/a.shared
|
|
endif
|
|
|
|
-include $(DEVGDRVROOT)/extrasrc.mk
|
|
-include $(DEVGDRVROOT)/driver.mk
|
|
|
|
include $(MKFILES_ROOT)/qtargets.mk
|
|
|
|
ifeq ($(origin NDEBUG),undefined)
|
|
CCFLAGS += -O0
|
|
else
|
|
CCFLAGS += -fomit-frame-pointer
|
|
endif
|
|
CCFLAGS += -Wno-switch
|
|
|
|
else # qnx4
|
|
ifneq ($(COMPOUND_VARIANT), a.g)
|
|
SHARED_LIBDIR = $(OS)/$(CPU)/a
|
|
STATIC_LIBDIR = $(OS)/$(CPU)/a
|
|
SHARED_LIBS += iographics photon3r $(QNX4_LIBS)
|
|
else
|
|
SHARED_LIBDIR = $(OS)/$(CPU)/a.g
|
|
STATIC_LIBDIR = $(OS)/$(CPU)/a.g
|
|
SHARED_LIBS += iographics photon3r $(QNX4_LIBS)
|
|
endif
|
|
SHARED_LIBS += $(QNX4_LIBS)
|
|
LDFLAGS += -T1
|
|
CCFLAGS += -Otax -D__X86__ -D__LITTLEENDIAN__
|
|
endif
|
|
|
|
ifeq ($(origin NDEBUG),undefined)
|
|
ifeq ($(OS), qnx4)
|
|
LIBS += $(foreach lib, $(STATIC_LIBS), $(lib)S) $(SHARED_LIBS)
|
|
else
|
|
LIBS += $(foreach lib, $(STATIC_LIBS), $(lib)S_g) $(foreach lib, $(SHARED_LIBS), $(lib)_g)
|
|
endif
|
|
else
|
|
LIBS += $(foreach lib, $(STATIC_LIBS), $(lib)S) $(SHARED_LIBS)
|
|
endif
|
|
WIN32_ENVIRON=mingw
|
|
|
|
ifeq "$(findstring e2k,$(CPU))" "e2k"
|
|
CCFLAGS += -D__DEF_BELOW4G_TMEM__=\"/below4G/ram\"
|
|
CCFLAGS += -fcontrol-spec
|
|
endif
|