Raphael Moll | fe21e0b | 2010-11-11 16:03:07 -0800 | [diff] [blame] | 1 | #!/bin/bash |
Raphael | 2eb3f74 | 2011-09-14 21:11:30 -0700 | [diff] [blame] | 2 | # |
| 3 | # Copyright (C) 2009 The Android Open Source Project |
| 4 | # |
| 5 | # Licensed under the Apache License, Version 2.0 (the "License"); |
| 6 | # you may not use this file except in compliance with the License. |
| 7 | # You may obtain a copy of the License at |
| 8 | # |
| 9 | # http://www.apache.org/licenses/LICENSE-2.0 |
| 10 | # |
| 11 | # Unless required by applicable law or agreed to in writing, software |
| 12 | # distributed under the License is distributed on an "AS IS" BASIS, |
| 13 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
| 14 | # See the License for the specific language governing permissions and |
| 15 | # limitations under the License. |
| 16 | # |
| 17 | |
Raphael Moll | fe21e0b | 2010-11-11 16:03:07 -0800 | [diff] [blame] | 18 | |
Raphael | 2a26b07 | 2011-02-01 12:51:24 -0800 | [diff] [blame] | 19 | # This file is run by development/tools/build/windows_sdk.mk right |
| 20 | # after development.git/tools/build/patch_windows_sdk.sh. |
Raphael Moll | fe21e0b | 2010-11-11 16:03:07 -0800 | [diff] [blame] | 21 | # Please see the details in the other file. |
| 22 | |
Raphael | 2a26b07 | 2011-02-01 12:51:24 -0800 | [diff] [blame] | 23 | set -e # any error stops the build |
Raphael Moll | fe21e0b | 2010-11-11 16:03:07 -0800 | [diff] [blame] | 24 | |
| 25 | # Verbose by default. Use -q to make more silent. |
Raphael | 2a26b07 | 2011-02-01 12:51:24 -0800 | [diff] [blame] | 26 | V="" |
Raphael Moll | fe21e0b | 2010-11-11 16:03:07 -0800 | [diff] [blame] | 27 | if [[ "$1" == "-q" ]]; then |
Raphael Moll | fe21e0b | 2010-11-11 16:03:07 -0800 | [diff] [blame] | 28 | shift |
Raphael | 2a26b07 | 2011-02-01 12:51:24 -0800 | [diff] [blame] | 29 | else |
| 30 | echo "Win SDK: $0 $*" |
| 31 | set -x # show bash commands; no need for V=-v |
Raphael Moll | fe21e0b | 2010-11-11 16:03:07 -0800 | [diff] [blame] | 32 | fi |
| 33 | |
| 34 | TEMP_SDK_DIR=$1 |
| 35 | WIN_OUT_DIR=$2 |
| 36 | TOPDIR=${TOPDIR:-$3} |
| 37 | |
Raphael | 2eb3f74 | 2011-09-14 21:11:30 -0700 | [diff] [blame] | 38 | # Invoke atree to copy the files |
Raphael | 0ce2b7a | 2011-09-16 15:28:45 -0700 | [diff] [blame] | 39 | # TODO: pass down OUT_HOST_EXECUTABLE to get the right bin/atree directory |
| 40 | ${TOPDIR}out/host/linux-x86/bin/atree -f ${TOPDIR}sdk/build/tools.windows.atree \ |
Raphael | 2eb3f74 | 2011-09-14 21:11:30 -0700 | [diff] [blame] | 41 | -I $WIN_OUT_DIR/host/windows-x86 \ |
| 42 | -I ${TOPDIR:-.} \ |
| 43 | -o $TEMP_SDK_DIR |
Raphael Moll | fe21e0b | 2010-11-11 16:03:07 -0800 | [diff] [blame] | 44 | |