devel/tllist 1.1.0 FreeBSD
C header file only implementation of a typed linked list
- System
- FreeBSD
- Repository
- FreeBSD ports
- Maintainer
- [email protected]
- License
- MIT
- Categories
- devel
- Package size
- 4.5 KiB, 14.3 KiB installed
Description
Most C implementations of linked list are untyped. That is, their data carriers are typically void *. This is error prone since your compiler will not be able to help you correct your mistakes (oh, was it a pointer-to-a-pointer... I thought it was just a pointer...).
tllist addresses this by using pre-processor macros to implement dynamic types, where the data carrier is typed to whatever you want; both primitive data types are supported as well as aggregated ones such as structs, enums and unions.
Being a double-linked list, most operations are constant in time (including pushing and popping both to/from front and back).
The memory overhead is fairly small; each item carries, besides its data, a prev and next pointer (i.e. a constant 16 byte overhead per item on 64-bit architectures).
The list itself has two head and tail pointers, plus a length variable (typically 8 bytes on 64-bit architectures) to make list length lookup constant in time.
Thus, assuming 64-bit pointers (and a 64-bit size_t type), the total overhead is 3*8 + n*2*8 bytes.
In the other systems
| System | Port | Version |
|---|---|---|
| FreeBSD | devel/tllist | 1.1.0 |
| OpenBSD | devel/tllist | 1.1.0p0 |
| NetBSD | devel/tllist | 1.1.0 |
| DragonFly | devel/tllist | 1.1.0 |
| MidnightBSD | devel/tllist | 1.1.0 |
| HardenedBSD | devel/tllist | 1.1.0 |
| GhostBSD | devel/tllist | 1.1.0 |
Install
Binary package:
pkg install tllist
From the ports tree:
cd /usr/ports/devel/tllist/ && make install clean
To depend on this port in another port's Makefile:
RUN_DEPENDS= tllist>0:devel/tllist
Packages
The version each package repository carries. “-” means the repository builds no package of it, “n/a” that there is no such repository.
| Repository | aarch64 | amd64 | armv6 | armv7 | i386 |
|---|---|---|---|---|---|
| FreeBSD:14:latest | 1.1.0 | 1.1.0 | 1.1.0 | 1.1.0 | 1.1.0 |
| FreeBSD:14:quarterly | 1.1.0 | 1.1.0 | n/a | 1.1.0 | 1.1.0 |
| FreeBSD:15:latest | 1.1.0 | 1.1.0 | n/a | 1.1.0 | 1.1.0 |
| FreeBSD:15:quarterly | 1.1.0 | 1.1.0 | n/a | n/a | n/a |
| FreeBSD:16:latest | 1.1.0 | 1.1.0 | n/a | n/a | n/a |
| FreeBSD:16:quarterly | n/a | n/a | n/a | n/a | n/a |
Dependencies
The Makefile names none itself; they come from USES and USE_*.
The full lists below include those, and their dependencies in turn.
Build dependencies 9
Configuration
No options to configure.
- USES
- meson
- Service scripts
- none
Files
distinfo 1
| File | Size | SHA256 |
|---|---|---|
| tllist-1.1.0.tar.gz | 7639 | 0e7b7094a02550dd80b7243bcffc3671550b0f1d8ba625e4dff52517827d5d23 |
Master sites 1
- https://codeberg.org/dnkl/tllist/archive/${DISTVERSIONFULL}${EXTRACT_SUFX}?dummy=/
Commit history 0
No commits in the history this site was built from.