snipplets.dev/snipplets/code/C/libserialport
..
Board
.editorconfig
.gitignore
build_gcc
build_tcc
clear
format-code
listen.c
README.md

Download libserialport library.

git clone git://sigrok.org/libserialport

For build code use build script or build files manually.

Example:

export C_INCLUDE_PATH=<path/to/libserialport>
export LIBRARY_PATH=<path/to/libserialport/.libs>

gcc -static -Wall -O3 -o <output_filename> <file.c> -lserialport

Arduino example project store in Board folder.