popt

C library for parsing command-line options with more features than getopt

brewmacoslinux
Try with needOr install directly
Source

About

Library like getopt(3) with a number of enhancements

Commands

popt

Examples

popt is primarily a library, not a CLI tool. Developers use it in C programs to parse command-line arguments with enhanced features like automatic --help/--version handling$ gcc -o myapp myapp.c $(pkg-config --cflags --libs popt)
Link against popt library when compiling applications that need advanced option parsing$ cc -lpopt program.c -o program
Check popt library documentation and version information$ pkg-config --modversion popt