The syntax error with (\\) was probably not-critical because setting the 
"float" option is probably not required.
The actual error was not detected because no one bothered to examine the 
configure script log.   

There was one critical error   False Detection of (xpm)   {xpm]  is not a Posix 
standard, therefore ibm does not support it   
I added the header detection error flag to fix [xpm] { haltonmsg(3296)  }  

As I mentioned in previous emails   the majority of { Xm }  headers  are Motif 
2.1  which IBM previously did not support 

I am not sure exactly when they added this new 2.1 support in     ( I am 
currently using z/OS 1.10 or 11 ) 

Unfortunately IBM made Motif  2.1 the new default  which requires using  a much 
higher  level of c standards compliant code   

Compiling with the new motif 2.1 headers generates a boat-load of errors 

So I inserted the old 1.2 headers back to the front of the bus   (but that does 
not hide the new Xm headers )

So the configure script detected all these wonderful new Xm headers  (some of 
which generated compile errors )  and after I hacked the code
To fix those errors I ended up with link errors because I was not and can-not 
link with the new motif 2.1 xm libs   

So I added a new check to exclude the new Xm headers  

Finally the configure script compile options are unique to the needs of the 
configure script and should not be used for the actual build process
Therefore I added a few new lines to set the correct options to be written to 
the make-file 

Here is the diff you requested >>

*** configure-new       Thu May  3 22:09:02 2012
--- configure   Tue Apr 24 15:54:41 2012
***************
*** 4411,4417 ****
  $as_echo_n "checking for z/OS Unix... " >&6; }
  case `uname` in
      OS/390)   zOSUnix="yes";
!               if test "$CC" = "cc"; then
                  ccm="$_CC_CCMODE"
                  ccn="CC"
                else
--- 4411,4417 ----
  $as_echo_n "checking for z/OS Unix... " >&6; }
  case `uname` in
      OS/390)   zOSUnix="yes";
!                                                                               
if test "$CC" = "cc"; then
                  ccm="$_CC_CCMODE"
                  ccn="CC"
                else
***************
*** 4426,4439 ****
                  echo ""
                  echo "------------------------------------------"
                  echo " On z/OS Unix, the environment variable"
!                 echo " _CC_${ccn}MODE must be set to \"1\"!"
                  echo " Do:"
                  echo "    export _CC_${ccn}MODE=1"
                  echo " and then call configure again."
                  echo "------------------------------------------"
                  exit 1
                fi
!               CFLAGS="$CFLAGS -D_ALL_SOURCE -Wc,float(IEEE),haltonmsg(3296)";
                  LDFLAGS="$LDFLAGS -Wl,EDIT=NO"
                { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  $as_echo "yes" >&6; }
--- 4426,4439 ----
                  echo ""
                  echo "------------------------------------------"
                  echo " On z/OS Unix, the environment variable"
!                 echo " __CC_${ccn}MODE must be set to \"1\"!"
                  echo " Do:"
                  echo "    export _CC_${ccn}MODE=1"
                  echo " and then call configure again."
                  echo "------------------------------------------"
                  exit 1
                fi
!               CFLAGS="$CFLAGS -D_ALL_SOURCE -Wc,float\\(IEEE\\)";
                  LDFLAGS="$LDFLAGS -Wl,EDIT=NO"
                { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  $as_echo "yes" >&6; }
***************
*** 7397,7403 ****
  fi
  
  
!   if test "$zOSUnix" = "yes"; then
      CFLAGS="$CFLAGS -W c,dll"
      LDFLAGS="$LDFLAGS -W l,dll"
      X_EXTRA_LIBS="$X_EXTRA_LIBS -lSM -lICE -lXmu"
--- 7397,7403 ----
  fi
  
  
!         if test "$zOSUnix" = "yes"; then
      CFLAGS="$CFLAGS -W c,dll"
      LDFLAGS="$LDFLAGS -W l,dll"
      X_EXTRA_LIBS="$X_EXTRA_LIBS -lSM -lICE -lXmu"
***************
*** 8697,8709 ****
  if test -z "$SKIP_MOTIF"; then
    cppflags_save=$CPPFLAGS
    CPPFLAGS="$CPPFLAGS $X_CFLAGS"
!   if test "$zOSUnix" = "yes"; then
!       xmheader="Xm/Xm.h"
!   else
!       xmheader="Xm/Xm.h Xm/XpmP.h Xm/JoinSideT.h Xm/TraitP.h Xm/Manager.h
!          Xm/UnhighlightT.h Xm/Notebook.h"  
!   fi  
!   for ac_header in $xmheader
  do :
    as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
  ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" 
"$ac_includes_default"
--- 8697,8704 ----
  if test -z "$SKIP_MOTIF"; then
    cppflags_save=$CPPFLAGS
    CPPFLAGS="$CPPFLAGS $X_CFLAGS"
!   for ac_header in Xm/Xm.h Xm/XpmP.h Xm/JoinSideT.h Xm/TraitP.h Xm/Manager.h \
!                  Xm/UnhighlightT.h Xm/Notebook.h
  do :
    as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
  ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" 
"$ac_includes_default"
***************
*** 8718,8724 ****
  done
  
  
!   if test "x$ac_cv_header_Xm_XpmP_h" = x""yes; then
          { $as_echo "$as_me:${as_lineno-$LINENO}: checking for 
XpmAttributes_21 in Xm/XpmP.h" >&5
  $as_echo_n "checking for XpmAttributes_21 in Xm/XpmP.h... " >&6; }
      cat confdefs.h - <<_ACEOF >conftest.$ac_ext
--- 8713,8719 ----
  done
  
  
!   if test $ac_cv_header_Xm_XpmP_h = yes; then
          { $as_echo "$as_me:${as_lineno-$LINENO}: checking for 
XpmAttributes_21 in Xm/XpmP.h" >&5
  $as_echo_n "checking for XpmAttributes_21 in Xm/XpmP.h... " >&6; }
      cat confdefs.h - <<_ACEOF >conftest.$ac_ext
***************
*** 12594,12603 ****
  $as_echo "no" >&6; }
  fi
  
- if test "$zOSUnix" = "yes"; then
- #     CFLAGS=`$as_echo "$CFLAGS" | sed 's/(/\\\\(/g;s/)/\\\\)/g'`
-       CFLAGS="-D_ALL_SOURCE -Wc,float\(IEEE\),dll"
- fi
  
  ac_config_files="$ac_config_files auto/config.mk:config.mk.in"
  
--- 12589,12594 ----


******************************************************************************
******************************************************************************


*** configure.in        Fri May  4 22:29:54 2012
--- ../configure.in     Tue Apr 24 15:54:41 2012
***************
*** 329,345 ****
                  echo ""
                  echo "------------------------------------------"
                  echo " On z/OS Unix, the environment variable"
!                 echo " _CC_${ccn}MODE must be set to \"1\"!"
                  echo " Do:"
                  echo "    export _CC_${ccn}MODE=1"
                  echo " and then call configure again."
                  echo "------------------------------------------"
                  exit 1
                fi
!               # set CFLAGS for configure process
!               # this will be reset later for config.mk
!               # use haltonmsg to force error for missing H files              
!               CFLAGS="$CFLAGS -D_ALL_SOURCE -Wc,float(ieee),haltonmsg(3296)";
                  LDFLAGS="$LDFLAGS -Wl,EDIT=NO"
                AC_MSG_RESULT(yes)
                ;;
--- 329,342 ----
                  echo ""
                  echo "------------------------------------------"
                  echo " On z/OS Unix, the environment variable"
!                 echo " __CC_${ccn}MODE must be set to \"1\"!"
                  echo " Do:"
                  echo "    export _CC_${ccn}MODE=1"
                  echo " and then call configure again."
                  echo "------------------------------------------"
                  exit 1
                fi
!               CFLAGS="$CFLAGS -D_ALL_SOURCE -Wc,float\\(IEEE\\)";
                  LDFLAGS="$LDFLAGS -Wl,EDIT=NO"
                AC_MSG_RESULT(yes)
                ;;
***************
*** 2381,2395 ****
  if test -z "$SKIP_MOTIF"; then
    cppflags_save=$CPPFLAGS
    CPPFLAGS="$CPPFLAGS $X_CFLAGS"
!   if test "$zOSUnix" = "yes"; then
!       xmheader="Xm/Xm.h"
!   else
!       xmheader="Xm/Xm.h Xm/XpmP.h Xm/JoinSideT.h Xm/TraitP.h Xm/Manager.h
!          Xm/UnhighlightT.h Xm/Notebook.h"  
!   fi    
!   AC_CHECK_HEADERS($xmheader)
  
!   if test "x$ac_cv_header_Xm_XpmP_h" = x""yes; then
      dnl Solaris uses XpmAttributes_21, very annoying.
      AC_MSG_CHECKING([for XpmAttributes_21 in Xm/XpmP.h])
      AC_TRY_COMPILE([#include <Xm/XpmP.h>], [XpmAttributes_21 attr;],
--- 2378,2387 ----
  if test -z "$SKIP_MOTIF"; then
    cppflags_save=$CPPFLAGS
    CPPFLAGS="$CPPFLAGS $X_CFLAGS"
!   AC_CHECK_HEADERS(Xm/Xm.h Xm/XpmP.h Xm/JoinSideT.h Xm/TraitP.h Xm/Manager.h \
!                  Xm/UnhighlightT.h Xm/Notebook.h)
  
!   if test $ac_cv_header_Xm_XpmP_h = yes; then
      dnl Solaris uses XpmAttributes_21, very annoying.
      AC_MSG_CHECKING([for XpmAttributes_21 in Xm/XpmP.h])
      AC_TRY_COMPILE([#include <Xm/XpmP.h>], [XpmAttributes_21 attr;],
***************
*** 3650,3660 ****
  fi
  AC_SUBST(LINK_AS_NEEDED)
  
- # IBM z/OS reset CFLAGS for config.mk
- if test "$zOSUnix" = "yes"; then
-       CFLAGS="-D_ALL_SOURCE -Wc,float\(ieee\),dll"
- fi
- 
  dnl write output files
  AC_OUTPUT(auto/config.mk:config.mk.in)
  
--- 3642,3647 ----

***************************************************************************
***************************************************************************

The next challenge is to try to fix things so we can use the new 2.1 headers  
and the new 2.1 libs

IBM recommends using  c89  >> which uses langlvl(ansi)    <<   

Compiling with langlvl(ansi) seems to help a lot , but it also introduces new 
problems   ( you can not re-define a #define !! )  

-----Original Message-----
From: [email protected] [mailto:[email protected]] 
Sent: Saturday, May 05, 2012 4:03 AM
To: Bovy, Stephen
Cc: [email protected]; MVS OpenEdition ([email protected])
Subject: Re: VIM: Configure script patch for IBM z/OS <<< gvim motif build 
procedure << motif 1.2 vs motif 2.1 <<


Stephen Bovy wrote:

> Background  >>
> 
> Problems
> 
> 1) The CFLAGS setting had syntax errors during the configure process ( 
> need to remove "escapes" {\\} )
> 2) The configure process did not correctly detect missing header files 
> {need to add option to force error on missing .h files haltonmsg(3296) 
> }
> 3) New default  Motif 2.1 support does not compile (need to externally 
> change lib search paths ) (no change needed ) (see notes below )
> 4) New Default Motif 2.1 header detection creates compile and link 
> errors ( need to remove most {Xm} headers )
> 5) configure CFLAGS value can-not be used for final  config.mk
> 
> Here is the diff >>
> 
> 4414c4414
> <                                                                             
> if test "$CC" = "cc"; then
> ---
> >             if test "$CC" = "cc"; then

Can you please make a context diff with diff -c or diff -u ?
Otherwise there might be mistakes.

I'm glad you managed to make it work.  I wonder what the existing configure 
lines were for.  I assume your system is more recent, I don't think these lines 
have been changed for several years.

Updating the os_390.txt file would also be very helpful for z/OS users.


--
A law to reduce crime states: "It is mandatory for a motorist with criminal 
intentions to stop at the city limits and telephone the chief of police as he 
is entering the town.
                [real standing law in Washington, United States of America]

 /// Bram Moolenaar -- [email protected] -- http://www.Moolenaar.net   \\\
///        sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\
\\\  an exciting new programming language -- http://www.Zimbu.org        ///
 \\\            help me help AIDS victims -- http://ICCF-Holland.org    ///

-- 
You received this message from the "vim_dev" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php

Raspunde prin e-mail lui