If cvs is ported to Z/os maybe we could set up a git/cvs gateway for John. Im pretty sure there is a reasonably good one included with git.
Likely it would need some support from Dennis tho. Yves On 24 February 2013 00:38, Karl Williamson <[email protected]> wrote: > The bottom (actually top :) ) line is that at least some of these errors > were the result of makedepend failing to realize that the C89 standard > allows preprocessor directives to be indented, and failing to account for > continuation lines in preprocessor lines. I am smoking some fixes for this. > On my system this gets rid of all errors in makedepend. (Several of the > errors that John mentions below were showing up on mine, but were being > suppressed.) > > We need to figure out how to most easily give John access to the latest > changes, and for him to submit patches, as I believe, he doesn't have git > access on z/OS. Perhaps their could be a branch, that he rsyncs from, for > the first part. Anyway, if you want to try these patches out before they > get into blead, the link is > > http://perl5.git.perl.org/perl.git/shortlog/refs/heads/smoke-me/khw-makedepend > > > On 02/23/2013 11:41 AM, John Goodyear wrote: >> >> Nicholas, I digested your response and makedepend (minus a sed >> statement) over coffee. >> >> Before I get into what I've found, it would seem that most of these >> errors emitted from makedepend can likely be ignored since its goal is >> just to find dependencies. However if there may be a (small) chance >> that a dependency gets dropped, so if there are errors, it is wise to >> understand their cause. >> >> The source of confusion was that I was looking at the real source files >> instead of the versions that makedepend strips before feeding to ccpstdin. >> >> A nit: >> >> makedepend puts '#line 1 "<filename>"' at the top of each >> UU/<filename>.c.c file. This causes the compiler errors to report >> a line above where the error is. >> At least for z/OS, if that was changed to '#line 2 ...' , it would >> prevent the compiler from reporting the wrong line >> >> >> >> Next ... >> >> >> Finding dependencies for pp_sys.o. >> >> ERROR CCN3010 ./time64.c:478 Macro PeRl_CaTiFy invoked with a null >> argument for parameter a. >> >> ERROR CCN3010 ./time64.c:478 Macro PeRl_CaTiFy invoked with a null >> argument for parameter a. >> >> >> Finding dependencies for regexec.o. >> >> ERROR CCN3287 regexec.c:35 The parameter list on the definition >> >> of macro LOAD_UTF8_CHARCLASS_DEBUG_TEST is not complete. >> >> ERROR CCN3287 regexec.c:75 The parameter list on the definition >> >> of macro REXEC_TRIE_READ_CHAR is not complete. >> >> For the errors above, I see that cppstdin is invoke with these >> arguments: >> $finc='', -I., $cppflags='', $cppminus='' >> This being the case, is it simply that when cppflags or cppminus >> are empty some macros aren't being defined? >> As you indicated, this could be happening on other platforms, but is >> getting hidden since stderr is handled differently. >> >> >> Next... >> > Finding dependencies for perly.o. >> >> > ERROR CCN3202 perly.c:82 #endif can only appear at the end of a >> #if, #elif, #ifdef or #ifndef block. >> >> You called out the extra #endif that makedepends appends >> specifically for this file. It is the cuprit >> >> Now we just have to understand why it was put there. Either >> something in the code, or something in (z/OS or the compiler) has >> changed since then. >> >> >> >> Next ... >> There a a couple of different issues for the files that take conditional >> declaration listed errors. This statement from makedepend seems to be >> the cause: >> >> 108 $echo "Finding dependencies for $filebase$_o." >> 109 ( $echo "#line 1 \"$file\""; \ >> 110 $sed -n <$file \ >> 111 -e "/^${filebase}_init(/q" \ >> 112 -e '/^#line/d' \ >> 113 -e '/^#/{' \ >> 114 -e 's|/\*.*$||' \ >> 115 -e 's|\\$||' \ >> 116 -e p \ >> 117 -e '}' ) >UU/$file.c >> >> >> My sed and re foo is a bit weak to understand why it's omitting the >> conditional lines highlighted below, but it seems to be the case. >> >> >> >> I ran the perl.c and perl.c.c files through some #ifdef #endif balance >> checking logic to understand what it is complaining about. For perl.c >> the sed expression that generates the .c.c file seems to have >> something against an indented "#endif" statement at line 3441. sed >> omits it, causing the error below. If I remove the indentation, then >> it is not omitted. Oddly, sv.c has a similarly indented #endif at >> 6610, but it does not cause a problem. Sigh. >> >> >> >> >> Finding dependencies for perl.o. >> >> WARNING CCN3296 ./patchlevel.h:132 #include file "git_version.h" >> not found. >> >> ERROR CCN3198 perl.c:536 #if, #else, #elif, #ifdef, #ifndef block >> >> must be ended with #endif. >> >> from perl.c: >> line 3419 iflevel inc to 1 #if !defined(DGUX) >> line 3422 iflevel inc to 2 #ifdef PERL_PATCHNUM >> line 3423 iflevel inc to 3 # ifdef PERL_GIT_UNCOMMITTED_CHANGES >> line 3427 iflevel dec to 2 # endif >> line 3441 iflevel dec to 1 #endif >> line 3463 iflevel dec to 0 #endif /* !DGUX */ >> line 3464 iflevel inc to 1 #if defined(LOCAL_PATCH_COUNT) >> >> from perl.c.c >> line 328 iflevel inc to 1 #if !defined(DGUX) >> line 329 iflevel inc to 2 #ifdef PERL_PATCHNUM >> line 330 iflevel inc to 3 # ifdef PERL_GIT_UNCOMMITTED_CHANGES >> line 332 iflevel dec to 2 # endif >> line 334 iflevel dec to 1 #endif >> line 335 iflevel inc to 2 #if defined(LOCAL_PATCH_COUNT) >> >> >> >> This error seemed to be complaining about define SIZE32 4, however >> looking at pp_pack.c.c, you can see that the line continuation and 2nd >> part of the conditional expression was (apparently) dropped by the sed >> statement that generates the UU/<filename>.c.c files >> >> >> Finding dependencies for pp_pack.o. >> >> ERROR CCN3294 pp_pack.c:116 Syntax error in expression on #if >> directive. >> >> from pp_pack.c >> 362 # if defined(my_htolen) && defined(my_letohn) && \ >> 363 defined(my_htoben) && defined(my_betohn) >> 364 # define DO_BO_UNPACK_N(var, type) >> from pp_pack.c.c >> 116 # if defined(my_htolen) && defined(my_letohn) && >> 117 # define DO_BO_UNPACK_N(var, type) >> >> >> >> >> >> Regards, >> >> John Goodyear >> IT Specialist: zBX Power Blades >> ATS zEnterprise Focus Team >> Gaithersburg,MD >> [email protected] >> >> Inactive hide details for Nicholas Clark ---02/22/2013 03:37:50 PM---On >> Fri, Feb 22, 2013 at 02:31:05PM -0500, John Goodyear wrNicholas Clark >> ---02/22/2013 03:37:50 PM---On Fri, Feb 22, 2013 at 02:31:05PM -0500, >> >> John Goodyear wrote: > sh ./makedepend MAKE=make >> >> From: Nicholas Clark <[email protected]> >> To: John Goodyear/Gaithersburg/IBM@IBMUS, Peter Prymmer >> <[email protected]>, >> Cc: [email protected], [email protected] >> Date: 02/22/2013 03:37 PM >> Subject: Re: makedepend issues with Perl 5.17.10 on z/OS 1.13 >> Sent by: Nicholas Clark <[email protected]> >> ------------------------------------------------------------------------ >> >> >> >> >> On Fri, Feb 22, 2013 at 02:31:05PM -0500, John Goodyear wrote: >> >> > sh ./makedepend MAKE=make >> > ... >> > ... >> > perl.c >> > Finding dependencies for perl.o. >> > WARNING CCN3296 ./patchlevel.h:132 #include file "git_version.h" >> not >> > found. >> > ERROR CCN3198 perl.c:535 #if, #else, #elif, #ifdef, #ifndef >> block must >> > be ended with #endif. >> > FSUM3065 The COMPILE step ended with return code 12. >> > FSUM3017 Could not compile .83952605.c. Correct the errors and try >> > again. >> > >> > Where does git_version.h come from? I don't have it. >> >> It's generated later on by the build. The code in makedepend differs quite >> markedly between os390 and everything else. >> >> Everything else does this, capturing stderr too, then processes it >> >> $cppstdin $finc -I. $cppflags $cppminus <UU/$file.c >.cout 2>.cerr >> $sed \ >> >> ... >> >> -e '/^# *[0-9][0-9]* *[".\/]/!d' \ >> >> -e 's|\.c\.c|.c|' $uwinfix .cout .cerr| \ >> $uniq | $sort | $uniq >> .deptmp >> >> >> As best I can work out, that expression I left in deletes *every* line >> that >> doesn't match something like # 999 "file.h" >> so eats all the error messages. >> >> The os390 code is this: >> >> $cppstdin $finc -I. $cppflags $cppminus <UU/$file.c | >> $sed \ >> >> ... >> >> -e 's|\.c\.c|.c|' $uwinfix | \ >> $uniq | $sort | $uniq >> .deptmp >> >> >> ie stderr is still visible. I think that this is why you're seeing error >> messages. >> >> >> > Not sure why the compiler is issuing the coplaint about 535. Is it >> > possibly 535 of the preprocessor expanded version of perl.c ?? >> > >> > 533 destruct_level = PL_perl_destruct_level; >> > 534 #if defined(DEBUGGING) || defined(PERL_TRACK_MEMPOOL) >> > 535 { >> >> This complaint doesn't make sense to me There are plenty of other lines >> with similar #if defined(XXX) || defined (YYY) >> >> > ... >> > ... >> > >> > perly.c >> > Same issue for perly.c. complaint at line 82 does not make sense >> > >> > ERROR CCN3202 perly.c:82 #endif can only appear at the end of a >> #if, >> > #elif, #ifdef or #ifndef block. >> > FSUM3065 The COMPILE step ended with return code 12. >> > FSUM3017 Could not compile .83952612.c. Correct the errors and try >> > again. >> >> I think that you're going to have to look at the output of pre-processor >> to figure out why it's confused. There is a hack in makedepend.SH that >> might be relevant. Using the git blame view: >> >> http://perl5.git.perl.org/perl.git/blame/HEAD:/makedepend.SH >> >> I find this: >> >> commit 4902b9ac34817bed7eedc3956f985e2d5ded090e >> Author: Jarkko Hietaniemi <[email protected]> >> Date: Thu Jun 5 16:58:23 2003 +0000 >> >> z/OS makedepend fix from Peter Prymmer; >> still needed as reported by Brian De Pradine. >> >> p4raw-id: //depot/perl@19692 >> >> diff --git a/makedepend.SH b/makedepend.SH >> index c1d880d..688f656 100755 >> --- a/makedepend.SH >> +++ b/makedepend.SH >> @@ -141,6 +141,11 @@ for file in `$cat .clist`; do >> -e 's|\\$||' \ >> -e p \ >> -e '}' ) >UU/$file.c >> + >> + if [ "$osname" = os390 -a "$file" = perly.c ]; then >> + $echo '#endif' >>UU/$file.c >> + fi >> + >> if [ "$osname" = os390 ]; then >> $cppstdin $finc -I. $cppflags $cppminus <UU/$file.c | >> $sed \ >> >> >> I don't know if Peter Prymmer remembers what that was about, and why it >> was >> needed. >> >> > Other makedepend output indicating problems >> > ... >> > ... >> > >> > Finding dependencies for pp_sys.o. >> > ERROR CCN3010 ./time64.c:478 Macro PeRl_CaTiFy invoked with a null >> > argument for parameter a. >> > ERROR CCN3010 ./time64.c:478 Macro PeRl_CaTiFy invoked with a null >> > argument for parameter a. >> >> >> That's very strange. The macro PeRl_CaTiFy is defined in config.h, >> probably >> looking like this: >> >> #define PeRl_CaTiFy(a, b) a ## b >> >> Line 478 of time64.c is this: >> >> if( SHOULD_USE_SYSTEM_LOCALTIME(*time) ) { >> >> and that's defined earlier like this: >> >> #ifdef USE_SYSTEM_LOCALTIME >> # define SHOULD_USE_SYSTEM_LOCALTIME(a) ( \ >> (a) <= SYSTEM_LOCALTIME_MAX && \ >> (a) >= SYSTEM_LOCALTIME_MIN \ >> ) >> #else >> # define SHOULD_USE_SYSTEM_LOCALTIME(a) (0) >> #endif >> >> >> So how come it thinks that the two are even remotely connected? >> >> >> > Finding dependencies for globals.o. >> > WARNING CCN3296 ./perl.h:4331 #include file "uudmap.h" not found. >> > WARNING CCN3296 ./perl.h:4338 #include file "bitcount.h" not found. >> > WARNING CCN3296 ./perl.h:5203 #include file "mg_data.h" not found. >> > FSUM3065 The COMPILE step ended with return code 4. >> >> These error messages will be ignored on platforms other than os390, due to >> the differing sed shown above. >> >> > Finding dependencies for pp_pack.o. >> > ERROR CCN3294 pp_pack.c:115 Syntax error in expression on #if >> directive. >> > FSUM3065 The COMPILE step ended with return code 12. >> > FSUM3017 Could not compile .67174450.c. Correct the errors and try >> again. >> >> It's objecting to this? >> >> #define SIZE32 4 >> >> > Does configure usually notice errors from makedepend and indicate >> something >> > needs to be fixed before running make, or is this normal >> >> It doesn't hit problems on non EBCDIC systems. Some of the (lack of) error >> messages are explained by the different code in makedepend. But the others >> seem really strange. >> >> Nicholas Clark >> >> > -- perl -Mre=debug -e "/just|another|perl|hacker/"
