2009-09-06 13:44:18 -06:00
|
|
|
#!/bin/sh
|
|
|
|
#
|
|
|
|
# 'Cause xcodebuild is hard to deal with
|
|
|
|
|
|
|
|
SRCDIR=$1
|
|
|
|
BUILDDIR=$2
|
|
|
|
BUNDLE_ROOT=$3
|
|
|
|
|
2012-06-10 07:21:05 -06:00
|
|
|
localities="Dutch English French German Italian Japanese Spanish ar ca cs da el fi he hr hu ko no pl pt pt_PT ro ru sk sv th tr uk zh_CN zh_TW"
|
2009-09-06 13:44:18 -06:00
|
|
|
for lang in ${localities} ; do
|
2010-12-21 13:10:44 -07:00
|
|
|
[ -d ${BUNDLE_ROOT}/Contents/Resources/${lang}.lproj ] && rm -rf ${BUNDLE_ROOT}/Contents/Resources/${lang}.lproj
|
2009-09-06 13:44:18 -06:00
|
|
|
mkdir -p ${BUNDLE_ROOT}/Contents/Resources/${lang}.lproj/main.nib
|
|
|
|
[ -d ${BUNDLE_ROOT}/Contents/Resources/${lang}.lproj/main.nib ] || exit 1
|
|
|
|
|
2015-11-07 09:48:51 -07:00
|
|
|
for f in Localizable.strings main.nib/keyedobjects.nib ; do
|
2009-09-06 13:44:18 -06:00
|
|
|
install -m 644 ${SRCDIR}/Resources/${lang}.lproj/$f ${BUNDLE_ROOT}/Contents/Resources/${lang}.lproj/${f}
|
|
|
|
done
|
|
|
|
done
|
|
|
|
|
2010-12-21 13:10:44 -07:00
|
|
|
install -m 644 ${SRCDIR}/Resources/English.lproj/main.nib/designable.nib ${BUNDLE_ROOT}/Contents/Resources/English.lproj/main.nib
|
2009-09-06 13:44:18 -06:00
|
|
|
install -m 644 ${SRCDIR}/Resources/X11.icns ${BUNDLE_ROOT}/Contents/Resources
|
|
|
|
|
|
|
|
install -m 644 ${BUILDDIR}/Info.plist ${BUNDLE_ROOT}/Contents
|
|
|
|
install -m 644 ${SRCDIR}/PkgInfo ${BUNDLE_ROOT}/Contents
|
|
|
|
|
|
|
|
mkdir -p ${BUNDLE_ROOT}/Contents/MacOS
|
|
|
|
install -m 755 ${SRCDIR}/X11.sh ${BUNDLE_ROOT}/Contents/MacOS/X11
|
|
|
|
|
|
|
|
if [[ $(id -u) == 0 ]] ; then
|
|
|
|
chown -R root:admin ${BUNDLE_ROOT}
|
|
|
|
fi
|