• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1#!/bin/bash
2
3# A script to generate TZ data updates.
4#
5# Usage: ./createTzDataBundle.sh <tzupdate.properties file> <output file>
6# See libcore.tzdata.update.tools.CreateTzDataBundle for more information.
7
8TOOLS_DIR=src/main/libcore/tzdata/update/tools
9UPDATE_DIR=../update/src/main/libcore/tzdata/update
10GEN_DIR=./gen
11
12# Fail if anything below fails
13set -e
14
15rm -rf ${GEN_DIR}
16mkdir -p ${GEN_DIR}
17
18javac \
19    ${TOOLS_DIR}/CreateTzDataBundle.java \
20    ${TOOLS_DIR}/TzDataBundleBuilder.java \
21    ${UPDATE_DIR}/ConfigBundle.java \
22    ${UPDATE_DIR}/FileUtils.java \
23    -d ${GEN_DIR}
24
25java -cp ${GEN_DIR} libcore.tzdata.update.tools.CreateTzDataBundle $@
26