[torquedev] Build Problems

Michael Jennings mej at lbl.gov
Fri Jul 23 19:48:03 MDT 2010


On Friday, 23 July 2010, at 17:39:19 (-0700),
Garrick Staples wrote:

> I think the use of -Wall -Werror has been very good for us. It
> catches little errors slip by because what is only a warning on one
> platform is actually an error on another platform.
> 
> I care about nearly all warnings. And I care about future types of
> warnings in future compiler releases. I specifically exempt a few
> warnings (-Wno-long-long) for ones that I don't care about it, but I
> want everything else watched.
> 
> So... what warning did you see? Have a patch yet?

I make it a policy to prototype every single function and declare
every single variable.  Therefore, I have -Wmissing-prototypes and
-Wmissing-declarations in my default $CFLAGS.

Just for grins, I removed -Werror and built torque with those two
flags in place.  There are a few hundred warnings that result.  So no,
I don't have a patch yet.  :-)

I do, however, have a patch for the problems caused when one does
"make maintainer-clean && autoreconf -i && ./configure && make distcheck"
which has the nice side effect of allowing 3 more auto-generated files
to be removed from the repository, if you so choose:
D       src/drmaa/src/drmaa_attrib.c
D       src/drmaa/src/pbs_attrib.c
D       src/scheduler.basl/Parser.h

Patch attached.

Michael

-- 
Michael Jennings <mej at lbl.gov>
Linux Systems and Cluster Engineer
High-Performance Computing Services
Bldg 50B-3209E      W: 510-495-2687
MS 050C-3396        F: 510-486-8615
-------------- next part --------------
Index: src/scheduler.basl/Lexer.l
===================================================================
--- src/scheduler.basl/Lexer.l	(revision 3930)
+++ src/scheduler.basl/Lexer.l	(working copy)
@@ -107,7 +107,7 @@
 #include <string.h>
 #include <stdlib.h>
 #include "Lexer.h"
-#include "y.tab.h"
+#include "Parser.h"
 extern int linenum;
 char   linebuf[500];
 int    tokenReturned = -1;
Index: src/scheduler.basl/Makefile.am
===================================================================
--- src/scheduler.basl/Makefile.am	(revision 3930)
+++ src/scheduler.basl/Makefile.am	(working copy)
@@ -9,16 +9,17 @@
 
 pbs_sched_LDADD = $(PBS_LIBS) $(SCHD_LIBS) pbs_sched.o
 pbs_sched_SOURCES = af.c af_cnode.c af_cnodemap.c af_config.c af_job.c \
-		    af_que.c af_resmom.c af_server.c af_system.c af.h
+		    af_que.c af_resmom.c af_server.c af_system.c af.h \
+		    af_system.h af_cnode.h af_cnodemap.h af_config.h \
+	     	    af_job.h af_que.h af_resmom.h af_server.h
 
 basl2c_LDADD = $(SCHD_LIBS)
-basl2c_SOURCES = af.c Basl2c.c CodeGen.c List.c Node.c Semantic.c SymTab.c \
-		 Lexer.l Parser.y CodeGen.h
+BUILT_SOURCES = Parser.h
+basl2c_SOURCES = af.c Basl2c.c CodeGen.c List.c List.h Node.c Node.h \
+		 Semantic.c Semantic.h SymTab.c SymTab.h SymTabGlob.h \
+		 Lexer.l Parser.y CodeGen.h Lexer.h ParLexGlob.h
 
-EXTRA_DIST = Lexer.h List.h af_system.h Node.h ParLexGlob.h Semantic.h \
-	     SymTab.h SymTabGlob.h af_cnode.h af_cnodemap.h af_config.h \
-	     af_job.h af_que.h af_resmom.h af_server.h \
-	     sample.programs/af.basl sample.programs/af2.basl \
+EXTRA_DIST = sample.programs/af.basl sample.programs/af2.basl \
 	     sample.programs/loadave1.basl sample.programs/loadave2.basl \
 	     sample.programs/loadave3.basl sample.programs/loadave4.basl \
 	     sample.programs/nas.basl sample.programs/nqs.basl \
@@ -36,18 +37,19 @@
 
 pbs_sched.c: samples/$(SCHD_CODE) basl2c
 	./basl2c $(srcdir)/samples/$(SCHD_CODE)
-		
-Lexer.o: Lexer.c y.tab.h
-	
+
+Lexer.o: Lexer.c Parser.h
+
 Lexer.c: Lexer.l
 	$(LEXCOMPILE) $< && mv $(LEX_OUTPUT_ROOT).c $@
 
-y.tab.h: Parser.c
+Parser.h: Parser.c
+	@if test ! -f $@ ; then rm -f $< ; $(MAKE) $(AM_MAKEFLAGS) $< && mv y.tab.h Parser.h ; else : ; fi
 
 Parser.c: Parser.y
 	$(YACCCOMPILE) $< && mv y.tab.c $@
 
-MOSTLYCLEANFILES = Parser.c y.tab.h Lexer.c pbs_sched.c
+MOSTLYCLEANFILES = Parser.c Parser.h Lexer.c pbs_sched.c
 
 
 install-exec-hook:
Index: configure.ac
===================================================================
--- configure.ac	(revision 3930)
+++ configure.ac	(working copy)
@@ -1417,7 +1417,9 @@
 
  build_drmaa_docs=yes
 else  
-  DOXYGEN=none
+ GPERF=/bin/true
+ AC_SUBST(GPERF)
+ DOXYGEN=none
  build_drmaa_docs=no
 fi
 AM_CONDITIONAL(DRMAA_DOCS, [test "$DOXYGEN" != "none"])


More information about the torquedev mailing list