查看單個文章
舊 2006-06-02, 10:05 AM   #2 (permalink)
psac
榮譽會員
 
psac 的頭像
榮譽勳章
UID - 3662
在線等級: 級別:30 | 在線時長:1048小時 | 升級還需:37小時級別:30 | 在線時長:1048小時 | 升級還需:37小時級別:30 | 在線時長:1048小時 | 升級還需:37小時級別:30 | 在線時長:1048小時 | 升級還需:37小時級別:30 | 在線時長:1048小時 | 升級還需:37小時
註冊日期: 2002-12-07
住址: 木柵市立動物園
文章: 17381
現金: 5253 金幣
資產: 33853 金幣
預設

Office 2003 SP2龍捲風版V2.2 製作心得







聲明:轉貼本文請註明出處並保持原文的完整性

一、準備工作:
原材料:Office 2003光碟鏡像OFFICE11.ISO
製作工具:UltraISO、Beyond Compare、Orca、cabarc



其中Orca和cabarc取自WindowsR Server 2003 SP1 Platform SDK:



http://www.microsoft.com/downloads/d...displaylang=en



二、整合SP2:



這裡以Office 2003為例:



1、用UltraISO將OFFICE11.ISO中的所有文件及資料夾,提取到D:\PRO11目錄下,並去掉它們的「隱藏」及「只讀」內容。用記事本打開D:\PRO11\FILES\SETUP\ SETUP.INI,把[Options]段替換為以下內容,作用是內置序列號:



[Options]


;USERNAME=User



;COMPANYNAME=Microsoft



PIDKEY=GWH28DGCMPP6RC46J4MT3HFDY



2、執行以下命令,釋放原始安裝文件到D:\OP1目錄下:




D:\PRO11\Setup.exe /a


然後把D:\OP1資料夾複製出一份副本,並更名為D:\OP2
3、下載Office 2003的SP2完整包(文件名為Office2003SP2-KB887616-FullFile-CHS.exe,大小為120MB):



http://www.microsoft.com/downloads/d...playLang=zh-cn



然後右擊Office2003SP2-KB887616-FullFile-CHS.exe,使用WinRAR解壓縮到D:\SP2目錄下。

4、執行以下命令,整合SP2升級包:


siexec /p D:\SP2\MAINSP2ff.msp /a D:\OP2\pro11.msi SHORTFILENAMES=TRUE /qb



由於此時的OP2資料夾大小已達891MB,一張700M的CD裝不下,因此我們可以先把SP2中的更新文件找出來,然後更新到原CAB包中去。


三、更新CAB包:


1、用Beyond Compare對D:\OP2\FILES和D:\OP1\FILES進行資料夾比較,把更新後的文件找出來。


2、這裡以更新WINWORD.EXE為例:首先要核對一下文件名,文件名必須跟CAB包中的標識一致。用Orca打開D:\OP2\ PRO11.MSI檢視,如圖



3、用WinRAR打開D:\PRO11目錄,查找WINWORD.EXE,搜索結果出來了:W2561417.CAB。把W2561417.CAB複製到D:\下,並用Cabarc進行解壓縮,命令如下:


Md d:\ W2561417


cabarc x d:\W2561417.CAB *.* d:\W2561417\ >d:\list.txt

Del d:\W2561417.CAB


然後用記事本打開d:\list.txt,將裡面的內容修改如下:


d:\W2561417\SYMINPUT.DLL



d:\W2561417\TBLHEAD.DLL_2052


d:\W2561417\WDREADME.HTM_2052





d:\W2561417\MF_WDTOC.XML_2052



d:\W2561417\VB_WDTOC.XML_2052


d:\W2561417\WDTOC.XML_2052


d:\W2561417\OMFCSAT.DLL_2052



d:\W2561417\OMFC.DLL

d:\W2561417\WINWORD.EXE


d:\W2561417\EMAIL.DOT_2052


d:\W2561417\WWINTL.DLL_2052


d:\W2561417\HTMQINTL.DLL_2052


d:\W2561417\HTMLMARQ.OCX




d:\W2561417\HTMMINTL.DLL_2052



d:\W2561417\HTMLMM.OCX



d:\W2561417\WORD.PIP



d:\W2561417\WRDPRTID.XML


d:\W2561417\WINWORD8.DOC


d:\W2561417\MSWORD.OLB


d:\W2561417\WORDMAIL.PIP



d:\W2561417\XML2WORD.XSL


d:\W2561417\wwasum.dll_2052.26565E87_AF6F_400C_8ABB_6D7D45C80B32



4、把更新後的WINWORD.EXE,覆蓋到D\ W2561417目錄下,然後用Cabarc重新壓縮打包,命令如下:


cabarc -m LZX:21 n d:\W2561417.CAB @d:\list.txt



最後把產生的W2561417.CAB,覆蓋到D:\PRO11目錄下即可。



至此,我們完成了對WINWORD.EXE的更新,其他文件的更新也同樣處理即可。



四、更新MSI文件:



這個還沒找到好的方法,我目前的做法如下:


1、複製D:\PRO11\PRO11.MSI到D:\下,用Orca打開D:\PRO11.MSI,在表菜單中選TransForm——View Patch,載入D:\SP2\MAINSP2ff.msp後,我們可以看到很多綠線條,這些是SP2的新增項,如圖



2、然後再用Orca打開D:\PRO11\PRO11.MSI,將所有綠色項都新增進入,最後儲存即可。



以上做法操作繁瑣,並且容易出錯。因此最好做成批處理,代替部分手工操作,以節省時間,減少工作量。具體做法可以參考老外的這篇教程:



After reading a lot about slipstreaming SP1 to Office 2003 still I couln'd find a nice solution. So after many different approaches and reading a lot about MSI here comes another guide on slipstreaming

The Goal: build a fully functional Office 2003 SP1, using cache on setup, asking for serial, being only a bit larger than the original without SP1 & allowing for administrative install

What do you need:
- ORCA
- MSI 3.1 installed
- WSH 5.6 installed
- md5sum.exe (http://unxutils.sourceforge.net/)
- makecab.exe (Microsoft Cabinet SDK)
- sort2cabs.js (Download (5,5kB))
- Office 2003 CD(s)
- appropriate administrative updates
- some hard disk space and some time

What I did to create a working Office 2003 SP1:

1. Copy the office 2003 to the hard disk (referred from now on as X:\office2003). Remove all hidden and write-only attributes from files. Store all updates on hard disk (*.MSP, directory referred to is called x:\SP1). Make backups of X:\office2003\FILES\SETUP\*.INI

2. Apply Updates (slipstream) using the following Syntax:


CODE
msiexec /a X:\office2003\PRO11.MSI /p X:\SP1\MAINSP1ff.msp MSINODISABLEMEDIA=1 SHORTFILENAMES=TRUE PIDKEY="xxxxxxxxxxxxxxxxxxxxxxxxx"
msiexec /a X:\office2003\OWC11.MSI /p X:\SP1\OWC11SP1ff.msp MSINODISABLEMEDIA=1 SHORTFILENAMES=TRUE PIDKEY="xxxxxxxxxxxxxxxxxxxxxxxxx"
msiexec /a X:\office2003\OWC10.MSI /p X:\SP1\OWC102003SP1ff.msp MSINODISABLEMEDIA=1 SHORTFILENAMES=TRUE PIDKEY="xxxxxxxxxxxxxxxxxxxxxxxxx"
msiexec /a X:\office2003\FP11.MSI /p X:\SP1\MAINSP1ff.msp MSINODISABLEMEDIA=1 SHORTFILENAMES=TRUE PIDKEY="yyyyyyyyyyyyyyyyyyyyyyyyy"
... (and so on for all your components)


if this is not working, try first making an administrative install and then copy the original msi-files over the altered and the apply the patches. This may be no longer necessary since MSI 3.x

After the Updates delete any cab files in X:\office2003

3. Create a subdirectory X:\office2003\sort and extract sort2cabs.zip here. Create subdirectories for every msi you installed before (-> X:\office2003\sort\pro11, X:\office2003\sort\owc10, X:\office2003\sort\owc11, ...). The following has to be done with every msi file:
- open with ORCA
- export tables CabinetDetail, Component, Directory, File, Media to the created corresponding directory

4. Copy XML files located at X:\office2003\FILES\SETUP to X:\office2003\sort. Now edit X:\office2003\sort\tabledirs.lst and X:\office2003\sort\xmlfiles.lst to match your need. tabledirs.lst lists all directories containing the exported tables from the msi packages (existence is checked in sort2cabs.js) and xmlfiles.lst lists all xml to edit (correct md5sums).

5. Open a command line (cmd) and change path to X:\office2003\sort. Start sort2cabs using folling syntax:
CODE
cscript sort2cabs.js

for successful completion md5sum.exe and makecab.exe should be placed in a directory listed in the path variable! ok, time for a cup of coffee

6. When the script stops you have to replace some tables in your msi packages. Use ORCA for this task:
- open zzz.msi with ORCA (replace zzz with msi package names)
- import tables called *.new.idt from X:\office2003\sort\zzz, replace the old ones, do not merge
- save (this is important, too)
now the script may continue (this stop is necessary for calculating the md5sums for the xml files)

7. That's nearly all, now copy the xml files from X:\office2003\sort to X:\office2003\FILES\SETUP, restore the backed up ini files in X:\office2003\FILES\SETUP and delete all files that were not originally on the office cd (ok, i wrote a bat file for copying all files to another location, which files are necessary you'll see on your cd ). Burn your new Office 2003 on a CD labeled 'OFFICE11'



It may be necessary to edit the msi package of MS Project when building an AIO CD. The table "Media" contains a column "VolumeLabel" which should be "OFFICE11". Make this change after step 1.

I know this is not as easy as just pressing a button, but sort2cabs.js is rather generic and may work with other msi packages. If not, try to alter the script

Here a short summary what the script does:
- read dirlist.lst and test for all necessary files in listed subdirs
- read all *.idt and combine information in arrays
- sort by media (cab files) and sequence numbers from msi packages
- renumber all files/set new sequence numbers to eliminate duplicate numbers (otherwise you cannot use compression)
- compress using makecab and ddf files to control process, sorting of files in cabs must be the same as sorting by sequence numbers in msi packages
- calculate md5 sums for cabs and other files listed in xml files located in X:\office2003\FILES\SETUP

This may help understanding the script. I added some comments, too.

Because I tested the whole process only with SP1 (maybe all later patches can be integrated) and not in detail please report problems here.






Trackback: http://tb.donews.net/TrackBack.aspx?PostId=712184
psac 目前離線  
送花文章: 3, 收花文章: 1631 篇, 收花: 3205 次