• R/O
  • SSH

pm_kvm_tools: Commit

※ リポジトリは、https://github.com/linux-ha-japan/pm_kvm_tools-1.0 へ移行しました。
仮想環境監視連携機能とSTONITH機能。KVM版。


Commit MetaInfo

Revisiona9f7a7361f569e4b313aa2c83b70d8b68448e922 (tree)
Time2011-09-15 16:04:14
AuthorKazunori INOUE <inouekazu@inte...>
CommiterKazunori INOUE

Log Message

Add README and configure.ac

Change Summary

Incremental Difference

diff -r 441a96ed873f -r a9f7a7361f56 configure.ac
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/configure.ac Thu Sep 15 16:04:14 2011 +0900
@@ -0,0 +1,131 @@
1+# -*- Autoconf -*-
2+# Process this file with autoconf to produce a configure script.
3+
4+AC_PREREQ([2.53])
5+AC_INIT([pm_kvm_tools], [1.0], [BUG-REPORT-ADDRESS])
6+AM_INIT_AUTOMAKE
7+AC_CONFIG_SRCDIR([lib/vm_connect.c])
8+AC_CONFIG_HEADERS([include/config.h])
9+
10+# Checks for programs.
11+AC_PROG_CC
12+AC_PROG_LIBTOOL
13+AC_PROG_INSTALL
14+AC_PROG_LN_S
15+AC_PROG_MAKE_SET
16+AC_PROG_RANLIB
17+
18+dnl ===============================================
19+dnl Helpers
20+dnl ===============================================
21+extract_header_define() {
22+ AC_MSG_CHECKING(for $2 in $1)
23+ Cfile=/tmp/extract_define.$2.${$}
24+ printf "#include <stdio.h>\n" > ${Cfile}.c
25+ printf "#include <%s>\n" $1 >> ${Cfile}.c
26+ printf "int main(int argc, char **argv) { printf(\"%%s\", %s); return 0; }\n" $2 >> ${Cfile}.c
27+ $CC $CFLAGS ${Cfile}.c -o ${Cfile}
28+ value=`${Cfile}`
29+ AC_MSG_RESULT($value)
30+ printf $value
31+ rm -f ${Cfile}.c ${Cfile}
32+ }
33+
34+dnl ===============================================
35+dnl General Processing
36+dnl ===============================================
37+echo Our Host OS: $host_os/$host
38+
39+# Checks for typedefs, structures, and compiler characteristics.
40+dnl Fix default variables - "prefix" variable if not specified
41+if test "$prefix" = "NONE"; then
42+ prefix="/usr"
43+
44+ dnl Fix "localstatedir" variable if not specified
45+ if test "$localstatedir" = "\${prefix}/var"; then
46+ localstatedir="/var"
47+ fi
48+ dnl Fix "sysconfdir" variable if not specified
49+ if test "$sysconfdir" = "\${prefix}/etc"; then
50+ sysconfdir="/etc"
51+ fi
52+ dnl Fix "libdir" variable if not specified
53+ if test "$libdir" = "\${exec_prefix}/lib"; then
54+ if test -e /usr/lib64; then
55+ libdir="/usr/lib64"
56+ else
57+ libdir="/usr/lib"
58+ fi
59+ fi
60+fi
61+
62+CFLAGS="$CFLAGS -I${prefix}/include/heartbeat"
63+
64+# Checks for header files.
65+AC_CHECK_HEADERS([getopt.h])
66+AC_CHECK_HEADERS([hb_config.h])
67+AC_CHECK_HEADERS([glue_config.h])
68+AC_CHECK_HEADERS([agent_config.h])
69+
70+GLUE_HEADER=none
71+if test "$ac_cv_header_glue_config_h" = "yes"; then
72+ GLUE_HEADER=glue_config.h
73+elif test "$ac_cv_header_hb_config_h" = "yes"; then
74+ GLUE_HEADER=hb_config.h
75+else
76+ AC_MSG_FAILURE(Core development headers were not found)
77+fi
78+
79+OCF_RA_DIR=`extract_header_define $GLUE_HEADER OCF_RA_DIR`
80+AC_DEFINE_UNQUOTED(OCF_RA_DIR,"$OCF_RA_DIR", Location for OCF RAs)
81+AC_SUBST(OCF_RA_DIR)
82+
83+stonith_ext_plugindir="${libdir}/stonith/plugins/external"
84+AC_SUBST(stonith_ext_plugindir)
85+
86+eval prefix="`eval echo ${prefix}`"
87+eval exec_prefix="`eval echo ${prefix}`"
88+eval bindir="`eval echo ${bindir}`"
89+eval sbindir="`eval echo ${sbindir}`"
90+eval libexecdir="`eval echo ${libexecdir}`"
91+eval datadir="`eval echo ${datadir}`"
92+eval sysconfdir="`eval echo ${sysconfdir}`"
93+eval sharedstatedir="`eval echo ${sharedstatedir}`"
94+eval localstatedir="`eval echo ${localstatedir}`"
95+eval libdir="`eval echo ${libdir}`"
96+eval includedir="`eval echo ${includedir}`"
97+eval oldincludedir="`eval echo ${oldincludedir}`"
98+eval infodir="`eval echo ${infodir}`"
99+eval mandir="`eval echo ${mandir}`"
100+
101+AC_CONFIG_FILES(Makefile \
102+ pm_kvm_tools.spec \
103+ include/Makefile \
104+ lib/Makefile \
105+ tools/Makefile \
106+ plugins/Makefile \
107+ resources/Makefile \
108+ conf/Makefile
109+)
110+
111+AC_OUTPUT
112+
113+dnl *****************
114+dnl Configure summary
115+dnl *****************
116+
117+AC_MSG_RESULT([])
118+AC_MSG_RESULT([$PACKAGE configuration:])
119+AC_MSG_RESULT([ Version = ${VERSION}])
120+AC_MSG_RESULT([])
121+AC_MSG_RESULT([ Prefix = ${prefix}])
122+AC_MSG_RESULT([ Executables = ${sbindir}])
123+AC_MSG_RESULT([ Man pages = ${mandir}])
124+AC_MSG_RESULT([ Libraries = ${libdir}])
125+AC_MSG_RESULT([ Header files = ${includedir}])
126+AC_MSG_RESULT([ Arch-independent files = ${datadir}])
127+AC_MSG_RESULT([ State information = ${localstatedir}])
128+AC_MSG_RESULT([ System configuration = ${sysconfdir}])
129+AC_MSG_RESULT([])
130+AC_MSG_RESULT([ CFLAGS = ${CFLAGS}])
131+AC_MSG_RESULT([ Libraries = ${LIBS}])
Show on old repository browser