Skip to content

Data stream library for reading and writing files, memory blocks and zipped files, with memory mapping support

License

Notifications You must be signed in to change notification settings

vampirefrog/streamlib

Repository files navigation

StreamLib

Project status GitHub latest commit GitHub release

MSYS2 MINGW64 Build MacOS Build Linux Build

Streaming I/O for stdio, memory blocks and files in zip archives. Supports memory mapping where available, and transparent gzip decompression.

module gzip open read write seek eof tell mmap munmap close
mem R no
R yes ☑️ ☑️ ☑️1 ☑️ ☑️ ☑️2 ☑️2 ☑️
W no ☑️ ☑️ ☑️ ☑️ ☑️ ☑️ ☑️ ☑️ ☑️
W yes ☑️ ☑️ ☑️3 ☑️ ☑️
RW no ☑️ ☑️ ☑️ ☑️ ☑️ ☑️ ☑️ ☑️ ☑️
RW yes
file R no ☑️ ☑️ ☑️ ☑️ ☑️ ☑️ ☑️ ☑️
R yes ☑️ ☑️ ☑️1 ☑️ ☑️ ☑️2 ☑️2 ☑️
W no ☑️ ☑️ ☑️ ☑️ ☑️ ☑️ ☑️ ☑️
W yes ☑️ ☑️ ☑️3 ☑️ ☑️
RW no ☑️ ☑️ ☑️ ☑️ ☑️ ☑️ ☑️ ☑️ ☑️
RW yes
zip_file R no ☑️ ☑️ ☑️4 ☑️ ☑️ ☑️ ☑️ ☑️
R yes ☑️ ☑️ ☑️14 ☑️ ☑️ ☑️2 ☑️2 ☑️
W no
W yes
RW no
RW yes

Building

  1. Clone the repository:
    git clone https://github.com/vampirefrog/streamlib.git
    cd streamlib
  2. Install dependencies:
    sudo apt install libzip-dev zlib1g-dev
  3. Compile the library:
    make HAVE_LIBZIP=1 HAVE_GZIP=1

Footnotes

  1. Slow 2 3

  2. Slurp into memory block 2 3 4 5 6

  3. Forward only 2

  4. Uncompressed data only 2

About

Data stream library for reading and writing files, memory blocks and zipped files, with memory mapping support

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published