From: wchang kim Date: Thu, 3 May 2018 22:06:23 +0000 (+0900) Subject: It is possible to use "lastest" as snapshot id. X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=587c1c96e389a3f4f42cee24eb6ec4f13ecd2bb4;p=tools%2Ftbb.git It is possible to use "lastest" as snapshot id. Change-Id: I5165139de479d0c8f2b53dcb38e080d964db9d15 --- diff --git a/.defconfig b/.defconfig index 79f1772..3aed999 100644 --- a/.defconfig +++ b/.defconfig @@ -2,9 +2,9 @@ # Automatically generated file; DO NOT EDIT. # Tizen Building Block 20171210.1 Configuration # -TBB_INFO_PLATFORM_VERSION_4.0=y -# TBB_INFO_PLATFORM_VERSION_5.0 is not set -TBB_INFO_SNAPSHOT_ID="20171210.1" +#TBB_INFO_PLATFORM_VERSION_4.0=y +TBB_INFO_PLATFORM_VERSION_5.0=y +TBB_INFO_SNAPSHOT_ID="latest" TBB_INFO_IMAGE_NAME="tizen-iot-img" TBB_SET_no_board=y # building-blocks-sub1-Preset_boards-ARTIK530 is not set diff --git a/Config.in b/Config.in index 6035aac..85d24cf 100644 --- a/Config.in +++ b/Config.in @@ -8,16 +8,16 @@ config TBB_VERSION choice prompt "Platform Version" -config TBB_INFO_PLATFORM_VERSION_4.0 - bool "tizen-4.0" - config TBB_INFO_PLATFORM_VERSION_5.0 bool "tizen-5.0" + +config TBB_INFO_PLATFORM_VERSION_4.0 + bool "tizen-4.0" endchoice config TBB_INFO_SNAPSHOT_ID string "Snapshot ID" - default "20171218.2" + default "latest" help Snapshot ID format : yyyymmdd.n or latest diff --git a/Makefile b/Makefile index 780b69a..d51c8e6 100644 --- a/Makefile +++ b/Makefile @@ -22,15 +22,16 @@ TBB_CONFIG = $(CONFIG_DIR)/.config -include $(TBB_CONFIG) -export TBB_VERSION := 20171218.2 -export TBB_PLATFORM_VERSION := 4.0 +export TBB_VERSION := V1.0 +export TBB_PLATFORM_VERSION := 5.0 +export TBB_SNAPSHOT_ID := latest # This is our default rule, so must come first TIC_CONFIG_ENV = \ TBB_CONFIG=$(TBB_CONFIG) \ BUILD_DIR=$(BUILD_DIR) \ INFO_DIR=$(INFO_DIR) \ - TBB_INFO_SNAPSHOT_ID=$(TBB_VERSION) \ + TBB_INFO_SNAPSHOT_ID=$(TBB_SNAPSHOT_ID) \ TBB_INFO_PLATFORM_VERSION=$(TBB_PLATFORM_VERSION) \ TOPDIR=$(TOPDIR) diff --git a/support/scripts/make_image.sh b/support/scripts/make_image.sh index 1119f9a..92ed585 100755 --- a/support/scripts/make_image.sh +++ b/support/scripts/make_image.sh @@ -64,19 +64,31 @@ then fi fi -echo $S_VER | grep -q "[0-9]\{8\}[.][0-9]$" -if [ $? != 0 ] +if [ $S_VER != "latest" ] then - echo "Invalid snapshot version : $S_VER" - echo "format is yyyymmdd.n" - exit 2 + echo $S_VER | grep -q "[0-9]\{8\}[.][0-9]$" + if [ $? != 0 && $S_VER != "latest" ] + then + echo "Invalid snapshot version : $S_VER" + echo "format is yyyymmdd.n" + exit 2 + fi + S_PATH=tizen-"$P_VER"unified_"$S_VER" +else +S_PATH=$S_VER fi +INDEX_LOC=http://download.tizen.org/snapshots/tizen/"$P_VER"unified/"$S_PATH"/images/standard/iot-headless-2parts-armv7l-artik530_710/ +echo $INDEX_LOC +wget -q -np -nd -P . $INDEX_LOC +KS_FILE=`grep ks index.html | sed -e 's/^.\+\"\(tizen-.\+\)\".\+$/\1/'` +echo $KS_FILE +rm -f index.html + ########## Set varaiables ########## ########## We use artik530 headless ks file because it is the same to rpi3 ########## -KS_FILE=tizen-"$P_VER"unified_"$S_VER"_iot-headless-2parts-armv7l-artik530_710.ks -KS_LOC=http://download.tizen.org/snapshots/tizen/"$P_VER"unified/tizen-"$P_VER"unified_"$S_VER"/images/standard/iot-headless-2parts-armv7l-artik530_710/"$KS_FILE" +KS_LOC=http://download.tizen.org/snapshots/tizen/"$P_VER"unified/"$S_PATH"/images/standard/iot-headless-2parts-armv7l-artik530_710/"$KS_FILE" DOWNDIR=$TBB_INFO_DL_DIR if [ "x$BUILD_DIR" = "x" ] diff --git a/support/scripts/mk_config_from_xml.sh b/support/scripts/mk_config_from_xml.sh index 03a24cd..316327d 100755 --- a/support/scripts/mk_config_from_xml.sh +++ b/support/scripts/mk_config_from_xml.sh @@ -30,7 +30,13 @@ P_VER="" else P_VER=${TBB_INFO_PLATFORM_VERSION}- fi + + +if [ $TBB_INFO_SNAPSHOT_ID = "latest" ] ; then S_VER=$TBB_INFO_SNAPSHOT_ID +else +S_VER="tizen-${P_VER}unified_${TBB_INFO_SNAPSHOT_ID}" +fi if [ -e $TOPDIR/advanced/${TBB_INFO_SNAPSHOT_ID}_$1_${TBB_INFO_PLATFORM_VERSION} ] then @@ -55,8 +61,7 @@ then XMLNAME="base.xml" RESULTFILE=$DOWNDIR/Config_$OUT_TYPE.in else - http://download.tizen.org/snapshots/tizen/${P_VER}unified/tizen-${P_VER}unified_${S_VER}/repos/standard/packages/repodata/ - DOWN_URL="http://download.tizen.org/snapshots/tizen/${P_VER}unified/tizen-${P_VER}unified_${S_VER}/repos/standard/packages/repodata/" + DOWN_URL="http://download.tizen.org/snapshots/tizen/${P_VER}unified/${S_VER}/repos/standard/packages/repodata/" XMLNAME="unified.xml" RESULTFILE=$DOWNDIR/Config_$OUT_TYPE.in fi @@ -138,11 +143,17 @@ then then NAME="libstdcpp-devel" fi + if [ $NAME = "GraphicsMagick-c++-devel" ] + then + NAME="GraphicsMagick-cpp-devel" + fi + if [[ $NAME = *"building-blocks-"* ]] then STATE="skip_package_state" continue fi + echo "config $NAME" >> $OUTFILE echo "bool \"$NAME\"" >> $OUTFILE STATE="package_name_state"