大网数据广告活动
安装更新与部署

Creating a Patch Creation Properties File

· 52CE 我爱测

To reproduce the sample patch package, you need a software tool capable of creating and editing a Windows Installer patch package.

To reproduce the sample patch package, you need a software tool capable of creating and editing a Windows Installer patch package. Several patch package creation tools are available from independent software vendors. The example discussed in the following sections uses a Windows Installer database editor called Orca to author a patch creation properties file (.pcp extension). The .pcp file may be used with the utilities Msimsp.exe and Patchwiz.dll to generate a Windows Installer patch package (.msp extension). Orca, Msimsp.exe, and Patchwiz.dll are provided in the Windows SDK Components for Windows Installer Developers.

A blank patch creation properties file, template.pcp, is also provided with the SDK. Make a copy of template.pcp and rename this copy MNP2000.pcp. Use Orca or another database editor to enter the following data into the Properties table of MNP2000.pcp. The Properties table contains global settings for the patch package.

Properties Table

Name Value
AllowProductCodeMismatches 1
AllowProductVersionMajorMismatches 1
ApiPatchingSymbolFlags 0x00000000
DontRemoveTempFolderWhenFinished 1
IncludeWholeFilesOnly 0
ListOfPatchGUIDsToReplace
ListOfTargetProductCodes *
PatchGUID {5406B219-A1AC-4BC4-8695-72292C8195AC}
PatchOutputPath c:\output.msp
PatchSourceList PatchSourceList

Use the database editor to enter the following data into the ImageFamilies table of MNP2000.pcp. The ImageFamilies table contains information to be added to the Media table during patching.

ImageFamilies Table

Family MediaSrcPropName MediaDiskId FileSequenceStart DiskPrompt VolumeLabel
MNPapps MNPSrcPropName 2 1000

Enter the following data into the UpgradedImages table of MNP2000.pcp. The UpgradedImages table contains information about the Upgraded image you created in Planning a Small Update Patch.

UpgradedImages Table

Upgraded MsiPath PatchMsiPath SymbolPaths Family
MNP_fixed C:\Note_Installer\Patch\Upgraded\MNP2000.msi MNPapps

Enter the following data into the TargetImages table of MNP2000.pcp. The TargetImages table contains information about the Target image.

TargetImages Table

Target MsiPath SymbolPaths Upgraded Order ProductValidateFlags IgnoreMissingSrcFiles
MNP_error C:\Note_Installer\Patch\Target\MNP2000.msi MNP_fixed 1 0

For the sample patch package, leave the following tables in MNP2000.pcp blank.

UpgradedFiles_OptionalData Table

FamilyFileRanges Table

TargetFiles_OptionalData Table

ExternalFiles Table

UpgradedFilesToIgnore Table

Continue

Source: Microsoft Learn / Windows Win32 documentation by Microsoft and contributors. Documentation licensed CC BY 4.0. Code samples are covered by the MIT License. Converted from Markdown, with links normalized and embedded media omitted.

资料来源与适用范围

资料来源
Microsoft Learn / Windows Win32 documentation
适用范围
Windows Win32 API · Source date 05/31/2018
内容语言
中文;命令、路径和错误标识保留技术原文
本地收录日期
2026-11-15
授权说明
CC BY 4.0 (documentation), MIT (code samples)

正文与所需资源由本站本地存储。查看来源及更新记录 ↗

请按适用版本和实际日志确认原因;本站没有对每一种系统或设备逐项执行文中的操作。