6 |
|
# |
7 |
|
|
8 |
|
# Change these to change the package name and version |
9 |
< |
AC_INIT(ihost, 1.5.7, bugs@i-scream.org) |
10 |
< |
AM_INIT_AUTOMAKE(ihost, 1.5.7) |
9 |
> |
AC_INIT(ihost, 1.5.9, bugs@i-scream.org) |
10 |
> |
AM_INIT_AUTOMAKE(ihost, 1.5.9) |
11 |
|
|
12 |
|
# Revision number (automatically updated) |
13 |
|
AC_REVISION($Revision$) |
75 |
|
solaris2.*) |
76 |
|
AC_CHECK_LIB(ukcprog, fpgetline,[:],[AC_MSG_ERROR([need libukcprog])],[-lnsl -lsocket]) |
77 |
|
AC_DEFINE(SOLARIS, , [Building on Solaris 2.x]) |
78 |
< |
LIBS="$LIBS -lnsl -lsocket -lkstat -ldevinfo -Wl,-Bstatic -lstatgrab -lukcprog -Wl,-Bdynamic" |
78 |
> |
LIBS="$LIBS -lnsl -lsocket -lkstat -ldevinfo -lstatgrab -lukcprog" |
79 |
|
;; |
80 |
|
freebsd*) |
81 |
|
AC_CHECK_LIB(ukcprog, fpgetline,[:],[AC_MSG_ERROR([need libukcprog])]) |
82 |
|
AC_DEFINE(ALLBSD, , [Building on a BSD-derived system]) |
83 |
|
AC_DEFINE(FREEBSD, , [Building on FreeBSD]) |
84 |
< |
LIBS="$LIBS -lstatgrab -lkvm -ldevstat -lukcprog -static" |
84 |
> |
LIBS="$LIBS -lstatgrab -lkvm -ldevstat -lukcprog" |
85 |
|
# FreeBSD needs ihost to be setgid kmem |
86 |
|
AM_CONDITIONAL(SETGIDKMEM, true) |
87 |
|
;; |
89 |
|
AC_CHECK_LIB(ukcprog, fpgetline,[:],[AC_MSG_ERROR([need libukcprog])]) |
90 |
|
AC_DEFINE(ALLBSD, , [Building on a BSD-derived system]) |
91 |
|
AC_DEFINE(NETBSD, , [Building on NetBSD]) |
92 |
< |
LIBS="$LIBS -lstatgrab -lkvm -lukcprog -static" |
92 |
> |
LIBS="$LIBS -lstatgrab -lkvm -lukcprog" |
93 |
|
AM_CONDITIONAL(SETGIDKMEM, true) |
94 |
|
;; |
95 |
|
linux-gnu) |
96 |
|
AC_CHECK_LIB(ukcprog, fpgetline,[:],[AC_MSG_ERROR([need libukcprog])]) |
97 |
|
AC_DEFINE(LINUX, , [Building on GNU/Linux]) |
98 |
< |
LIBS="$LIBS -lstatgrab -lukcprog -static" |
98 |
> |
LIBS="$LIBS -lstatgrab -lukcprog" |
99 |
|
;; |
100 |
|
cygwin) |
101 |
< |
AC_DEFINE(CYGWIN, , [Building on Cygwin]) |
101 |
> |
AC_MSG_ERROR([libstatgrab doesn't fully support cygwin, yet]) |
102 |
|
;; |
103 |
|
*) |
104 |
|
AC_MSG_ERROR([Cannot build on unknown OS: $host_os]) |
106 |
|
esac |
107 |
|
|
108 |
|
# Check for libstatgrab |
109 |
< |
AC_CHECK_LIB(statgrab, get_general_stats,[:],[AC_MSG_ERROR([need libstatgrab])]) |
109 |
> |
AC_CHECK_LIB(statgrab, sg_get_host_info,[:],[AC_MSG_ERROR([need libstatgrab])]) |
110 |
|
|
111 |
|
# Check for the --with-pid-file option |
112 |
|
AC_ARG_WITH([pid-file], [ --with-pid-file=FILE location of PID file (default: /var/tmp/.ihost.pid)], [pidfile=$withval], [pidfile=[/var/tmp/.ihost.pid]]) |