Next: , Up: overview   [Contents][Index]


1.1 Linking code with the library

This package installs a data file for pkg-config, so when searching for the installed library with the GNU Autotools, we can add the following macro use to configure.ac:

PKG_CHECK_MODULES([CCTESTS],[cctests >= 0.1.0])

which will set the variables CCTESTS_LIBS and CCTESTS_CFLAGS. To avoid problems with pkg-config, we need to remember that:

Alternatively we can use the raw GNU Autoconf macros:

AC_CHECK_LIB([cctests],[cctests_version_string],,
  [AC_MSG_FAILURE([test for CCTests library failed])])
AC_CHECK_HEADERS([cctests.h],,
  [AC_MSG_FAILURE([test for CCTests header failed])])

Next: , Up: overview   [Contents][Index]

This document describes version 0.4.1-devel.1 of CCTests.