blob: d3fb7bd1b5c4e5928b64792eb3375764fc9a8b92 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
|
#!/bin/sh
# Copyright (c) 2016 Samsung Electronics Co., Ltd All Rights Reserved
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
# This script takes up to three arguments, the syntax is:
# build_tct.sh $ARCH $NATIVE_TCT_REPO [$RESULTS]
#
# It will generate list of all available testsuites in NATIVE_TCT_REPO,
# compile them for ARCH one-by-one and copy produced zip files to RESULTS.
# If RESULTS argument is not given, it is set to ${TESTLAB_SCRIPTS}/native_tct/${ARCH}.
#
# Author: Aleksander Mistewicz <a.mistewicz@samsung.com>
ARCH="${1}"
NATIVE_TCT_REPO="${2}"
RESULTS="${3}"
TESTLAB_SCRIPTS="$(CDPATH='' cd -- "$(dirname -- "$0")" && pwd -P)"
. "${TESTLAB_SCRIPTS}/common.sh"
. "${TESTLAB_SCRIPTS}/build/build.sh"
test -n "${ARCH}" || die "Missing argument: arch"
test -n "${NATIVE_TCT_REPO}" || die "Missing argument: native_tct_repo"
PACKAGES_PATH="/opt/tct/tizen_native_3.0/packages/"
mkdir -p "${PACKAGES_PATH}/tv"
mkdir -p "${PACKAGES_PATH}/common"
NATIVE_TCT_LIST_PATH="/tmp/${ARCH}-$(date +%M%S)"
gen_list "${NATIVE_TCT_REPO}" "${NATIVE_TCT_LIST_PATH}"
cd "${NATIVE_TCT_REPO}"
while IFS= read -r LINE
do
ARCH="${ARCH}" ./tcbuild build "${LINE}"
ARCH="${ARCH}" ./tcbuild install "${LINE}"
done < "${NATIVE_TCT_LIST_PATH}"
test -n "${RESULTS}" || RESULTS="${TESTLAB_SCRIPTS}/native_tct/${ARCH}/"
mkdir -p "${RESULTS}"
mv "${PACKAGES_PATH}/tv/"* "${RESULTS}"
mv "${PACKAGES_PATH}/common/"* "${RESULTS}"
cd "${OLDPWD}"
|