From adead5f1b994ebba96e1fc684282bd7bf2e70afb Mon Sep 17 00:00:00 2001 From: "(no author)" <(no author)@b08762b0-b915-fc4b-9d8c-17b2551a87ff> Date: Tue, 26 Aug 2008 10:15:59 +0000 Subject: [PATCH] =?UTF-8?q?(=E4=BD=90=E3=80=85=E6=9C=A8@PSEG1)=EF=BC=A3?= =?UTF-8?q?=EF=BC=AC=EF=BC=B3=E5=BE=8C=E3=81=AE=E3=83=87=E3=82=A3=E3=83=AC?= =?UTF-8?q?=E3=82=AF=E3=83=88=E3=83=AA=E3=81=AB=E5=AF=BE=E3=81=97=E3=81=A6?= =?UTF-8?q?=E3=80=81AQUA=E3=82=84CSU=E3=81=AE=E3=81=9F=E3=82=81=E3=81=AB?= =?UTF-8?q?=E3=83=87=E3=82=A3=E3=83=AC=E3=82=AF=E3=83=88=E3=83=AA=E6=A7=8B?= =?UTF-8?q?=E6=88=90=E3=82=92=E5=A4=89=E6=9B=B4=E3=81=99=E3=82=8B=E3=82=B9?= =?UTF-8?q?=E3=82=AF=E3=83=AA=E3=83=97=E3=83=88=E3=81=AE=E8=BF=BD=E5=8A=A0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit git-svn-id: file:///Users/lillianskinner/Downloads/platinum/twl/TwlIPL/trunk@2276 b08762b0-b915-fc4b-9d8c-17b2551a87ff --- .../CustomSystemUpdater/work/aftercls.sh | 29 ++++++++ .../tests/CustomSystemUpdater/work/toaqua.rb | 69 +++++++++++++++++++ 2 files changed, 98 insertions(+) create mode 100755 build/tests/CustomSystemUpdater/work/aftercls.sh create mode 100755 build/tests/CustomSystemUpdater/work/toaqua.rb diff --git a/build/tests/CustomSystemUpdater/work/aftercls.sh b/build/tests/CustomSystemUpdater/work/aftercls.sh new file mode 100755 index 00000000..a7459117 --- /dev/null +++ b/build/tests/CustomSystemUpdater/work/aftercls.sh @@ -0,0 +1,29 @@ +#!/bin/sh +#! bash -f +#---------------------------------------------------------------------------- +# Project: TwlSDK - tools +# File: aftercls.sh +# +# Copyright 2007 Nintendo. All rights reserved. +# +# These coded instructions, statements, and computer programs contain +# proprietary information of Nintendo of America Inc. and/or Nintendo +# Company Ltd., and are protected by Federal copyright law. They may +# not be disclosed to third parties or copied or duplicated in any form, +# in whole or in part, without the prior written consent of Nintendo. +# +# $Date:: $ +# $Rev$ +# $Author$ +#---------------------------------------------------------------------------- + + + +if [ $# -lt 1 ]; +then + echo "input target dir name" + exit +fi + +./tocsu.sh $1 +ruby toaqua.rb $1 diff --git a/build/tests/CustomSystemUpdater/work/toaqua.rb b/build/tests/CustomSystemUpdater/work/toaqua.rb new file mode 100755 index 00000000..caeb94a1 --- /dev/null +++ b/build/tests/CustomSystemUpdater/work/toaqua.rb @@ -0,0 +1,69 @@ +#---------------------------------------------------------------------------- +# Project: TwlSDK - tools +# File: toaqua.sh +# +# Copyright 2007 Nintendo. All rights reserved. +# +# These coded instructions, statements, and computer programs contain +# proprietary information of Nintendo of America Inc. and/or Nintendo +# Company Ltd., and are protected by Federal copyright law. They may +# not be disclosed to third parties or copied or duplicated in any form, +# in whole or in part, without the prior written consent of Nintendo. +# +# $Date:: $ +# $Rev$ +# $Author$ +#---------------------------------------------------------------------------- +require "find" +require "fileutils" + +REGION_DIR = { + "u" => ["aus"], + "e" => ["usa"], + "j" => ["jp"], + "p" => ["euro"], + "a" => ["aus", "usa", "jp", "euro"], +} + +def proc(target_dir, output_dir) + Find.find(target_dir){ |path| + next unless File.file?(path) && (/[a-z0-9A-Z]{4}-v[0-9]+\.tad\.out/ =~ path) != nil +# p path + src = path + + # ディレクトリ内のtadファイルの.tadより前を取り出す + dest = "" + Find.find(File.split(src)[0]){|tad| + next unless (/.*\.tad\z/ =~ tad) != nil + #p tad + dest = File.split(tad)[1] + } + # リージョンを判別してコピー + regions = REGION_DIR[File.split(src)[1][3..3]] + for region in regions do + system("cp #{src} #{[output_dir, region, dest].join("/")}") + end + } + +end + +# こっからメイン + +if ARGV.size < 1 + $stdout.printf("Usage:#{__FILE__} target_clsed_dir output_dir") + exit -1 +end +src = ARGV[0] +out = "#{src}_foraqua" +system("mkdir #{out}") +system("cp -rf #{src}/aus #{out}") +system("cp -rf #{src}/usa #{out}") +system("cp -rf #{src}/euro #{out}") +system("cp -rf #{src}/jp #{out}") +#system("mkdir #{out}/aus") +#system("mkdir #{out}/usa") +#system("mkdir #{out}/euro") +#system("mkdir #{out}/jp") + +proc(src, out) +