[MPICH2-dev] [patch] create valid default defmsg.h if building one fails
Ashley Pittman
ashley at quadrics.com
Thu Nov 24 08:11:55 CST 2005
This patch didn't get applied correctly, we are re-syncing with the
1.0.3 code currently and the "#define MPIR_MAX_ERROR_CLASS_INDEX 1" line
is missing from the new code. Without this the code still doesn't
compile.
One other oddity I've spotted is that once the src/mpi/errhan/defmsg.h
file is created once running configure doesn't re-create it which can
lead to problems lingering un-noticed.
Ashley,
On Thu, 2005-10-06 at 10:08 -0500, William Gropp wrote:
> At 11:38 AM 10/5/2005, Ashley Pittman wrote:
>
> >Hi,
> >
> >We've hit a bug several times now where we add error codes to the source
> >without writing a long description for it, this in turn causes
> >maint/extracterrmsgs to fail (as it should) but the fallback defmsg.h
> >that updatefiles creates is un-usable leading to compile errors later
> >on.
> >
> >This patch causes the fallback file to be generated properly. It's
> >tested in so much as the code compiles but I haven't tried running any
> >code with it yet, I'll let you know the results of the testsuite
> >tomorrow.
>
> Thanks for the patch, I've applied it and will check it in today.
>
> Bill
>
>
> >Ashley,
> >
> >
> >Index: maint/updatefiles
> >===================================================================
> >RCS file: /cvs/master/quadrics/mpi2/mpich2/maint/updatefiles,v
> >retrieving revision 1.1.1.2
> >retrieving revision 1.4
> >diff -u -3 -p -r1.1.1.2 -r1.4
> >--- maint/updatefiles 23 Jun 2005 13:56:39 -0000 1.1.1.2
> >+++ maint/updatefiles 5 Oct 2005 16:30:50 -0000 1.4
> >@@ -287,18 +287,19 @@ Error message files in src/mpi/errhan we
> > if [ ! -s src/mpi/errhan/defmsg.h ] ; then
> > echo "Creating a dummy defmsg.h file"
> > cat > src/mpi/errhan/defmsg.h <<EOF
> >-typedef struct { const char *short_name, *long_name; } msgpair;
> >+typedef struct { const unsigned int sentinal1; const char *short_name,
> >*long_name; const unsigned int sentinal2; } msgpair;
> > static const int generic_msgs_len = 0;
> >-static msgpair generic_err_msgs[] { {0, "no error catalog"}, };
> >+static msgpair generic_err_msgs[] = { {0xacebad03, 0, "no error
> >catalog", 0xcb0bfa11}, };
> > static const int specific_msgs_len = 0;
> >-static msgpair specific_err_msgs[] { {0,0}, };
> >+static msgpair specific_err_msgs[] = { {0xacebad03,0,0,0xcb0bfa11}, };
> > static int class_to_index[] = {
> > 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
> > 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
> > 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
> > 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
> > 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
> >-0, 0, 0, 0 }
> >+0, 0, 0, 0 };
> >+#define MPIR_MAX_ERROR_CLASS_INDEX 1
> > EOF
> > fi
> > fi
>
> William Gropp
> http://www.mcs.anl.gov/~gropp
>
More information about the mpich2-dev
mailing list