Skip to content

Releases: randoragon/libstaple

Strings Update - 2.1.0

03 May 10:13
2bb2413
Compare
Choose a tag to compare

This release adds support for C-style strings. This is achieved by the new suffixed str and strn functions.
The goal is to provide a quick and easy interface for pushing/popping strings from the structures.

This release also adds a new library function: sp_free(), which is a destructor for strings (or any other buffer-like data).

Many man pages have been accordingly updated with extra string information.

Quick example scraped from the sp_free(3) man page:

#include <staple.h>

int main()
{
    struct sp_stack *stack;

    stack = sp_stack_create(sizeof(char*), 15);

    sp_stack_pushstr(stack, "test string #1");
    sp_stack_pushstr(stack, "test string #2");
    sp_stack_pushstr(stack, "test string #3");

    sp_stack_destroy(stack, sp_free);
    /* using NULL instead of sp_free leaks memory */

    return 0;
}

License Update - 2.0.2

21 Aug 19:32
4ab3156
Compare
Choose a tag to compare

This release does nothing more than change the license from GPLv2 to LGPLv2.1. This most notably means that you are henceforth free to link against Staple in proprietary projects.

I've decided to make this a standalone release to draw a fine line between Staple under GPLv2 and Staple under LGPLv2.1, to prevent potential ambiguity in the future.

Update 2.0.1 - Rename rnd to Staple

21 Aug 12:48
ee2d7f4
Compare
Choose a tag to compare

This is an unusual release, the entire library is getting renamed from "rnd" or "librnd" to "Staple" or "libstaple".

WHY

There already exists a C library called "rnd", with roughly the same naming conventions etc. which predates the existence of this library. I was ignorant to its existence for a while, but now that I know I don't want to continue working on a project which collides with another. There are serious issues from situations like these, e.g. packaging the library for linux distros.
My library is still immature and in early stages of development, so I can afford a name change.

Queue Update - 2.0.0

21 Aug 12:11
a110b42
Compare
Choose a tag to compare

This update adds a new data structure to the librnd repertoire - the queue. There are also a lot of other improvements and changes.

Changes For Users

New Features

  • added the queue data structure
  • man pages now get compressed with gzip before installation
  • improved modular design - it is now possible to e.g. only #include <rnd_stack.h> instead of #include <rnd.h> (which would include all modules). The former only makes stack-related functions visible, which keeps you from using or being suggested functions you're not interested in. The linking stage is unaffected.
  • added rnd_is_debug, rnd_is_quiet and rnd_is_abort functions (495f2ce)

Bug Fixes

  • fixed size_t overflow error in rnd_stack_copy (62c32c7)
  • fixed debug mode compilation errors in rnd_stack_print (8bc6b79)
  • fixed rnd_stack_set (32e1fc6)
  • fixed rnd_stack_create division by 0 when passing elem_size=0 (68d164f)
  • fixed rnd_stack_clear not updating stack size (bf4547e)
  • many miscellaneous error-checking fixes in the stack module (e357eeb)
  • fixed numerous small mistakes and ambiguities in man pages

Other

  • renamed some functions (d8df04b)
    • renamed rnd_*_quickinsert functions to rnd_*_qinsert
    • renamed rnd_*_quickremove functions to rnd_*_qremove
    • renamed rnd_*_map functions to rnd_*_foreach

Changes For Developers

  • added many helper functions for working with ring buffers
  • normalized argument order in some helper functions (ef8f3c5)
  • migrated testing framework from greatest to criterion
  • Makefile rewritten to be more conveniently generic with test units (7b92aaa)

Update 1.0.1

21 Aug 12:11
07dc406
Compare
Choose a tag to compare

Library Changes

  • added linking information to man pages
  • added librnd.a generation, making it possible to statically link with the library
  • miscellaneous man page fixes

Internal Changes

  • fixed some missing casts in test units
  • removed rnd_foomap for reasons explained in 15565f6

Stack Release - 1.0.0

21 Aug 12:10
7aef282
Compare
Choose a tag to compare

This is the first release of the library implementing the stack data structure.