Skip to content

phuqoan/aPlib

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

aPLib Compression Library

aPLib is a lightweight, fast, and efficient compression library based on the LZ77 algorithm. It is written in assembly language and optimized for speed.

Features

  • LZ77-based compression: Provides good compression ratios for a wide range of data.
  • Fast: The core compression and decompression routines are written in highly optimized assembly language.
  • Lightweight: The library is small and has a minimal memory footprint.
  • Portable: Can be used in various projects, with examples provided in C.

Building the Library

The library can be built using the provided build scripts.

There are two ways to build the aPLib library:

Using the Python Build Script (Recommended)

A Python build script (build_aplib.py) is provided for a more flexible and cross-platform build process.

Requirements:

  • Python 3.x
  • FASM (the Flat Assembler)

Instructions:

  1. Make sure you have Python and FASM installed and accessible from your system's PATH.

  2. Open a terminal or command prompt in the SRC directory.

  3. Run the following command:

    python build_aplib.py
  4. The script will assemble the source files and create the APLIB.LIB (on Windows) or aplib.a (on Linux/macOS) static library.

Using the Batch Script (Windows Only)

A simple batch script (MakeLib.BAT) is provided for building on Windows.

Requirements:

  • FASM (the Flat Assembler)
  • Microsoft Visual Studio (for the LIB.EXE tool)

Instructions:

  1. Make sure you have FASM and Visual Studio installed.

  2. Open a "Developer Command Prompt for VS" or make sure FASM.EXE and LIB.EXE are in your system's PATH.

  3. Run the MakeLib.BAT script from the SRC directory:

    MakeLib.BAT
  4. The script will assemble the source files and create the APLIB.LIB static library.

Using the Library

Documentation

  • Usage: A C example of how to use the aPLib library.
  • API Reference: A full reference for the public functions in the library.
  • Internals: A high-level overview of the internal workings of the aPLib compression algorithm.

License

The source code of this library is released into the public domain. You are free to use, modify, and distribute it for any purpose. No warranties of any kind are provided.

Disclaimer

This is a project created for educational purposes. The code is provided as-is, without any warranty. Use at your own risk.

Credits

  • Joergen Ibsen: Original author of aPLib.
  • PhuQoan: Optimizations, AP-reverse mode and comments.

About

aPlib (normal & reverse mode)

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published