All of lore.kernel.org
 help / color / mirror / Atom feed
* [Cluster-devel] [PATCH] fencing: Add support for ipmitool/amttool binaries during autoconf
@ 2013-12-02 15:39 Marek 'marx' Grac
  2013-12-02 18:13 ` Fabio M. Di Nitto
  0 siblings, 1 reply; 2+ messages in thread
From: Marek 'marx' Grac @ 2013-12-02 15:39 UTC (permalink / raw)
  To: cluster-devel.redhat.com

Configuration of autoconf was extended to dynamically find ipmitool/amttool. If the binary is not found on
the system then we will switch to default values (Fedora/RHEL). Path to binaries is exported and replaced in
fencebuild using same processes as a version number or sbin/logdir.
---
 configure.ac       |    6 ++++++
 make/fencebuild.mk |    2 ++
 2 files changed, 8 insertions(+), 0 deletions(-)

diff --git a/configure.ac b/configure.ac
index 6f4baa0..02c46b8 100644
--- a/configure.ac
+++ b/configure.ac
@@ -163,6 +163,9 @@ LOGDIR=${localstatedir}/log/cluster
 CLUSTERVARRUN=${localstatedir}/run/cluster
 CLUSTERDATA=${datadir}/cluster
 
+## path to 3rd-party binaries
+AC_PATH_PROG([IPMITOOL_PATH], [ipmitool], [/usr/bin/ipmitool])
+AC_PATH_PROG([AMTTOOL_PATH], [amttool], [/usr/bin/amttool])
 ## do subst
 
 AC_SUBST([DEFAULT_CONFIG_DIR])
@@ -187,6 +190,9 @@ AC_SUBST([SNMPBIN])
 AC_SUBST([AGENTS_LIST])
 AM_CONDITIONAL(BUILD_XENAPILIB, test $XENAPILIB -eq 1)
 
+AC_SUBST([IPMITOOL_PATH])
+AC_SUBST([AMTTOOL_PATH])
+
 ## *FLAGS handling
 
 ENV_CFLAGS="$CFLAGS"
diff --git a/make/fencebuild.mk b/make/fencebuild.mk
index 15a47fd..5cbe3bd 100644
--- a/make/fencebuild.mk
+++ b/make/fencebuild.mk
@@ -9,6 +9,8 @@ $(TARGET): $(SRC)
 		-e 's#@''LOGDIR@#${LOGDIR}#g' \
 		-e 's#@''SBINDIR@#${sbindir}#g' \
 		-e 's#@''LIBEXECDIR@#${libexecdir}#g' \
+		-e 's#@''IPMITOOL_PATH#${IPMITOOL_PATH}#g' \
+		-e 's#@''AMTTOOL_PATH#${AMTTOOL_PATH}#g' \
 	> $@
 
 	if [ 0 -eq `echo "$(SRC)" | grep fence_ &> /dev/null; echo $$?` ]; then \
-- 
1.7.7.6



^ permalink raw reply related	[flat|nested] 2+ messages in thread

* [Cluster-devel] [PATCH] fencing: Add support for ipmitool/amttool binaries during autoconf
  2013-12-02 15:39 [Cluster-devel] [PATCH] fencing: Add support for ipmitool/amttool binaries during autoconf Marek 'marx' Grac
@ 2013-12-02 18:13 ` Fabio M. Di Nitto
  0 siblings, 0 replies; 2+ messages in thread
From: Fabio M. Di Nitto @ 2013-12-02 18:13 UTC (permalink / raw)
  To: cluster-devel.redhat.com

Thanks for doing it, we still need to change the agent to use
IPMITOOL_PATH & co. :)

Fabio

On 12/02/2013 04:39 PM, Marek 'marx' Grac wrote:
> Configuration of autoconf was extended to dynamically find ipmitool/amttool. If the binary is not found on
> the system then we will switch to default values (Fedora/RHEL). Path to binaries is exported and replaced in
> fencebuild using same processes as a version number or sbin/logdir.
> ---
>  configure.ac       |    6 ++++++
>  make/fencebuild.mk |    2 ++
>  2 files changed, 8 insertions(+), 0 deletions(-)
> 
> diff --git a/configure.ac b/configure.ac
> index 6f4baa0..02c46b8 100644
> --- a/configure.ac
> +++ b/configure.ac
> @@ -163,6 +163,9 @@ LOGDIR=${localstatedir}/log/cluster
>  CLUSTERVARRUN=${localstatedir}/run/cluster
>  CLUSTERDATA=${datadir}/cluster
>  
> +## path to 3rd-party binaries
> +AC_PATH_PROG([IPMITOOL_PATH], [ipmitool], [/usr/bin/ipmitool])
> +AC_PATH_PROG([AMTTOOL_PATH], [amttool], [/usr/bin/amttool])
>  ## do subst
>  
>  AC_SUBST([DEFAULT_CONFIG_DIR])
> @@ -187,6 +190,9 @@ AC_SUBST([SNMPBIN])
>  AC_SUBST([AGENTS_LIST])
>  AM_CONDITIONAL(BUILD_XENAPILIB, test $XENAPILIB -eq 1)
>  
> +AC_SUBST([IPMITOOL_PATH])
> +AC_SUBST([AMTTOOL_PATH])
> +
>  ## *FLAGS handling
>  
>  ENV_CFLAGS="$CFLAGS"
> diff --git a/make/fencebuild.mk b/make/fencebuild.mk
> index 15a47fd..5cbe3bd 100644
> --- a/make/fencebuild.mk
> +++ b/make/fencebuild.mk
> @@ -9,6 +9,8 @@ $(TARGET): $(SRC)
>  		-e 's#@''LOGDIR@#${LOGDIR}#g' \
>  		-e 's#@''SBINDIR@#${sbindir}#g' \
>  		-e 's#@''LIBEXECDIR@#${libexecdir}#g' \
> +		-e 's#@''IPMITOOL_PATH#${IPMITOOL_PATH}#g' \
> +		-e 's#@''AMTTOOL_PATH#${AMTTOOL_PATH}#g' \
>  	> $@
>  
>  	if [ 0 -eq `echo "$(SRC)" | grep fence_ &> /dev/null; echo $$?` ]; then \
> 



^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2013-12-02 18:13 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2013-12-02 15:39 [Cluster-devel] [PATCH] fencing: Add support for ipmitool/amttool binaries during autoconf Marek 'marx' Grac
2013-12-02 18:13 ` Fabio M. Di Nitto

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.