#!/bin/sh
DIR=`dirname $0`/..

# abvw/js/*
TARGET1='bookmark.js contentsearch.js contentview.js contentview_Gomu.js contentview_Maker.js contentview_Marking.js contentview_Memo.js contentview_Paint.js contentview_Pen.js contentview_PopupText.js detail.js header.js history.js home.js login.js settings.js'

# abvw/common/js
TARGET2='avweb.js common.js i18n.js screenLock.js slideshow.js textObject.js zoomDetector.js'

OBFUSCATE_EXECUTABLE="$DIR/packer/jsPacker.pl -e10"

for f in $TARGET1
do
		ORG=$DIR/abvw/js/$f
		TARGET=$DIR/ob/abvw/js/$f
		$OBFUSCATE_EXECUTABLE -i $ORG -o $TARGET
done

for f in $TARGET2
do
		ORG=$DIR/abvw/common/js/$f
		TARGET=$DIR/ob/abvw/common/js/$f
		$OBFUSCATE_EXECUTABLE -i $ORG -o $TARGET
done
