aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorFilipp Lepalaan <filipp@mac.com>2010-02-20 14:06:54 +0200
committerFilipp Lepalaan <filipp@mac.com>2010-02-20 14:06:54 +0200
commitc13136914f3033afb2a373f1d0ba1e0a348b97f0 (patch)
treece5a4679c3c6f8d283363e3e43ed3aae10f849ab
parent05655228858b3defa578cbaaa314ab8f7299ddeb (diff)
downloadmtk-c13136914f3033afb2a373f1d0ba1e0a348b97f0.tar.gz
mtk-c13136914f3033afb2a373f1d0ba1e0a348b97f0.tar.bz2
mtk-c13136914f3033afb2a373f1d0ba1e0a348b97f0.zip
Bug fixes, thinner image
-rwxr-xr-xmake_boot/exclude.txt42
-rwxr-xr-xmake_boot/include.txt70
-rwxr-xr-xmake_boot/makeboot.sh27
3 files changed, 89 insertions, 50 deletions
diff --git a/make_boot/exclude.txt b/make_boot/exclude.txt
index c06e890..6c4092e 100755
--- a/make_boot/exclude.txt
+++ b/make_boot/exclude.txt
@@ -1,34 +1,24 @@
-private/var/vm/sleepimage
-private/var/logs/*
-usr/X11/*
-usr/standalone/bootcaches.plist
+private/var/vm/*
+private/var/log/*
System/Library/Extensions.mkext
System/Library/Extensions/IO80211Family.kext
System/Library/Caches/*
-System/Library/Core Services/Setup Assistant.app
-System/Library/Core Services/RawCamera.bundle
-System/Library/Core Services/Server Assistant.app
-System/Library/Core Services/Front Row.app
+System/Library/CoreServices/Setup Assistant.app
+System/Library/CoreServices/RawCamera.bundle
+System/Library/CoreServices/Server Assistant.app
+System/Library/CoreServices/Front Row.app
-System/Library/Frameworks/JavaVM.framework
-System/Library/Frameworks/JavaFrameEmbedding.framework
-System/Library/Frameworks/CoreWLAN.framework
-System/Library/Frameworks/XgridFoundation.framework
-System/Library/Frameworks/Ruby.framework
-System/Library/Frameworks/Python.framework
+private/var/db/RemoteManagement
+private/var/db/locate.database
+private/var/db/receipts
+private/var/db/BootCache.playlist
+private/var/db/volinfo.database
-System/Library/PrivateFrameworks/iLifeSlideshow.framework
-System/Library/PrivateFrameworks/iLifeMediaBrowser.framework
-System/Library/PrivateFrameworks/MobileDevice.framework
-System/Library/PrivateFrameworks/Apple80211.framework
-System/Library/PrivateFrameworks/CoreChineseEngine.framework
-System/Library/PrivateFrameworks/VideoConference.framework
-System/Library/PrivateFrameworks/OfficeImport.framework
-System/Library/PrivateFrameworks/GeoKit.framework
-System/Library/PrivateFrameworks/ExchangeWebServices.framework
-System/Library/PrivateFrameworks/BackRow.framework
-System/Library/PrivateFrameworks/Helium.framework
-System/Library/PrivateFrameworks/LiveType.framework
+private/var/folders
+private/var/db/dyld
+private/var/root/.Spotlight-V100
+private/var/run/*
+private/tmp/*
diff --git a/make_boot/include.txt b/make_boot/include.txt
index f577e25..b932747 100755
--- a/make_boot/include.txt
+++ b/make_boot/include.txt
@@ -1,3 +1,5 @@
+mach_kernel
+
Applications/TextEdit.app
Applications/System Preferences.app
Applications/Safari.app
@@ -14,35 +16,73 @@ Library/Preferences
System/Library/Caches
System/Library/Components
-System/Library/CoreServices
+
+System/Library/CoreServices/CoreTypes.bundle
+System/Library/CoreServices/KernelEventAgent.bundle
+System/Library/CoreServices/RemoteManagement
+System/Library/CoreServices/SecurityAgentPlugins
+
System/Library/DirectoryServices
-System/Library/ColorSync
System/Library/Displays
-System/Library/Extensions
System/Library/Filesystems
-System/Library/Frameworks
System/Library/KerberosPlugins
-System/Library/LaunchDaemons
System/Library/LoginPlugins
-System/Library/OpenSSL
-System/Library/PreferencePanes/StartupDisk.prefPane
-System/Library/PreferencePanes/Network.prefPane
-System/Library/PrivateFrameworks
+System/Library/Perl
System/Library/Sandbox
-System/Library/ScriptingDefinitions
System/Library/Sounds
System/Library/SystemConfiguration
System/Library/SystemProfiler
-System/Library/Fonts/LastResort.ttf
+System/Library/PreferencePanes/StartupDisk.prefPane
+System/Library/PreferencePanes/Network.prefPane
+
+System/Library/Frameworks/AppKit.framework
+System/Library/Frameworks/ApplicationServices.framework
+System/Library/Frameworks/CoreVideo.framework
+System/Library/Frameworks/CoreServices.framework
+System/Library/Frameworks/IOBluetooth.framework
+System/Library/Frameworks/JavaScriptCore.framework
+System/Library/Frameworks/LDAP.framework
+System/Library/Frameworks/OpenDirectory.framework
+System/Library/Frameworks/OpenGL.framework
+System/Library/Frameworks/PreferencePanes.framework
+System/Library/Frameworks/QTKit.framework
+System/Library/Frameworks/QuickTime.framework
+System/Library/Frameworks/Security.framework
+System/Library/Frameworks/ServiceManagement.framework
+System/Library/Frameworks/WebKit.framework
+
+System/Library/PrivateFrameworks/AppleVA.framework
+System/Library/PrivateFrameworks/CoreMedia.framework
+System/Library/PrivateFrameworks/CoreMediaIOServices.framework
+System/Library/PrivateFrameworks/DSObjCWrappers.framework
+System/Library/PrivateFrameworks/HelpData.framework
+System/Library/PrivateFrameworks/MachineSettings.framework
+System/Library/PrivateFrameworks/MediaToolbox.framework
+System/Library/PrivateFrameworks/MobileDevice.framework
+System/Library/PrivateFrameworks/Shortcut.framework
+System/Library/PrivateFrameworks/VideoToolbox.framework
+
System/Library/Fonts/Helvetica.dfont
-System/Library/Fonts/Menlo.ttc
-System/Library/Fonts/LucidaGrande.ttc
-System/Library/Fonts/Apple Symbols.ttf
+System/Library/Fonts/Geneva.dfont
+System/Library/Fonts/Monaco.dfont
+
+usr/lib/libtcl.dylib
+usr/lib/libtk.dylib
+usr/lib/mecab
+usr/lib/pam
+usr/lib/pkgconfig
+usr/lib/samba
+usr/lib/sasl2
+
+usr/bin
+usr/sbin
+usr/share/sandbox
+usr/share/terminfo
+usr/share/zoneinfo
bin
etc
private
sbin
tmp
-usr
diff --git a/make_boot/makeboot.sh b/make_boot/makeboot.sh
index 3ef33af..17648c9 100755
--- a/make_boot/makeboot.sh
+++ b/make_boot/makeboot.sh
@@ -19,7 +19,7 @@ fi
RSYNC_VERSION=$(rsync --version | head -n 1 | cut -d ' ' -f 8)
if [[ $RSYNC_VERSION -lt 30 ]]; then
- echo "Sorry, but your rsync is too old. You can get the latest from http://github.com/filipp/mtk" 2>&1
+ echo "Sorry, but your rsync is too old" 2>&1
exit 1
fi
@@ -44,21 +44,30 @@ mdutil -i off "${TMP_MOUNT_POINT_PATH}"
mdutil -E "${TMP_MOUNT_POINT_PATH}"
defaults write "${TMP_MOUNT_POINT_PATH}"/.Spotlight-V100/_IndexPolicy Policy -int 3
-mkdir "${TMP_MOUNT_POINT_PATH}/Library/Caches"
+mkdir -p "${TMP_MOUNT_POINT_PATH}/Library/Caches"
echo "Cloning system (this will take a while)..."
/usr/local/bin/rsync\
- --protect-args --fileflags --force-change -aNHAXxrP\
+ --protect-args --fileflags --force-change -avhNHAXxr\
--files-from=./include.txt --exclude-from=./exclude.txt\
- "${SOURCE}" ${TMP_MOUNT_POINT_PATH}
+ "${SOURCE}" $TMP_MOUNT_POINT_PATH
echo "Doing boot things..."
-ditto /mach_kernel "${TMP_MOUNT_POINT_PATH}"/mach_kernel
-ln -s "${TMP_MOUNT_POINT_PATH}"/mach_kernel "${TMP_MOUNT_POINT_PATH}"/mach
-kextcache -l -m "${TMP_MOUNT_POINT_PATH}"/System/Library/Extensions.mkext "${SOURCE}"/System/Library/Extensions
-bless --folder "${TMP_MOUNT_POINT_PATH}"/System/Library/CoreServices --label "${VOL_NAME}" --botinfo --bootefi --verbose
+kextcache -l -m "${TMP_MOUNT_POINT_PATH}"/System/Library/Extensions.mkext\
+ "${SOURCE}"/System/Library/Extensions
+
+bless --folder "${TMP_MOUNT_POINT_PATH}"/System/Library/CoreServices\
+ --label "${VOL_NAME}" --bootinfo --bootefi --verbose
+
+echo "Removing non-English localisations..."
+find "${TMP_MOUNT_POINT_PATH}"/Applications\
+ "${TMP_MOUNT_POINT_PATH}"/System/Library/Frameworks\
+ -type d -name '*.lproj' ! -iname 'en*' -delete
+
+#chflags hidden "${TMP_MOUNT_POINT_PATH}"/mach_kernel
#kextcache -a i386 -s -l -n -z -m /tmp/macnbi-i386/mach.macosx.mkext /System/Library/Extensions
-rm -r "${TMP_MOUNT_POINT_PATH}"
diskutil eject "${TMP_MOUNT_POINT_PATH}"
+rm -r "${TMP_MOUNT_POINT_PATH}"
+open .