PRC (Palm Resource Code) is a container format for code databases in Palm OS, Garnet OS and Access Linux Platform. Its structure is similar to PDB databases.N. Rhodes, J. McKeehan. Palm OS Programming, Second Edition, O'Reilly, 2001, . Usually, a PRC file is a flat representation of a Palm OS application that is stored as forked database on the PDA.

PRC files are also used by the Mobipocket e-book-reader (here sometimes referred to as MOBI formatMobileRead Wiki: Reference for the MOBI format). The AZW format of Amazon's Kindle reading device is in turn a DRM-restricted form of the Mobipocket format.

On Palm OS, PRC files are used for applications, localized resources (overlays) and shared libraries.

Structure of PRC file In its essence, a PRC file is similar to a classic Mac OS application. It contains a PRC header, PRC resource headers and PRC resources.Theodore Ts'o (2000) The PRC Format. Accessed on 2009-03-07 PRC Header PRC Resource Header PRC Resources

PRC Header The PRC header is located at the beginning of the file and contains meta-information on the file: Offset Name Type Size 0x00 name char 32 Bytes 0x20 flags integer 2 Bytes 0x22 version integer 2 Bytes 0x24 creation time 32bit integer - PDB Datetime 4 Bytes 0x28 modification time 32bit integer - PDB Datetime 4 Bytes 0x2c backup time 32bit integer - PDB Datetime 4 Bytes 0x30 mod_num integer 4 Bytes 0x34 app_info integer 4 Bytes 0x38 sort_info integer 4 Bytes 0x3c type integer 4 Bytes 0x40 creator integer 4 Bytes 0x44 unique_id_seed integer 4 Bytes 0x48 next_record_list integer 4 Bytes 0x4c num_records integer 2 Bytes

PRC Resource Header For every resource (specified by num_records), there is a resource header containing: name type notes size name char Name of the resource 4 bytes ID integer ID number of the resource 2 bytes offset integer Pointer to resource data 4 bytes

PRC Resources Every application contains al least a Code #0 resource with size information and jump tables, a Code #1 resource with executable code and data resources containing pre-initialized values of global variables in compressed form. Other resources that may be contained are forms, form objects, alerts and multimedia data, e. g. images and sounds.

References