{"id":16358807,"url":"https://github.com/pbatard/bled","last_synced_at":"2025-03-16T15:32:18.627Z","repository":{"id":25034606,"uuid":"28454254","full_name":"pbatard/bled","owner":"pbatard","description":"Base Library for Easy Decompression","archived":false,"fork":false,"pushed_at":"2024-11-27T17:15:46.000Z","size":898,"stargazers_count":32,"open_issues_count":0,"forks_count":4,"subscribers_count":8,"default_branch":"master","last_synced_at":"2025-03-16T03:41:25.298Z","etag":null,"topics":["bzip2","compression-formats","decompression","decompression-library","gzip","lzma","rufus","xz","zip"],"latest_commit_sha":null,"homepage":"","language":"C","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"gpl-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/pbatard.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2014-12-24T16:23:44.000Z","updated_at":"2025-03-05T16:43:41.000Z","dependencies_parsed_at":"2023-01-14T02:01:02.112Z","dependency_job_id":"9e1dab02-d754-45e2-8bf0-6bc2f9b9b019","html_url":"https://github.com/pbatard/bled","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/pbatard%2Fbled","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/pbatard%2Fbled/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/pbatard%2Fbled/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/pbatard%2Fbled/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/pbatard","download_url":"https://codeload.github.com/pbatard/bled/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":243891231,"owners_count":20364574,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["bzip2","compression-formats","decompression","decompression-library","gzip","lzma","rufus","xz","zip"],"created_at":"2024-10-11T02:06:48.344Z","updated_at":"2025-03-16T15:32:18.621Z","avatar_url":"https://github.com/pbatard.png","language":"C","readme":"Bled - Base Library for Easy Decompression\n=============================================\n\n## What's this then?\n\nThis is _Bled_, the \u003cb\u003eB\u003c/b\u003ease \u003cb\u003eL\u003c/b\u003eibrary for \u003cb\u003eE\u003c/b\u003easy \u003cb\u003eD\u003c/b\u003eecompression. It\nis based almost entirely on the native decompression code found in [BusyBox](http://www.busybox.net/).\n\n## What's it for?\n\nIt's a library, that can be used in applications to handle the decompression of\n__.Z__, __.gz__, __.bz2__, __.lzma__, __.xz__, __.zip__, __.zst__ compressed files and/or\narchives.\n\n## Why are you doing that?\n\nBecause I need this stuff for [Rufus](http://rufus.akeo.ie), mostly to handle compressed\ndisk images, and nobody outside of [BusyBox](http://www.busybox.net/) seems to have put\nmuch effort providing a compact, one-size-fits-all Open Source library, for decompressing\nthe most common formats.\n\nAs I am very conscious of size in Rufus, and Busybox is targeted at embedded systems,\nits decompression library seemed like a natural choice. Sure, the [7-Zip LZMA SDK](http://www.7-zip.org/sdk.html)\nis nice, and compiles nicely on Windows, but it only supports lzma/lzma2/xz (+.7z archives),\nso you'll need to add stuff like [miniz](https://code.google.com/p/miniz/), and then some\nmore, and soon enough you're dealing with multiple APIs and a lot of duplicated code.\nPlus these libraries also provide compression support, which we don't need, so the whole\nthing becomes quite large.\n\n## What's the license?\n\nGPLv2 __or later__.\n\nWhile the BusyBox project as a whole is GPLv2 __only__, this library is GPLv2\n__or later__, which means it can be used indiscriminately in GPLv2 or GPLv3 projects.\nThis is possible because the BusyBox sources we used were all explictly tagged GPLv2 or\nlater and any source that wasn't (`libbb.h`, `crc32.c`, `decompress_unxz.c`) has been\nrecreated/replaced with versions that are. Also, since we're not using any part of bzlib\nthere's no additional license notice required. So this really is a _pure_ GPLv2\n__or later__ decompression library, for the most common compression formats.\n\n## What about compressed tar archives?\n\nI'm not planning to handle these, because I have no need for tar extraction in Rufus.\nHowever, since tar archive handling is present in the BusyBox sources, I may accept a\npatch if you feel like adding support for it.\n\n## What about .rar?\n\nNot planning to add support for RAR, unless a truly Free Source (GPL) RAR decompression\ncomes along.\n\n## Are there any limitations?\n\n* Only Windows is supported for now (MinGW/gcc and MSVC). That's because:\n  * Windows is the only platform I need for Rufus\n  * The original `libbb.h` was GPLv2 __only__, so I had to recreate my own from scratch\n    that is GPLv2 __or later__. This was a bit of a pain, so I don't want to bother\n    recreating a GPLv2+ libbb.h for Linux or other platforms.\n* Can't query the uncompressed file size. This is mostly due to the limitation of the\n  compression formats being used, as most of them are stream formats and do not store\n  that information anywhere.\n* .7z archive extraction is not supported.\n* No multithreading and not optimized for speed __at all__!\n* There probably exist limitations with regards to advanced compression and/or newer\n  compression formats.\n\n## Alright I'm sold. What do I need?\n\nEither:\n\n* Visual Studio 2022\n* MinGW\n\nThen use the `.sln` file or run `configure` + `make`.\n\n## Is the name a reference to _Bled, Slovenia_?\n\nIt is. You should visit Slovenia too, if you ever have a chance.\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fpbatard%2Fbled","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fpbatard%2Fbled","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fpbatard%2Fbled/lists"}