Brian Silver | 015b591 | 2014-08-07 15:50:15 -0500 | [diff] [blame] | 1 | ################################################################################ |
| 2 | # |
| 3 | # palmetto_xml |
| 4 | # |
| 5 | ################################################################################ |
| 6 | |
Matt Ploetz | ed8800a | 2015-02-10 13:12:24 -0600 | [diff] [blame] | 7 | PALMETTO_XML_VERSION = a3fc5ca767f0447a80442bbed70eec16f67fc7f4 |
Brian Silver | 015b591 | 2014-08-07 15:50:15 -0500 | [diff] [blame] | 8 | PALMETTO_XML_SITE = $(call github,open-power,palmetto-xml,$(PALMETTO_XML_VERSION)) |
| 9 | |
| 10 | PALMETTO_XML_LICENSE = Apache-2.0 |
| 11 | PALMETTO_XML_DEPENDENCIES = hostboot-install-images openpower-mrw-install-images common-p8-xml-install-images |
| 12 | |
| 13 | PALMETTO_XML_INSTALL_IMAGES = YES |
| 14 | PALMETTO_XML_INSTALL_TARGET = NO |
| 15 | |
| 16 | MRW_SCRATCH=$(STAGING_DIR)/openpower_mrw_scratch |
Brian Silver | 015b591 | 2014-08-07 15:50:15 -0500 | [diff] [blame] | 17 | MRW_HB_TOOLS=$(STAGING_DIR)/hostboot_build_images |
| 18 | |
Brian Silver | 015b591 | 2014-08-07 15:50:15 -0500 | [diff] [blame] | 19 | define PALMETTO_XML_BUILD_CMDS |
| 20 | # copy the palmetto xml where the common lives |
| 21 | bash -c 'mkdir -p $(MRW_SCRATCH) && cp -r $(@D)/* $(MRW_SCRATCH)' |
Brian Silver | 015b591 | 2014-08-07 15:50:15 -0500 | [diff] [blame] | 22 | |
Matt Ploetz | ed8800a | 2015-02-10 13:12:24 -0600 | [diff] [blame] | 23 | # generate the system mrw xml |
| 24 | perl -I $(MRW_HB_TOOLS) \ |
| 25 | $(MRW_HB_TOOLS)/processMrw.pl -x $(MRW_SCRATCH)/palmetto.xml |
Brian Silver | 015b591 | 2014-08-07 15:50:15 -0500 | [diff] [blame] | 26 | endef |
| 27 | |
| 28 | define PALMETTO_XML_INSTALL_IMAGES_CMDS |
| 29 | |
| 30 | # merge in any system specific attributes, hostboot attributes |
Matt Ploetz | ed8800a | 2015-02-10 13:12:24 -0600 | [diff] [blame] | 31 | $(MRW_HB_TOOLS)/mergexml.sh $(MRW_SCRATCH)/$(BR2_PALMETTO_SYSTEM_XML_FILENAME) \ |
Brian Silver | 015b591 | 2014-08-07 15:50:15 -0500 | [diff] [blame] | 32 | $(MRW_HB_TOOLS)/attribute_types.xml \ |
| 33 | $(MRW_HB_TOOLS)/attribute_types_hb.xml \ |
| 34 | $(MRW_HB_TOOLS)/target_types_merged.xml \ |
| 35 | $(MRW_HB_TOOLS)/target_types_hb.xml \ |
Matt Ploetz | ed8800a | 2015-02-10 13:12:24 -0600 | [diff] [blame] | 36 | $(MRW_SCRATCH)/$(BR2_PALMETTO_MRW_XML_FILENAME) > $(MRW_HB_TOOLS)/temporary_hb.hb.xml; |
Brian Silver | 015b591 | 2014-08-07 15:50:15 -0500 | [diff] [blame] | 37 | |
| 38 | # creating the targeting binary |
| 39 | $(MRW_HB_TOOLS)/xmltohb.pl \ |
| 40 | --hb-xml-file=$(MRW_HB_TOOLS)/temporary_hb.hb.xml \ |
| 41 | --fapi-attributes-xml-file=$(MRW_HB_TOOLS)/fapiattrs.xml \ |
| 42 | --src-output-dir=none \ |
| 43 | --img-output-dir=$(MRW_HB_TOOLS)/ \ |
| 44 | --vmm-consts-file=$(MRW_HB_TOOLS)/vmmconst.h --noshort-enums |
| 45 | |
| 46 | mv $(MRW_HB_TOOLS)/targeting.bin $(MRW_HB_TOOLS)/$(BR2_OPENPOWER_TARGETING_BIN_FILENAME) |
| 47 | endef |
| 48 | |
| 49 | $(eval $(generic-package)) |