X-Git-Url: http://git.droids-corp.org/?a=blobdiff_plain;f=mk%2Frte.sdkconfig.mk;h=f538649f228ae1bc01a4a0d47c83954d2fc4cee7;hb=52ec00fd1474e8f99f3da705b7efe95ba994b352;hp=46ec9e76df9080a9b5ba1c56417552f7e1202dd4;hpb=c04172b5f0311ce7af586b6004b1f27993a5cc48;p=dpdk.git diff --git a/mk/rte.sdkconfig.mk b/mk/rte.sdkconfig.mk index 46ec9e76df..f538649f22 100644 --- a/mk/rte.sdkconfig.mk +++ b/mk/rte.sdkconfig.mk @@ -74,9 +74,16 @@ else # To do so the temp config is checked for duplicate keys with cut/sort/uniq # Then for each of those identified duplicates as long as there are more than # just one left the last match is removed. +# Part of the config includes the version information taken from "VERSION" +# in the repo. This needs to be split into the various parts using sed and awk. +# To ensure correct version comparison, we append ".99" to the version number +# so that the version of a release is higher than that of its rc's. $(RTE_OUTPUT)/.config: $(RTE_CONFIG_TEMPLATE) FORCE | $(RTE_OUTPUT) $(Q)if [ "$(RTE_CONFIG_TEMPLATE)" != "" -a -f "$(RTE_CONFIG_TEMPLATE)" ]; then \ $(CPP) -undef -P -x assembler-with-cpp \ + `cat $(RTE_SRCDIR)/VERSION | \ + sed -e 's/-rc/.-rc./' -e 's/$$/..99/' | \ + awk -F '.' '{print "-D__YEAR="int($$1), "-D__MONTH="int($$2), "-D__MINOR="int($$3), "-D__SUFFIX=\""$$4"\"", "-D__RELEASE="int($$5)}'` \ -ffreestanding \ -o $(RTE_OUTPUT)/.config_tmp $(RTE_CONFIG_TEMPLATE) ; \ config=$$(cat $(RTE_OUTPUT)/.config_tmp) ; \