Personal C library of data structures and common code
  • C 98.5%
  • CMake 1.2%
  • Shell 0.2%
  • Makefile 0.1%
Find a file
Evan Burkey ffa5fed79e
All checks were successful
test / test (push) Successful in 9s
fix vec_shrink: replace BSD reallocf with standard realloc
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-04-03 14:01:59 -07:00
.forgejo/workflows fix CI: add libbsd-dev and skip slow tests in container 2026-04-03 13:59:55 -07:00
include fix ~60 bugs, add NULL checks, expand test coverage across all 14 modules 2026-03-14 12:15:01 -07:00
src fix vec_shrink: replace BSD reallocf with standard realloc 2026-04-03 14:01:59 -07:00
tests fix ~60 bugs, add NULL checks, expand test coverage across all 14 modules 2026-03-14 12:15:01 -07:00
.gitignore fix ~60 bugs, add NULL checks, expand test coverage across all 14 modules 2026-03-14 12:15:01 -07:00
clanggen.sh Implement Server (#1) 2024-07-09 21:03:23 +00:00
CMakeLists.txt fix ~60 bugs, add NULL checks, expand test coverage across all 14 modules 2026-03-14 12:15:01 -07:00
LICENSE init 2021-02-01 14:06:37 -08:00
Makefile fix compiler warnings 2024-08-13 12:57:36 -07:00
README.md ci and docs 2026-04-03 13:57:47 -07:00

libflint

My personal library of common C data structures and algorithms. Supports Linux, macOS, OpenBSD, and FreeBSD.

Documentation

Extensive documentation can be found here. You can also check out the per-module test files in tests/ for example usage.

Building

libflint requires Cmake to be built. It can then be built using either cmake or make with the provided build files. The Makefile is a wrapper around Cmake for Makefile compatibility.

Cmake

If libflint is in ./lib/libflint

add_subdirectory(lib/libflint)

when building target...

target_include_directories(${TARGET} PRIVATE lib/libflint/include) target_link_libraries(${TARGET} PRIVATE flint )

Testing

cmake -B build && cmake --build build
ctest --test-dir build                # run all tests
ctest --test-dir build --parallel     # run in parallel
ctest --test-dir build --label-exclude slow  # skip slow tests (network, macos)

Requirements

Building on Linux requires libbsd. Building on macOS, OpenBSD, or FreeBSD requires no extra dependencies.

Libraries

libflint includes uthash for a hash table implementation. uthash is a single header file included in the source code of libflint. See the top of include/uthash.h for license information