Library File Format Changes for Library Packages

The sctructure of the .libpack format.

Library parts made for Archicad can be in many different formats. Some are used for development, while others are optimized for delivering these libraries to users. From Archicad 28, a new format is introduced: the library packages (or libpacks for short). While all other formats were in use before, the library package format also changed them.

New in hsf

If hsf is new to you in general, you can read more about it here: HSF source format

In the library package format, a new file is used optionally in each hsf folder: parammapping.xml. This file relates to the ability to change the library part parameters’ defaults in Archicad. It lists all those parameters from its parent library part that can be changed via the Mapping Value Tables by the user. See more on this topic at Setting Library Part Defaults  section of the User Documentation and Creating parammapping.xml and MappingDefinitions.json

The decoding of all hsf files should be UTF-8 with BOM (the LP_XMLConverter creates these files with the proper encoding; however, when created manually, the encoding should be set accordingly).

New in .lcf

The contents of a .lcf file do not change with the introduction of library packages, but its use does.

A library package consists of a .lcf file supplemented by additional files. These new files hold all the information that makes the library packages a more powerful and flexible version of the previously used .lcf files.

.libpack

The new format in which libraries are released to users from Archicad 28 onwards is .libpack. Each .libpack contains a single .lcf file and additional data files, making library usage more flexible than before.

Folder/File Optional/Mandatory Details Format
package.info mandatory As libpartdata.xml is the summary of a library part, the package.info is the summary of a library package. See more on this in Libpack info files UTF-8 encoding without BOM
localizationData.info optional unless referred to in package.info Describes the .libpack’s behavior in different localization settings. Refers to mappingDefinitions.json, pathnametables, and dictionaries, if applicable. See more on this in Changing libpack language section of the User Documentation. For technical details, visit Libpack info files.
Localization folder optional unless referred to in localizationData.info Contains two main parts: pathnametables and dictionaries, both of which are used for Changing libpack language section of the User Documentation
symbolStrings.po Contains translations for library parts’ strings .po format, UTF-8 encoding with BOM

(GNU gettext utilities)

fileNames.po Contains translations for library part names
folderNames.po Contains translations for the virtual folder structure defined in pathNameTable.json
pathNameTable.json Defines alternate virtual folder structures UTF-8 encoding without BOM
mappingDefinitions.json Needed to change library part parameter defaults (Setting library part defaults section of the User Documentation). Archicad uses it to communicate between the library parts’ parameters and the MappingValueTable.json loaded into the project. It can be created by hand or automatically during the build process if any library parts have parammapping.xml (Creating parammapping.xml and MappingDefinitions.json).

MappingValueTable.json

Not strictly a library format, but this file is introduced with library packages in Archicad 28. It describes the value to which each parameter of each library part is set by default. MappingValueTables are shipped with the template files, but the user can change its content, adjusting library defaults to their company templates and needs.

Read more on this in Setting Library Part Defaults section of the User Documentation.