Skip to contentSkip to conversation

Cluster Project branch, master, updated. gfs-kernel_0_1_22-197-g717048d

Cluster-devel [email protected] 1 participant 1 message Apr 23, 2008

lore
Share & tools
lore
#0 lore raw

This is an automated email from the git hooks/post-receive script. It was generated because a ref change was pushed to the repository containing the project "Cluster Project".

http://sources.redhat.com/git/gitweb.cgi?p=cluster.git;a=commitdiff;h=717048ded0a562b49c2ec300646d390cff3f6e99

The branch, master has been updated

       via  717048ded0a562b49c2ec300646d390cff3f6e99 (commit)
      from  07e949fa5bc4eef61f16974bf1cc5a5adb9568a4 (commit)

Those revisions listed above that are new to this repository have not appeared on any other notification email; so we list those revisions in full, below.

- Log ----------------------------------------------------------------- commit 717048ded0a562b49c2ec300646d390cff3f6e99

Author: Fabio M. Di Nitto <[email protected]>
Date:   Wed Apr 23 08:52:05 2008 +0200

[BUILD] Deal with the new libfence properly

configure, make/defines.mk.input:
- rename fencelibdir to fenceagentslibdir to avoid name space collision.
- add fenceincdir and fencelibdir options for the shared library.

make/fencebuild.mk, make/install.mk, make/uninstall.mk, fence/agents/apc/apc.py, fence/agents/bladecenter/bladecenter.py, fence/agents/drac/drac5.py, fence/agents/ilo/ilo.py, fence/agents/lib/Makefile, fence/agents/wti/wti.py:
- rename fencelibdir to fenceagentslibdir.

fence/Makefile:
- build the shared lib.

fence/fence_node/Makefile, fence/fenced/Makefile:
- use fenceincdir and fencelibdir.
- add build-dep on the shared library.

fence/fence_tool/Makefile:
- remove obsolete depends target.

fence/fenced/fd.h:
- include "libfence.h" to fix implicit declaration when building fenced.

fence/lib/Makefile:
- build also static version of libfence.
- move ldflags at the end of the linking invokation call.

-----------------------------------------------------------------------

Summary of changes:

 configure                               |   26 ++++++++++++++++++++------
 fence/Makefile                          |    4 ++--
 fence/agents/apc/apc.py                 |    2 +-
 fence/agents/bladecenter/bladecenter.py |    2 +-
 fence/agents/drac/drac5.py              |    2 +-
 fence/agents/ilo/ilo.py                 |    2 +-
 fence/agents/lib/Makefile               |    2 +-
 fence/agents/wti/wti.py                 |    2 +-
 fence/fence_node/Makefile               |   10 ++++++----
 fence/fence_tool/Makefile               |   10 +++-------
 fence/fenced/Makefile                   |   11 +++++++----
 fence/fenced/fd.h                       |    1 +
 fence/lib/Makefile                      |   15 +++++++++++----
 make/defines.mk.input                   |    4 +++-
 make/fencebuild.mk                      |    4 ++--
 make/install.mk                         |    6 +++---
 make/uninstall.mk                       |    4 ++--
 17 files changed, 66 insertions(+), 41 deletions(-)
configure +20 -6
index 82268c6..e993d36 100755
@@ -52,6 +52,8 @@ my %options = (
 	cmanlibdir => \$cmanlibdir,
 	dlmincdir => \$dlmincdir,
 	dlmlibdir => \$dlmlibdir,
+	fenceincdir => \$fenceincdir,
+	fencelibdir => \$fencelibdir,
 	volidincdir => \$volidincdir,
 	volidlibdir => \$volidlibdir,
 	ncursesincdir => \$ncursesincdir,
@@ -81,7 +83,7 @@ my %options = (
 	confdir => \$confdir,
 	conffile => \$conffile,
 	fence_agents => \$fence_agents,
-	fencelibdir => \$fencelibdir,
+	fenceagentslibdir => \$fenceagentslibdir,
 	enable_experimental_fence_agents => \$enable_experimental_fence_agents,
 	enable_crack_of_the_day => \$enable_crack_of_the_day,
 	enable_xen => \$enable_xen,
@@ -122,6 +124,8 @@ my $err = &GetOptions (\%options,
 		    'cmanlibdir=s',
 		    'dlmincdir=s',
 		    'dlmlibdir=s',
+		    'fenceincdir=s',
+		    'fencelibdir=s',
 		    'volidincdir=s',
 		    'volidlibdir=s',
 		    'ncursesincdir=s',
@@ -154,7 +158,7 @@ my $err = &GetOptions (\%options,
 		    'sominor=s',
 		    'release_version=s',
 		    'fence_agents=s',
-		    'fencelibdir=s',
+		    'fenceagentslibdir=s',
 		    'enable_experimental_fence_agents',
 		    'enable_crack_of_the_day',
 		    'enable_xen',
@@ -209,6 +213,8 @@ if ($help || !$err) {
   print "--cmanlibdir=\tthe base directory for cman libraries.  (Default: ./cman/lib)\n";
   print "--dlmincdir=\tthe base directory for dlm include files.  (Default: ./dlm/lib)\n";
   print "--dlmlibdir=\tthe base directory for dlm libraries.  (Default: ./dlm/lib)\n";
+  print "--fenceincdir=\tthe base directory for fence include files.  (Default: ./fence/lib)\n";
+  print "--fencelibdir=\tthe base directory for fence libraries.  (Default: ./fence/lib)\n";
   print "--volidincdir=\tthe base directory for volume_id include files.  (Default: {incdir})\n";
   print "--volidlibdir=\tthe base directory for volume_id libraries.  (Default: {libdir})\n";
   print "--ncursesincdir=\tthe base directory for ncurses include files.  (Default: {incdir})\n";
@@ -230,7 +236,7 @@ if ($help || !$err) {
   print "--xenlibdir=\tthe base directory for xen libraries.  (Default: {libdir})\n";
   print "--fence_agents=\tlist of fence agents to configure.  (Default: all)\n";
   print "\t\tUse --fence_agents=help for a list\n";
-  print "--fencelibdir=\tspecify directory where to install common fence python lib.  (Default: /usr/lib/fence)\n";
+  print "--fenceagentslibdir=\tspecify directory where to install common fence python lib.  (Default: /usr/lib/fence)\n";
   print "--enable_experimental_fence_agents\tEnable build and install of experimental fence agents.  (Default: no)\n";
   print "--enable_crack_of_the_day\tEnable build of highly experimental features that rely on code that is not yet available for general use. (Default: no)\n";
   print "--enable_xen\tEnable building of Xen-specific pieces\n";
@@ -433,6 +439,12 @@ if (!$dlmincdir) {
 if (!$dlmlibdir) {
   $dlmlibdir="${objdir}/dlm/lib";
 }
+if (!$fenceincdir) {
+  $fenceincdir="${cdir}/fence/lib";
+}
+if (!$fencelibdir) {
+  $fencelibdir="${objdir}/fence/lib";
+}
 if (!$volidincdir) {
   $volidincdir="${incdir}";
 }
@@ -520,8 +532,8 @@ if (!$conffile) {
 if (!$fence_agents) {
   $fence_agents="all";
 }
-if (!$fencelibdir) {
-  $fencelibdir="/usr/lib/fence";
+if (!$fenceagentslibdir) {
+  $fenceagentslibdir="/usr/lib/fence";
 }
 if (!$enable_experimental_fence_agents) {
   $enable_experimental_fence_agents="";
@@ -625,6 +637,8 @@ while (<IFILE>) {
   $_ =~ s/\@CMANLIBDIR\@/$cmanlibdir/;
   $_ =~ s/\@DLMINCDIR\@/$dlmincdir/;
   $_ =~ s/\@DLMLIBDIR\@/$dlmlibdir/;
+  $_ =~ s/\@FENCEINCDIR\@/$fenceincdir/;
+  $_ =~ s/\@FENCELIBDIR\@/$fencelibdir/;
   $_ =~ s/\@VOLIDINCDIR\@/$volidincdir/;
   $_ =~ s/\@VOLIDLIBDIR\@/$volidlibdir/;
   $_ =~ s/\@READLINEINCDIR\@/$readlineincdir/;
@@ -653,7 +667,7 @@ while (<IFILE>) {
   $_ =~ s/\@CONFDIR\@/$confdir/;
   $_ =~ s/\@CONFFILE\@/$conffile/;
   $_ =~ s/\@FENCE_AGENTS\@/$fence_agents/;
-  $_ =~ s/\@FENCELIBDIR\@/$fencelibdir/;
+  $_ =~ s/\@FENCEAGENTSLIBDIR\@/$fenceagentslibdir/;
   $_ =~ s/\@ENABLE_EXPERIMENTAL_FENCE_AGENTS\@/$enable_experimental_fence_agents/;
   $_ =~ s/\@ENABLE_CRACK_OF_THE_DAY\@/$enable_crack_of_the_day/;
   $_ =~ s/\@ENABLE_XEN\@/$enable_xen/;
fence/Makefile +2 -2
index 8c3eccc..31734a4 100644
@@ -2,7 +2,7 @@
 ###############################################################################
 ##
 ##  Copyright (C) Sistina Software, Inc.  1997-2003  All rights reserved.
-##  Copyright (C) 2004 Red Hat, Inc.  All rights reserved.
+##  Copyright (C) 2004-2008 Red Hat, Inc.  All rights reserved.
 ##  
 ##  This copyrighted material is made available to anyone wishing to use,
 ##  modify, copy, or redistribute it subject to the terms and conditions
@@ -14,4 +14,4 @@
 include ../make/defines.mk
 include $(OBJDIR)/make/passthrough.mk
 
-SUBDIRS=agents fenced fence_node fence_tool man
+SUBDIRS=agents lib fenced fence_node fence_tool man
fence/agents/apc/apc.py +1 -1
index e26c2ca..59c5083 100755
@@ -13,7 +13,7 @@
 #####
 
 import sys, re, pexpect
-sys.path.append("@FENCELIBDIR@")
+sys.path.append("@FENCEAGENTSLIBDIR@")
 from fencing import *
 
 #BEGIN_VERSION_GENERATION
fence/agents/bladecenter/bladecenter.py +1 -1
index 675b921..e049735 100755
@@ -14,7 +14,7 @@
 #####
 
 import sys, re, pexpect
-sys.path.append("@FENCELIBDIR@")
+sys.path.append("@FENCEAGENTSLIBDIR@")
 from fencing import *
 
 #BEGIN_VERSION_GENERATION
fence/agents/drac/drac5.py +1 -1
index a94c5f6..f3e5a1d 100755
@@ -14,7 +14,7 @@
 #####
 
 import sys, re, pexpect
-sys.path.append("@FENCELIBDIR@")
+sys.path.append("@FENCEAGENTSLIBDIR@")
 from fencing import *
 
 #BEGIN_VERSION_GENERATION
fence/agents/ilo/ilo.py +1 -1
index 0db971b..dfc9d74 100755
@@ -13,7 +13,7 @@
 #####
 
 import sys, re, pexpect
-sys.path.append("@FENCELIBDIR@")
+sys.path.append("@FENCEAGENTSLIBDIR@")
 from fencing import *
 
 #BEGIN_VERSION_GENERATION
fence/agents/lib/Makefile +1 -1
index a9d8c77..76d96dc 100644
@@ -18,7 +18,7 @@ ifdef enable_experimental_fence_agents
 
 TARGET= fencing.py
 
-FENCELIB= $(TARGET)
+FENCEAGENTSLIB= $(TARGET)
 
 endif
 
fence/agents/wti/wti.py +1 -1
index bf64304..e72d449 100755
@@ -13,7 +13,7 @@
 #####
 
 import sys, re, pexpect
-sys.path.append("@FENCELIBDIR@")
+sys.path.append("@FENCEAGENTSLIBDIR@")
 from fencing import *
 
 #BEGIN_VERSION_GENERATION
fence/fence_node/Makefile +6 -4
index b9c96c4..b076479 100644
@@ -15,7 +15,7 @@ TARGET = fence_node
 
 SBINDIRT=$(TARGET)
 
-all: ${TARGET}
+all: depends ${TARGET}
 
 include ../../make/defines.mk
 include $(OBJDIR)/make/cobj.mk
@@ -27,16 +27,18 @@ OBJS=	fence_node.o
 
 CFLAGS += -D_FILE_OFFSET_BITS=64
 
-CFLAGS += -I${ccsincdir} -I../lib
+CFLAGS += -I${ccsincdir} -I${fenceincdir}
 CFLAGS += -I../include
 CFLAGS += -I${incdir}
 
-LDFLAGS += -L${ccslibdir} -lccs
-LDFLAGS += -L../lib -lfence
+LDFLAGS += -L${ccslibdir} -L${fencelibdir} -lccs -lfence
 
 ${TARGET}: ${OBJS}
 	$(CC) -o $@ $^ $(LDFLAGS)
 
+depends:
+	$(MAKE) -C ../lib
+
 clean: generalclean
 
 -include $(OBJS:.o=.d)
fence/fence_tool/Makefile +3 -7
index 0c56ed2..868a439 100644
@@ -2,7 +2,7 @@
 ###############################################################################
 ##
 ##  Copyright (C) Sistina Software, Inc.  1997-2003  All rights reserved.
-##  Copyright (C) 2004 Red Hat, Inc.  All rights reserved.
+##  Copyright (C) 2004-2008 Red Hat, Inc.  All rights reserved.
 ##  
 ##  This copyrighted material is made available to anyone wishing to use,
 ##  modify, copy, or redistribute it subject to the terms and conditions
@@ -15,7 +15,7 @@ TARGET = fence_tool
 
 SBINDIRT=$(TARGET)
 
-all: depends ${TARGET}
+all: ${TARGET}
 
 include ../../make/defines.mk
 include $(OBJDIR)/make/cobj.mk
@@ -23,8 +23,7 @@ include $(OBJDIR)/make/clean.mk
 include $(OBJDIR)/make/install.mk
 include $(OBJDIR)/make/uninstall.mk
 
-OBJS= ../fenced/agent.o \
-	fence_tool.o
+OBJS=fence_tool.o
 
 CFLAGS += -D_FILE_OFFSET_BITS=64
 CFLAGS += -I${ccsincdir} -I${cmanincdir}
@@ -37,9 +36,6 @@ LDFLAGS += -L../../group/lib -lgroup
 ${TARGET}: ${OBJS}
 	$(CC) -o $@ $^ $(LDFLAGS)
 
-depends:
-	$(MAKE) -C ../fenced agent.o
-
 clean: generalclean
 
 -include $(OBJS:.o=.d)
fence/fenced/Makefile +7 -4
index 555b430..bc94f39 100644
@@ -2,7 +2,7 @@
 ###############################################################################
 ##
 ##  Copyright (C) Sistina Software, Inc.  1997-2003  All rights reserved.
-##  Copyright (C) 2004 Red Hat, Inc.  All rights reserved.
+##  Copyright (C) 2004-2008 Red Hat, Inc.  All rights reserved.
 ##  
 ##  This copyrighted material is made available to anyone wishing to use,
 ##  modify, copy, or redistribute it subject to the terms and conditions
@@ -15,7 +15,7 @@ TARGET = fenced
 
 SBINDIRT=$(TARGET)
 
-all: ${TARGET}
+all: depends ${TARGET}
 
 include ../../make/defines.mk
 include $(OBJDIR)/make/cobj.mk
@@ -31,18 +31,21 @@ OBJS=	config.o \
 	recover.o
 
 CFLAGS += -D_FILE_OFFSET_BITS=64
-CFLAGS += -I${ccsincdir} -I${cmanincdir} -I${openaisincdir}
+CFLAGS += -I${ccsincdir} -I${cmanincdir} -I${fenceincdir} -I${openaisincdir}
 CFLAGS += -I$(S) -I$(S)/../include -I$(SRCDIR)/group/lib
 CFLAGS += -I${incdir}
 
 LDFLAGS += -L${ccslibdir} -L${cmanlibdir} -L${openaislibdir} -lccs -lcman -lcpg
-LDFLAGS += -L../lib -lfence
+LDFLAGS += -L${fencelibdir} -L${openaislibdir} -lfence -lcpg
 LDFLAGS += -L../../group/lib -l group
 
 
 ${TARGET}: ${OBJS}
 	$(CC) -o $@ $^ $(LDFLAGS)
 
+depends:
+	$(MAKE) -C ../lib
+
 clean: generalclean
 
 -include $(OBJS:.o=.d)
fence/fenced/fd.h +1 -0
index 2695de8..581a206 100644
@@ -41,6 +41,7 @@
 
 #include "list.h"
 #include "linux_endian.h"
+#include "libfence.h"
 
 /* Max name length for a group, pointless since we only ever create the
    "default" group.  Regardless, set arbitrary max to match dlm's
fence/lib/Makefile +11 -4
index d69d4f9..94a5064 100644
@@ -12,17 +12,20 @@
 
 TARGET= libfence
 
-LIBDIRT=$(TARGET).so.$(SOMAJOR).$(SOMINOR)
+LIBDIRT=$(TARGET).a \
+	$(TARGET).so.$(SOMAJOR).$(SOMINOR)
 
-LIBSYMT=$(TARGET).so.$(SOMAJOR)
+LIBSYMT=$(TARGET).so \
+	$(TARGET).so.$(SOMAJOR)
 
 INCDIRT=$(TARGET).h
 
 include ../../make/defines.mk
 
 SHAREDLIB=$(TARGET).so.${SOMAJOR}.${SOMINOR}
+STATICLIB=$(TARGET).a
 
-all: $(SHAREDLIB)
+all: $(STATICLIB) $(SHAREDLIB)
 
 include $(OBJDIR)/make/cobj.mk
 include $(OBJDIR)/make/clean.mk
@@ -37,8 +40,12 @@ CFLAGS += -I${incdir}
 
 LDFLAGS += -L${ccslibdir} -lccs
 
+$(TARGET).a: $(OBJS)
+	${AR} r $@ $^
+	${RANLIB} $@
+
 $(TARGET).so.${SOMAJOR}.${SOMINOR}: $(OBJS)
-	$(CC) $(LDFLAGS) -shared -o $@ -Wl,-soname=$(TARGET).so.$(SOMAJOR) $<
+	$(CC) -shared -o $@ -Wl,-soname=$(TARGET).so.$(SOMAJOR) $< $(LDFLAGS)
 	ln -sf $(TARGET).so.$(SOMAJOR).$(SOMINOR) $(TARGET).so
 	ln -sf $(TARGET).so.$(SOMAJOR).$(SOMINOR) $(TARGET).so.$(SOMAJOR)
 
make/defines.mk.input +3 -1
index acbbe36..63d639e 100644
@@ -46,6 +46,8 @@ cmanincdir ?= @CMANINCDIR@
 cmanlibdir ?= @CMANLIBDIR@
 dlmincdir ?= @DLMINCDIR@
 dlmlibdir ?= @DLMLIBDIR@
+fenceincdir ?= @FENCEINCDIR@
+fencelibdir ?= @FENCELIBDIR@
 volidincdir ?= @VOLIDINCDIR@
 volidlibdir ?= @VOLIDLIBDIR@
 readlineincdir ?= @READLINEINCDIR@
@@ -66,7 +68,7 @@ xenlibdir ?= @XENLIBDIR@
 virtincdir ?= @VIRTINCDIR@
 virtlibdir ?= @VIRTLIBDIR@
 fence_agents ?= @FENCE_AGENTS@
-fencelibdir ?= @FENCELIBDIR@
+fenceagentslibdir ?= @FENCEAGENTSLIBDIR@
 enable_experimental_fence_agents ?= @ENABLE_EXPERIMENTAL_FENCE_AGENTS@
 experimental_build ?= @ENABLE_CRACK_OF_THE_DAY@
 enable_xen ?= @ENABLE_XEN@
make/fencebuild.mk +2 -2
index c0671e0..edb3d3d 100644
@@ -1,4 +1,4 @@
-ifndef FENCELIB
+ifndef FENCEAGENTSLIB
 SBINDIRT=$(TARGET)
 endif
 
@@ -14,7 +14,7 @@ $(TARGET):
 		${RELEASE_VERSION} \
 		$(S) $@ | \
 	sed \
-		-e 's#@FENCELIBDIR@#${fencelibdir}#g' \
+		-e 's#@FENCEAGENTSLIBDIR@#${fenceagentslibdir}#g' \
 		-e 's#@MIBDIR@#${mibdir}#g' \
 		-e 's#@SNMPBIN@#${snmpbin}#g' \
 	> $@
make/install.mk +3 -3
index 6260e50..5a6c995 100644
@@ -51,7 +51,7 @@ ifdef MIBRESOURCE
 	install -d ${mibdir}
 	install -m644 $(S)/${MIBRESOURCE} ${mibdir}
 endif
-ifdef FENCELIB
-	install -d ${DESTDIR}/${fencelibdir}
-	install -m644 $(S)/${FENCELIB} ${DESTDIR}/${fencelibdir}
+ifdef FENCEAGENTSLIB
+	install -d ${DESTDIR}/${fenceagentslibdir}
+	install -m644 $(S)/${FENCELIB} ${DESTDIR}/${fenceagentslibdir}
 endif
make/uninstall.mk +2 -2
index e6211c6..2896816 100644
@@ -32,6 +32,6 @@ endif
 ifdef MIBRESOURCE
 	${UNINSTALL} ${MIBRESOURCE} ${mibdir}
 endif
-ifdef FENCELIB
-	${UNINSTALL} ${FENCELIB}* ${DESTDIR}/${fencelibdir}
+ifdef FENCEAGENTSLIB
+	${UNINSTALL} ${FENCELIB}* ${DESTDIR}/${fenceagentslibdir}
 endif

hooks/post-receive
--
Cluster Project