Commit 83adabfa3e7869ca73f2e245dd14ee48356b6d9d

Authored by Stéphane Raimbault
1 parent 1fca027f

Add -lsocket to compile on QNX

configure.ac
@@ -54,8 +54,12 @@ case "${host_os}" in @@ -54,8 +54,12 @@ case "${host_os}" in
54 *mingw32*) 54 *mingw32*)
55 os_win32="true" 55 os_win32="true"
56 ;; 56 ;;
  57 + *nto-qnx*)
  58 + os_qnx="true"
  59 + ;;
57 esac 60 esac
58 AM_CONDITIONAL(OS_WIN32, test "$os_win32" = "true") 61 AM_CONDITIONAL(OS_WIN32, test "$os_win32" = "true")
  62 +AM_CONDITIONAL(OS_QNX, test "$os_qnx" = "true")
59 63
60 # Checks for programs. 64 # Checks for programs.
61 AC_PROG_CC 65 AC_PROG_CC
src/Makefile.am
@@ -16,6 +16,10 @@ if OS_WIN32 @@ -16,6 +16,10 @@ if OS_WIN32
16 libmodbus_la_LIBADD = -lwsock32 16 libmodbus_la_LIBADD = -lwsock32
17 endif 17 endif
18 18
  19 +if OS_QNX
  20 +libmodbus_la_LIBADD = -lsocket
  21 +endif
  22 +
19 libmodbus_la_LDFLAGS = $(AM_LDFLAGS) -no-undefined -version-info $(LIBMODBUS_LT_VERSION_INFO) 23 libmodbus_la_LDFLAGS = $(AM_LDFLAGS) -no-undefined -version-info $(LIBMODBUS_LT_VERSION_INFO)
20 24
21 # Header files to install 25 # Header files to install