1 # Configure paths for libsmi.
4 dnl Test for libsmi and defines the symbol LIBSMI if the test is
5 dnl successful. Also defines HAVE_LIBSMI_H and adds -llibsmi to the
8 AC_DEFUN([AM_PATH_LIBSMI],
10 AC_CHECK_HEADERS(smi.h)
11 AC_CHECK_LIB(smi, smiInit)
12 AC_MSG_CHECKING([whether to enable libsmi])
13 AC_TRY_RUN([ /* libsmi available check */
17 int current, revision, age, n;
18 const int required = 2;
21 if (strcmp(SMI_LIBRARY_VERSION, smi_library_version))
23 n = sscanf(smi_library_version, "%d:%d:%d", ¤t, &revision, &age);
26 if (required < current - age || required > current)
35 [ AC_MSG_RESULT(not when cross-compiling)