From d08d812c3025474d47a090626b8ee14fcb89f883 Mon Sep 17 00:00:00 2001 From: Sean Middleditch Date: Sat, 19 Sep 2009 14:35:05 -0700 Subject: pkgconfig support --- .gitignore | 1 + Makefile.am | 3 +++ configure.ac | 6 ++---- libtelnet.pc.in | 10 ++++++++++ 4 files changed, 16 insertions(+), 4 deletions(-) create mode 100644 libtelnet.pc.in diff --git a/.gitignore b/.gitignore index d5db3c1..e8d2580 100644 --- a/.gitignore +++ b/.gitignore @@ -19,3 +19,4 @@ autom4te.cache telnet-proxy telnet-client telnet-chatd +libtelnet.pc diff --git a/Makefile.am b/Makefile.am index dd7fe68..8075823 100644 --- a/Makefile.am +++ b/Makefile.am @@ -1,3 +1,6 @@ +pkgconfigdir = $(libdir)/pkgconfig +pkgconfig_DATA = libtelnet.pc + libtelnet_includedir = $(includedir) libtelnet_include_HEADERS = libtelnet.h diff --git a/configure.ac b/configure.ac index 1eda608..3285f95 100644 --- a/configure.ac +++ b/configure.ac @@ -1,4 +1,4 @@ -AC_INIT([libtelnet], [0.11], [http://github.com/elanthis/libtelnet/tree/master]) +AC_INIT([libtelnet], [0.12], [http://github.com/elanthis/libtelnet/tree/master]) AM_INIT_AUTOMAKE @@ -10,9 +10,7 @@ AC_CHECK_LIB(z,deflate,ZLIB=yes,ZLIB=no) if test "x$ZLIB" = "xyes" ; then LIBS="$LIBS -lz" AC_DEFINE(HAVE_ZLIB, 1, [We have zlib]) - LIBTELNET_HAVE_ZLIB="-DHAVE_ZLIB" - AC_SUBST(LIBTELNET_HAVE_ZLIB) fi -AC_CONFIG_FILES(Makefile) +AC_CONFIG_FILES([Makefile libtelnet.pc]) AC_OUTPUT diff --git a/libtelnet.pc.in b/libtelnet.pc.in new file mode 100644 index 0000000..293125b --- /dev/null +++ b/libtelnet.pc.in @@ -0,0 +1,10 @@ +prefix=@prefix@ +exec_prefix=@exec_prefix@ +libdir=@libdir@ +includedir=${prefix}/include + +Name: libtelnet +Description: TELNET protocol handling library +Version: @VERSION@ +Libs: -L${libdir} -ltelnet @LIBS@ +Cflags: -I${includedir} -- cgit v1.2.3