Are

Website:

https://gitlab.com/stcarrez/resource-embedder

Author:
  • Stephane.Carrez@gmail.com
Maintainer:
  • Stephane.Carrez@gmail.com
License:

Apache-2.0

Version:

1.4.0

Alire CI:

Dependencies: Dependents:

No dependents.

Badge:

Advanced Resource Embedder

#resource #embedder #generator

Build Status Test Status Coverage Documentation Status

The resource embedder allows to embed files in binaries by producing C, Ada or Go source files that contain the original files.

To generate a config.ads and config.adb Ada package with the resources, you may use:

are --lang=Ada -o src --resource=config --name-access --fileset='**/*.conf' config

Complex resource integrations are best described with and XML and are generated with:

are --lang=Ada -o src --rule=package.xml --name-access .

For Ada, it generates the following package declaration with the Get_Content function that gives access to the files. The Ada body contains the content of each embedded file.

package Config is
  function Get_Content (Name : in String)
    return access constant String;
end Config;