Initialized data compression for embedded systems
Project description
lean-init
Compression of initialized data for embedded systems.
Features
- Use a fast decompressor (lz4)
- Produce a fully debuggable elf file
Installation
Python package
pipenv shell
pip install leaninit
Native dependencies
The python package relies on lz4 to perform the compression and binutils to parse/edit elf files. Binutils package need to match the target CPU.
How to integrate
LD file
- User add a new section
.leaninit
and specify in it which sections shall be compressed. - Remove
AT
statement for sections to compress.
Start up file
- Replace uncompressed initialization loop by a call to the compressed initialization function.
C code
- Include
leaninit.h
inmain.c
.
Build system
- Invoke
leansys.cli
at the end of the build to generate the final elf file.
How to test
Native dependencies
The test use Renode.
Launching a test
The testit_env
scripts build the python package in an isolated environment and then test the basic example for a particular build preset.
cd examples/basic
./testit_env minSizeRel
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
File details
Details for the file leaninit-0.0.2.tar.gz
.
File metadata
- Download URL: leaninit-0.0.2.tar.gz
- Upload date:
- Size: 109.8 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.0.1 CPython/3.12.8
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 0a8595660885e96882c0a7deb150f01457716e5b41de7fbfb1d113973cd81f5d |
|
MD5 | cc8d68f8c0bd6808b1d210c4efb5ce1f |
|
BLAKE2b-256 | fa1d41251227fb226a0e8e3f9df8c3e816b105b06f0e9171454342210adcf213 |
Provenance
The following attestation bundles were made for leaninit-0.0.2.tar.gz
:
Publisher:
workflow.yml
on sebastien-riou/lean-init
-
Statement:
- Statement type:
https://in-toto.io/Statement/v1
- Predicate type:
https://docs.pypi.org/attestations/publish/v1
- Subject name:
leaninit-0.0.2.tar.gz
- Subject digest:
0a8595660885e96882c0a7deb150f01457716e5b41de7fbfb1d113973cd81f5d
- Sigstore transparency entry: 157356493
- Sigstore integration time:
- Permalink:
sebastien-riou/lean-init@bba71417957799b90a686168d0e24801d8ecf843
- Branch / Tag:
refs/tags/v0.0.2
- Owner: https://github.com/sebastien-riou
- Access:
private
- Token Issuer:
https://token.actions.githubusercontent.com
- Runner Environment:
github-hosted
- Publication workflow:
workflow.yml@bba71417957799b90a686168d0e24801d8ecf843
- Trigger Event:
release
- Statement type:
File details
Details for the file leaninit-0.0.2-py3-none-any.whl
.
File metadata
- Download URL: leaninit-0.0.2-py3-none-any.whl
- Upload date:
- Size: 9.9 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.0.1 CPython/3.12.8
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | f90909d3fa69d1170411f703ef6a95e304dc0d20f106cc81dc8851862bf4d0e7 |
|
MD5 | 991b3c856da75bfc65e0637512230a3d |
|
BLAKE2b-256 | f001fcb1fe8b0ec42cb99b4f3267beb3e00e5e12adb7716ac19f71d289fde94e |
Provenance
The following attestation bundles were made for leaninit-0.0.2-py3-none-any.whl
:
Publisher:
workflow.yml
on sebastien-riou/lean-init
-
Statement:
- Statement type:
https://in-toto.io/Statement/v1
- Predicate type:
https://docs.pypi.org/attestations/publish/v1
- Subject name:
leaninit-0.0.2-py3-none-any.whl
- Subject digest:
f90909d3fa69d1170411f703ef6a95e304dc0d20f106cc81dc8851862bf4d0e7
- Sigstore transparency entry: 157356494
- Sigstore integration time:
- Permalink:
sebastien-riou/lean-init@bba71417957799b90a686168d0e24801d8ecf843
- Branch / Tag:
refs/tags/v0.0.2
- Owner: https://github.com/sebastien-riou
- Access:
private
- Token Issuer:
https://token.actions.githubusercontent.com
- Runner Environment:
github-hosted
- Publication workflow:
workflow.yml@bba71417957799b90a686168d0e24801d8ecf843
- Trigger Event:
release
- Statement type: