diff --git a/Makefile.am b/Makefile.am index 1984dc1..a599ece 100644 --- a/Makefile.am +++ b/Makefile.am @@ -10,6 +10,8 @@ libite_la_CPPFLAGS = -D_GNU_SOURCE libite_la_CFLAGS = -W -Wall -Wextra libite_la_LDFLAGS = $(AM_LDFLAGS) -version-info 2:1:0 +pkgconfigdir = $(libdir)/pkgconfig +pkgconfig_DATA = libite.pc doc_DATA = README.md LICENSE EXTRA_DIST = README.md LICENSE ChangeLog.md diff --git a/README.md b/README.md index fd85480..37c404e 100644 --- a/README.md +++ b/README.md @@ -8,10 +8,10 @@ developed by both [Finit][1] and the [OpenBSD][2] project. Most notably the string functions: [strlcpy(3)][3], [strlcat(3)][3] and the highly useful *BSD [sys/queue.h][4] and [sys/tree.h][7] API's. -Libite aims to fill in the gaps missing in GLIBC/EGLIBC. (It does not -aimo to become another [GLIB][5] though.) One such gap in GLIBC is the -missing `_SAFE` macros in `sys/queue.h` — highly recommended when -traversing lists to delete/free nodes. +Libite is the frog DNA missing in GNU libc. However, -lite does not aim +to become another [GLIB][5]! One noticeable gap in GLIBC is the missing +`_SAFE` macros in tje BSD `sys/queue.h` API — highly recommended +when traversing lists to delete/free nodes. The code is open sourced under a mix of the [MIT/X11 license][MIT], the [ISC license][ISC] used by OpenBSD, and [BSD licenses][BSD], all of them @@ -22,6 +22,25 @@ For an introduction to why Libite happened, and how you can use it, see [this blog post][6]. +Using -lite +----------- + +Libite is by default installed as a library and a set of include files. +To prevent clashing with include files of the same name -lite employs a +include file namespace `lite/`, which is recommended to use in your +applications: + + #include + #include + #include + #include + +The output from the `pkg-config` tool holds no surprises: + + $ pkg-config --libs --static --cflags libite + -I/usr/local/include -L/usr/local/lib -lite @LTLIBINTL@ + + Helper Macros ------------- diff --git a/configure.ac b/configure.ac index 4defac1..03810de 100644 --- a/configure.ac +++ b/configure.ac @@ -6,7 +6,7 @@ AM_SILENT_RULES([yes]) AC_CONFIG_SRCDIR(lite.h) AM_CONFIG_HEADER(config.h) -AC_CONFIG_FILES([Makefile]) +AC_CONFIG_FILES([Makefile libite.pc]) AC_CONFIG_MACRO_DIR([m4]) AC_PROG_CC diff --git a/libite.pc.in b/libite.pc.in new file mode 100644 index 0000000..ee3c56d --- /dev/null +++ b/libite.pc.in @@ -0,0 +1,12 @@ +prefix=@prefix@ +exec_prefix=@exec_prefix@ +libdir=@libdir@ +includedir=@includedir@ + +Name: @PACKAGE@ +Description: Frog DNA, basically +Version: @VERSION@ +Requires: +Libs: -L${libdir} -lite @LTLIBINTL@ +Cflags: -I${includedir} +