Commit d4216637b7ae537ed98f53a4ccfc4c6f1fdaf57b
1 parent
e4496fd6
- Add glib-2.0 dependency in modbus.pc
- Fix modbus.h path
Showing
2 changed files
with
4 additions
and
2 deletions
configure.ac
| @@ -15,6 +15,8 @@ AM_PATH_GLIB_2_0(2.0.0,,AC_MSG_ERROR(libmodbus needs GLib 2.X)) | @@ -15,6 +15,8 @@ AM_PATH_GLIB_2_0(2.0.0,,AC_MSG_ERROR(libmodbus needs GLib 2.X)) | ||
| 15 | PKG_CHECK_MODULES(GLIB, glib-2.0) | 15 | PKG_CHECK_MODULES(GLIB, glib-2.0) |
| 16 | AC_SUBST(GLIB_CFLAGS) | 16 | AC_SUBST(GLIB_CFLAGS) |
| 17 | AC_SUBST(GLIB_LIBS) | 17 | AC_SUBST(GLIB_LIBS) |
| 18 | +# Optional requirements to report via pkg-config (in modbus.pc) | ||
| 19 | +modbus_pkgdeps="glib-2.0" | ||
| 18 | 20 | ||
| 19 | # Checks for header files. | 21 | # Checks for header files. |
| 20 | AC_HEADER_STDC | 22 | AC_HEADER_STDC |
| @@ -30,6 +32,7 @@ AC_FUNC_MALLOC | @@ -30,6 +32,7 @@ AC_FUNC_MALLOC | ||
| 30 | AC_FUNC_SELECT_ARGTYPES | 32 | AC_FUNC_SELECT_ARGTYPES |
| 31 | AC_CHECK_FUNCS([inet_ntoa memset select socket]) | 33 | AC_CHECK_FUNCS([inet_ntoa memset select socket]) |
| 32 | 34 | ||
| 35 | +AC_SUBST(modbus_pkgdeps) | ||
| 33 | AC_OUTPUT([ | 36 | AC_OUTPUT([ |
| 34 | Makefile | 37 | Makefile |
| 35 | src/Makefile | 38 | src/Makefile |
| @@ -37,4 +40,3 @@ include/Makefile | @@ -37,4 +40,3 @@ include/Makefile | ||
| 37 | include/modbus/Makefile | 40 | include/modbus/Makefile |
| 38 | modbus.pc | 41 | modbus.pc |
| 39 | ]) | 42 | ]) |
| 40 | - |
include/modbus/Makefile.am
| 1 | ## Process this file with automake to produce Makefile.in | 1 | ## Process this file with automake to produce Makefile.in |
| 2 | 2 | ||
| 3 | # Include files to install | 3 | # Include files to install |
| 4 | -libmodbusincludedir = $(includedir)/libmodbus | 4 | +libmodbusincludedir = $(includedir)/modbus |
| 5 | libmodbusinclude_HEADERS = modbus.h | 5 | libmodbusinclude_HEADERS = modbus.h |
| 6 | \ No newline at end of file | 6 | \ No newline at end of file |