ifndef QCONFIG QCONFIG=qconfig.mk endif include $(QCONFIG) LIB_VARIANT=$(subst .o,,a.$(COMPOUND_VARIANT)) #===== INSTALLDIR - Subdirectory where the executable or library is to be installed. INSTALLDIR=boot/sys #===== LIBS - a space-separated list of library items to be included in the link. LIBS=-Bstatic ^ipl -Bdynamic LIBS=-Bstatic ^ipl -Bdynamic #===== NAME - name of the project (default - name of project directory). NAME=ipl-$(SECTION) #===== USEFILE - the file containing the usage message for the application. USEFILE= #===== EXTRA_INCVPATH - a space-separated list of directories to search for include files. EXTRA_INCVPATH=$(LIBIPL_ROOT)/$(CPU)/$(LIB_VARIANT) \ $(LIBIPL_ROOT)/$(CPU) $(LIBIPL_ROOT) \ $(PROJECT_ROOT_include) #===== EXTRA_LIBVPATH - a space-separated list of directories to search for library files. EXTRA_LIBVPATH=$(LIBIPL_ROOT)/$(CPU)/$(LIB_VARIANT) \ $(PROJECT_ROOT_ipl)/$(CPU)/$(patsubst o%,a%,$(notdir $(CURDIR))) ## DEFFILE = $(LIBIPL_ROOT)/$(CPU)/$(LIB_VARIANT)/asmoff.def #===== LDFLAGS - add the flags to the linker command line. LDFLAGS+=-nostdlib -M -M -nostartup \ -Wl,-T$(PROJECT_ROOT)/$(PROJECT).lnk -include $(PROJECT_ROOT)/roots.mk ifndef LIBIPL_ROOT LIBIPL_ROOT=$(PRODUCT_ROOT)/lib endif # # Make sure *_reset.o gets linked _first_. # old_OBJS:=$(OBJS) OBJS:=$(filter %_reset.o, $(old_OBJS)) \ $(filter-out %_reset.o, $(old_OBJS)) include $(MKFILES_ROOT)/qmacros.mk ifndef QNX_INTERNAL QNX_INTERNAL=$(PROJECT_ROOT)/.qnx_internal.mk endif include $(QNX_INTERNAL) postbuild: $(POST_BUILD) include $(MKFILES_ROOT)/qtargets.mk CCF_gcc_=-O2 -fomit-frame-pointer CCF_gcc_qcc=-O2 -Wc,-fomit-frame-pointer #===== CCFLAGS - add the flags to the C compiler command line. CCFLAGS+=-O0 $(CCFLAGS_$(COMPILER_TYPE)_$(COMPILER_DRIVER)) ASFLAGS+=-Wa,--defsym -Wa,MPC$(firstword $(MPU) 8280)=1 # # This particular little kludge is to stop GCC from using F.P. instructions # to move 8 byte quantities around. # CC_nto_ppc_gcc+=-msoft-float CC_nto_ppc_gcc_qcc+=-Wc,-msoft-float #===== DEFCOMPILER_TYPE - default compiler. DEFCOMPILER_TYPE=gcc #===== GCC_VERSION - use it when you want to specify compiler version other than default. GCC_VERSION=4.2.1 #===== POST_BUILD - extra steps to do after building the image. define POST_BUILD -@${QNX_HOST}/usr/bin/ntoppc-objcopy --input-format=elf32-powerpc --output-format=srec -R.data $(BUILDNAME) $(BUILDNAME)_srec endef