Driver FP Fixup

From DDCIDeos
Jump to navigationJump to search

Device driver components don't deliver FP XML specific for each architecture and build variation.

Steps to fix:

  1. Run update-externals to get the latest build-utils.
  2. Create a code/xml folder if one doesn't already exist [it likely doesn't as we moved away from those with config/ bundles]. But for reasons I don't understand exactly, the new FP XML we're creating needs to be in code/ not config/. So I like to put XMLs in a xml/ subfolder under code/.
  3. Create <component>-base-integ.bangvar.fp.xml file in code/xml. The only purpose of this is to provide <component>-base-integ featureSet with one feature, oncePerUsingProcessTemplate. The only actions needed in that feature are the actions that have the !RAM_PAGES! and !CODE_PAGES! copied from the original component FP XML.
  4. Add <component>-base-integ.fp.xml to all necessary CD XML files.
  5. Add usage of the <component>-base-integ featureSet, oncePerUsingProcessTemplate feature in each independendly user-usable feature in the original FP XML.
  6. Remove the actions that have !RAM_PAGES! and !CODE_PAGES! from the original FP XML.
  7. Make sure the versionNumber attribute in the old and new FP XML still has the !MAJOR!.!MINOR!.!DEBUG! bangvars - ie. don't "un-bangvar" the original FP XML.
  8. Modify the FP stuff in the component's makefile. Here's the updated one for duart-nxp:

#------------------------------------------------------------------------------
# Feature Provider targets.
#------------------------------------------------------------------------------
$(APPBASE)-base-integ.fp.xml : $(APPLICATION_BIN) makefile.mk # Implicit dependency on $(APPLICATION).bangvar.fp.xml
$(APPBASE)-base-integ.fp.xml : ADDITIONAL_RAM=0     # Application doesn't need ADDITIONAL_RAM.
DI_DESK_TARGET_ETC_BV += $(APPBASE)-base-integ.fp.xml

  1. If you left the original FP XML in the config/ bundle, it should still get bangvar-replaced and put into the output/desk/ as before.
  2. Change the INSTALL_TREE rule in code/makefile.mk to:
$(eval $(call INSTALL_TREE,$(DISTRIBUTION_INSTALL_PREFIX),$(BRANCH_PREFIX)/config))