This chapter describes how to use PRCCompare
to find differences between two Palm OS resource database files (files of type PRC, BPRC, OPRC, and TRC).
- "Introducing PRCCompare" describes the basic functions of the
PRCCompare
tool. - "Using the PRCCompare Command Line Tool" documents how you specify the
PRCCompare
command line arguments to compare Palm OS resource database files.
Introducing PRCCompare
PRCCompare
compares two Palm OS binary resource database files and produces a text file report detailing the results of the comparison. PRCCompare
reports resources that are in one file but not the other, resources that have different binary data between the two files, and changes to header information such as database names and internal flags.
PRCCompare
can be used as a general purpose debugging tool. For example, if you are testing with a debug ROM and you receive the error message "Resource not found," then you can use PRCCompare
to compare the old and new versions of the application's PRC files and identify the resource that is missing.
PRCCompare
can also be used when doing localization work. For example, say you have an older version of an application which was translated and you only want to translate the resources that have been added in the new version of the application. You can use PRCCompare
to identify the specific resources that are new or changed.
PRCCompare
is available as a command line tool for Windows.
Using the PRCCompare Command Line Tool
PRCCompare
is used to compare two Palm OS binary resource database files.
The command syntax for PRCCompare
is:
PRCCompare inputFile1 inputFile2 [options]
-
inputFile1, inputFile2
- One or more files of the following type:
-
options
- Additional command line options as described in the following section "Specifying Command Line Options."
By default, PRCCompare
compares the database headers, application information and sort information blocks, and all of the resources, and reports all differences between the two files.
PRCCompare
does not report differences in the creation, modification, and backup date and timestamp information found in the database headers, because these are normally different for different builds of the same PRC file.
Specifying Command Line Options
-
-help
-
PRCCompare
displays help information and ignores any other options. -
-helpVersion
-
PRCCompare
displays the tool's version information. -
-ignoreHeader
-
PRCCompare
does not compare the database headers. -
-ignoreInfo
-
PRCCompare
does not compare the application information and sort information. -
-ignoreOvlyTimes
-
PRCCompare
ignores the date and timestamps in overlay resources. - Since the date and timestamp in the
'ovly'
resource is updated each time a PRC overlay is built, this is an expected difference. Therefore, the binary data of these resources may be different, but the logical data is the same. -
-ignoreRes
-
PRCCompare
does not compare the resources. -
-ignoreResData
-
PRCCompare
does not compare the resource data.PRCCompare
reports if a resource is in one file but not the other, but not if the resource exists in both files but has different data. -
-ignoreStrResPad
-
PRCCompare
ignores the pad bytes after string resource types. - Some resources use a string constant with a 0 byte to mark the end of data. Some versions of Palm OS development tools additionally align the resource data to an even boundary by storing an additional 0 byte past the end of the data.
- The binary data of these resources may be different (depending on the development tools used), but the logical data is the same.
-
-noList
-
PRCCompare
does not list the individual resource differences. Instead, it outputs either "No differences found" or the number of differences detected. -
-only
type - Indicates that you want to input only a particular resource or resources of a particular type. This option is followed by a resource type expression:
-
type
- A resource type to indicate all resources of that type.
-
type (id)
- A resource type followed by a resource ID to indicate a specific resource.
-
type (id:id)
- A resource type followed by an ID range to indicate all matching resources.
- This option may be specified multiple times, in which case the options are additive. For example,
"-only tSTR -only tSTL"
indicates that you want to compare only the string and string list resources. -
-omit
type - Indicates that you want to omit a particular resource or resources of a particular type. This option is followed by a resource type expression:
-
type
- A resource type to indicate all resources of that type.
-
type (id)
- A resource type followed by a resource ID to indicate a specific resource.
-
type (id:id)
- A resource type followed by an ID range to indicate all matching resources.
- This option -omit may be specified multiple times in which case the options are combined. For example,
"-omit Talt -omit tFRM"
indicates that you want to compare all resources except for alert resources and form resources. -
-q | -quiet
-
PRCCompare
suppresses the tool description (tool name and version number) and copyright information.