source: patches/2.0/vim-7.0-cross_compile-1.patch@ 1ffcade

clfs-1.2 clfs-2.1 clfs-3.0.0-systemd clfs-3.0.0-sysvinit systemd sysvinit
Last change on this file since 1ffcade was e9be59d, checked in by Jim Gifford <clfs@…>, 18 years ago

r3849@server (orig r1736): jciccone | 2006-06-06 17:35:53 -0700
Added the vim cross compilation patch.

  • Property mode set to 100644
File size: 24.1 KB
  • src/auto/configure

    Submitted By: Joe Ciccone <joeciccone@crazyeyesoft.com
    Date: 2006-06-06
    Initial Package Version: 7.0
    Upstream Status: Unknown
    Origin: Joe Ciccone and OpenEmbedded
    Description: This patch makes it possible to cross_compile vim.
    
    diff -Naur vim70.orig/src/auto/configure vim70/src/auto/configure
    old new  
    27962796  fi
    27972797fi
    27982798
    2799 if test "$cross_compiling" = yes; then
    2800   { { echo "$as_me:$LINENO: error: cannot compile a simple program, check CC and CFLAGS
    2801   (cross compiling doesn't work)" >&5
    2802 echo "$as_me: error: cannot compile a simple program, check CC and CFLAGS
    2803   (cross compiling doesn't work)" >&2;}
    2804    { (exit 1); exit 1; }; }
    2805 fi
    2806 
    28072799test "$GCC" = yes && CPP_MM=M;
    28082800
    28092801if test -f ./toolcheck; then
     
    34103402
    34113403
    34123404
    3413 have_local_include=''
    3414 have_local_lib=''
    3415 if test "$GCC" = yes; then
    3416   echo 'void f(){}' > conftest.c
    3417     have_local_include=`${CC-cc} -no-cpp-precomp -c -v conftest.c 2>&1 | grep '/usr/local/include'`
    3418   have_local_lib=`${CC-cc} -c -v conftest.c 2>&1 | grep '/usr/local/lib'`
    3419   rm -f conftest.c conftest.o
    3420 fi
    3421 if test -z "$have_local_lib" -a -d /usr/local/lib; then
    3422   tt=`echo "$LDFLAGS" | sed -e 's+-L/usr/local/lib ++g' -e 's+-L/usr/local/lib$++g'`
    3423   if test "$tt" = "$LDFLAGS"; then
    3424     LDFLAGS="$LDFLAGS -L/usr/local/lib"
    3425   fi
    3426 fi
    3427 if test -z "$have_local_include" -a -d /usr/local/include; then
    3428   tt=`echo "$CPPFLAGS" | sed -e 's+-I/usr/local/include ++g' -e 's+-I/usr/local/include$++g'`
    3429   if test "$tt" = "$CPPFLAGS"; then
    3430     CPPFLAGS="$CPPFLAGS -I/usr/local/include"
    3431   fi
    3432 fi
    3433 
    34343405echo "$as_me:$LINENO: checking --with-vim-name argument" >&5
    34353406echo $ECHO_N "checking --with-vim-name argument... $ECHO_C" >&6
    34363407
     
    92739244echo "$as_me:$LINENO: checking quality of toupper" >&5
    92749245echo $ECHO_N "checking quality of toupper... $ECHO_C" >&6
    92759246if test "$cross_compiling" = yes; then
    9276   { { echo "$as_me:$LINENO: error: failed to compile test program" >&5
    9277 echo "$as_me: error: failed to compile test program" >&2;}
    9278    { (exit 1); exit 1; }; }
     9247  { echo "$as_me:$LINENO: WARNING: failed to compile test program" >&5
     9248echo "$as_me: WARNING: failed to compile test program" >&2;}
    92799249else
    92809250  cat >conftest.$ac_ext <<_ACEOF
    92819251/* confdefs.h.  */
     
    1174811718echo "$as_me:$LINENO: checking whether we talk terminfo" >&5
    1174911719echo $ECHO_N "checking whether we talk terminfo... $ECHO_C" >&6
    1175011720if test "$cross_compiling" = yes; then
    11751   { { echo "$as_me:$LINENO: error: failed to compile test program." >&5
    11752 echo "$as_me: error: failed to compile test program." >&2;}
    11753    { (exit 1); exit 1; }; }
     11721  { echo "$as_me:$LINENO: WARNING: failed to compile test program." >&5
     11722echo "$as_me: WARNING: failed to compile test program." >&2;}
     11723          cat >>confdefs.h <<\_ACEOF
     11724#define TERMINFO 1
     11725_ACEOF
     11726
    1175411727else
    1175511728  cat >conftest.$ac_ext <<_ACEOF
    1175611729/* confdefs.h.  */
     
    1231312286echo $ECHO_N "checking default tty permissions/group... $ECHO_C" >&6
    1231412287rm -f conftest_grp
    1231512288if test "$cross_compiling" = yes; then
    12316   { { echo "$as_me:$LINENO: error: failed to compile test program" >&5
    12317 echo "$as_me: error: failed to compile test program" >&2;}
    12318    { (exit 1); exit 1; }; }
     12289  { echo "$as_me:$LINENO: WARNING: failed to compile test program" >&5
     12290echo "$as_me: WARNING: failed to compile test program" >&2;}
    1231912291else
    1232012292  cat >conftest.$ac_ext <<_ACEOF
    1232112293/* confdefs.h.  */
     
    1254212514echo "$as_me:$LINENO: checking getcwd implementation" >&5
    1254312515echo $ECHO_N "checking getcwd implementation... $ECHO_C" >&6
    1254412516if test "$cross_compiling" = yes; then
    12545   { { echo "$as_me:$LINENO: error: failed to compile test program" >&5
    12546 echo "$as_me: error: failed to compile test program" >&2;}
    12547    { (exit 1); exit 1; }; }
     12517  { echo "$as_me:$LINENO: WARNING: failed to compile test program" >&5
     12518echo "$as_me: WARNING: failed to compile test program" >&2;}
    1254812519else
    1254912520  cat >conftest.$ac_ext <<_ACEOF
    1255012521/* confdefs.h.  */
     
    1280512776
    1280612777echo "$as_me:$LINENO: checking whether stat() ignores a trailing slash" >&5
    1280712778echo $ECHO_N "checking whether stat() ignores a trailing slash... $ECHO_C" >&6
    12808 if test "$cross_compiling" = yes; then
    12809   { { echo "$as_me:$LINENO: error: failed to compile test program" >&5
    12810 echo "$as_me: error: failed to compile test program" >&2;}
    12811    { (exit 1); exit 1; }; }
     12779if test "${ac_cv_func_stat_ignores_trailing_slash+set}" = set; then
     12780  echo $ECHO_N "(cached) $ECHO_C" >&6
     12781else
     12782  if test "$cross_compiling" = yes; then
     12783  ac_cv_func_stat_ignores_trailing_slash=no
     12784
    1281212785else
    1281312786  cat >conftest.$ac_ext <<_ACEOF
    1281412787/* confdefs.h.  */
     
    1283112804  ac_status=$?
    1283212805  echo "$as_me:$LINENO: \$? = $ac_status" >&5
    1283312806  (exit $ac_status); }; }; then
    12834   echo "$as_me:$LINENO: result: yes" >&5
    12835 echo "${ECHO_T}yes" >&6; cat >>confdefs.h <<\_ACEOF
    12836 #define STAT_IGNORES_SLASH 1
    12837 _ACEOF
    12838 
     12807  ac_cv_func_stat_ignores_trailing_slash=yes
    1283912808else
    1284012809  echo "$as_me: program exited with status $ac_status" >&5
    1284112810echo "$as_me: failed program was:" >&5
    1284212811sed 's/^/| /' conftest.$ac_ext >&5
    1284312812
    1284412813( exit $ac_status )
    12845 echo "$as_me:$LINENO: result: no" >&5
    12846 echo "${ECHO_T}no" >&6
     12814ac_cv_func_stat_ignores_trailing_slash=no
    1284712815fi
    1284812816rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
    1284912817fi
     12818fi
     12819echo "$as_me:$LINENO: result: $ac_cv_func_stat_ignores_trailing_slash" >&5
     12820echo "${ECHO_T}$ac_cv_func_stat_ignores_trailing_slash" >&6
     12821
     12822if X"$ac_cv_func_stat_ignores_trailing_slash" = Xyes; then
     12823       cat >>confdefs.h <<\_ACEOF
     12824#define STAT_IGNORES_SLASH 1
     12825_ACEOF
     12826
     12827fi
    1285012828
    1285112829echo "$as_me:$LINENO: checking for iconv_open()" >&5
    1285212830echo $ECHO_N "checking for iconv_open()... $ECHO_C" >&6
     
    1374313721fi
    1374413722rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
    1374513723
     13724echo "$as_me:$LINENO: checking for int" >&5
     13725echo $ECHO_N "checking for int... $ECHO_C" >&6
     13726if test "${ac_cv_type_int+set}" = set; then
     13727  echo $ECHO_N "(cached) $ECHO_C" >&6
     13728else
     13729  cat >conftest.$ac_ext <<_ACEOF
     13730/* confdefs.h.  */
     13731_ACEOF
     13732cat confdefs.h >>conftest.$ac_ext
     13733cat >>conftest.$ac_ext <<_ACEOF
     13734/* end confdefs.h.  */
     13735$ac_includes_default
     13736int
     13737main ()
     13738{
     13739if ((int *) 0)
     13740  return 0;
     13741if (sizeof (int))
     13742  return 0;
     13743  ;
     13744  return 0;
     13745}
     13746_ACEOF
     13747rm -f conftest.$ac_objext
     13748if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
     13749  (eval $ac_compile) 2>conftest.er1
     13750  ac_status=$?
     13751  grep -v '^ *+' conftest.er1 >conftest.err
     13752  rm -f conftest.er1
     13753  cat conftest.err >&5
     13754  echo "$as_me:$LINENO: \$? = $ac_status" >&5
     13755  (exit $ac_status); } &&
     13756         { ac_try='test -z "$ac_c_werror_flag"
     13757                         || test ! -s conftest.err'
     13758  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
     13759  (eval $ac_try) 2>&5
     13760  ac_status=$?
     13761  echo "$as_me:$LINENO: \$? = $ac_status" >&5
     13762  (exit $ac_status); }; } &&
     13763         { ac_try='test -s conftest.$ac_objext'
     13764  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
     13765  (eval $ac_try) 2>&5
     13766  ac_status=$?
     13767  echo "$as_me:$LINENO: \$? = $ac_status" >&5
     13768  (exit $ac_status); }; }; then
     13769  ac_cv_type_int=yes
     13770else
     13771  echo "$as_me: failed program was:" >&5
     13772sed 's/^/| /' conftest.$ac_ext >&5
     13773
     13774ac_cv_type_int=no
     13775fi
     13776rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
     13777fi
     13778echo "$as_me:$LINENO: result: $ac_cv_type_int" >&5
     13779echo "${ECHO_T}$ac_cv_type_int" >&6
    1374613780
    1374713781echo "$as_me:$LINENO: checking size of int" >&5
    1374813782echo $ECHO_N "checking size of int... $ECHO_C" >&6
    1374913783if test "${ac_cv_sizeof_int+set}" = set; then
    1375013784  echo $ECHO_N "(cached) $ECHO_C" >&6
    1375113785else
     13786  if test "$ac_cv_type_int" = yes; then
     13787  # The cast to unsigned long works around a bug in the HP C Compiler
     13788  # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
     13789  # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
     13790  # This bug is HP SR number 8606223364.
    1375213791  if test "$cross_compiling" = yes; then
    13753   { { echo "$as_me:$LINENO: error: failed to compile test program" >&5
    13754 echo "$as_me: error: failed to compile test program" >&2;}
     13792  # Depending upon the size, compute the lo and hi bounds.
     13793cat >conftest.$ac_ext <<_ACEOF
     13794/* confdefs.h.  */
     13795_ACEOF
     13796cat confdefs.h >>conftest.$ac_ext
     13797cat >>conftest.$ac_ext <<_ACEOF
     13798/* end confdefs.h.  */
     13799$ac_includes_default
     13800int
     13801main ()
     13802{
     13803static int test_array [1 - 2 * !(((long) (sizeof (int))) >= 0)];
     13804test_array [0] = 0
     13805
     13806  ;
     13807  return 0;
     13808}
     13809_ACEOF
     13810rm -f conftest.$ac_objext
     13811if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
     13812  (eval $ac_compile) 2>conftest.er1
     13813  ac_status=$?
     13814  grep -v '^ *+' conftest.er1 >conftest.err
     13815  rm -f conftest.er1
     13816  cat conftest.err >&5
     13817  echo "$as_me:$LINENO: \$? = $ac_status" >&5
     13818  (exit $ac_status); } &&
     13819         { ac_try='test -z "$ac_c_werror_flag"
     13820                         || test ! -s conftest.err'
     13821  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
     13822  (eval $ac_try) 2>&5
     13823  ac_status=$?
     13824  echo "$as_me:$LINENO: \$? = $ac_status" >&5
     13825  (exit $ac_status); }; } &&
     13826         { ac_try='test -s conftest.$ac_objext'
     13827  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
     13828  (eval $ac_try) 2>&5
     13829  ac_status=$?
     13830  echo "$as_me:$LINENO: \$? = $ac_status" >&5
     13831  (exit $ac_status); }; }; then
     13832  ac_lo=0 ac_mid=0
     13833  while :; do
     13834    cat >conftest.$ac_ext <<_ACEOF
     13835/* confdefs.h.  */
     13836_ACEOF
     13837cat confdefs.h >>conftest.$ac_ext
     13838cat >>conftest.$ac_ext <<_ACEOF
     13839/* end confdefs.h.  */
     13840$ac_includes_default
     13841int
     13842main ()
     13843{
     13844static int test_array [1 - 2 * !(((long) (sizeof (int))) <= $ac_mid)];
     13845test_array [0] = 0
     13846
     13847  ;
     13848  return 0;
     13849}
     13850_ACEOF
     13851rm -f conftest.$ac_objext
     13852if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
     13853  (eval $ac_compile) 2>conftest.er1
     13854  ac_status=$?
     13855  grep -v '^ *+' conftest.er1 >conftest.err
     13856  rm -f conftest.er1
     13857  cat conftest.err >&5
     13858  echo "$as_me:$LINENO: \$? = $ac_status" >&5
     13859  (exit $ac_status); } &&
     13860         { ac_try='test -z "$ac_c_werror_flag"
     13861                         || test ! -s conftest.err'
     13862  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
     13863  (eval $ac_try) 2>&5
     13864  ac_status=$?
     13865  echo "$as_me:$LINENO: \$? = $ac_status" >&5
     13866  (exit $ac_status); }; } &&
     13867         { ac_try='test -s conftest.$ac_objext'
     13868  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
     13869  (eval $ac_try) 2>&5
     13870  ac_status=$?
     13871  echo "$as_me:$LINENO: \$? = $ac_status" >&5
     13872  (exit $ac_status); }; }; then
     13873  ac_hi=$ac_mid; break
     13874else
     13875  echo "$as_me: failed program was:" >&5
     13876sed 's/^/| /' conftest.$ac_ext >&5
     13877
     13878ac_lo=`expr $ac_mid + 1`
     13879                    if test $ac_lo -le $ac_mid; then
     13880                      ac_lo= ac_hi=
     13881                      break
     13882                    fi
     13883                    ac_mid=`expr 2 '*' $ac_mid + 1`
     13884fi
     13885rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
     13886  done
     13887else
     13888  echo "$as_me: failed program was:" >&5
     13889sed 's/^/| /' conftest.$ac_ext >&5
     13890
     13891cat >conftest.$ac_ext <<_ACEOF
     13892/* confdefs.h.  */
     13893_ACEOF
     13894cat confdefs.h >>conftest.$ac_ext
     13895cat >>conftest.$ac_ext <<_ACEOF
     13896/* end confdefs.h.  */
     13897$ac_includes_default
     13898int
     13899main ()
     13900{
     13901static int test_array [1 - 2 * !(((long) (sizeof (int))) < 0)];
     13902test_array [0] = 0
     13903
     13904  ;
     13905  return 0;
     13906}
     13907_ACEOF
     13908rm -f conftest.$ac_objext
     13909if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
     13910  (eval $ac_compile) 2>conftest.er1
     13911  ac_status=$?
     13912  grep -v '^ *+' conftest.er1 >conftest.err
     13913  rm -f conftest.er1
     13914  cat conftest.err >&5
     13915  echo "$as_me:$LINENO: \$? = $ac_status" >&5
     13916  (exit $ac_status); } &&
     13917         { ac_try='test -z "$ac_c_werror_flag"
     13918                         || test ! -s conftest.err'
     13919  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
     13920  (eval $ac_try) 2>&5
     13921  ac_status=$?
     13922  echo "$as_me:$LINENO: \$? = $ac_status" >&5
     13923  (exit $ac_status); }; } &&
     13924         { ac_try='test -s conftest.$ac_objext'
     13925  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
     13926  (eval $ac_try) 2>&5
     13927  ac_status=$?
     13928  echo "$as_me:$LINENO: \$? = $ac_status" >&5
     13929  (exit $ac_status); }; }; then
     13930  ac_hi=-1 ac_mid=-1
     13931  while :; do
     13932    cat >conftest.$ac_ext <<_ACEOF
     13933/* confdefs.h.  */
     13934_ACEOF
     13935cat confdefs.h >>conftest.$ac_ext
     13936cat >>conftest.$ac_ext <<_ACEOF
     13937/* end confdefs.h.  */
     13938$ac_includes_default
     13939int
     13940main ()
     13941{
     13942static int test_array [1 - 2 * !(((long) (sizeof (int))) >= $ac_mid)];
     13943test_array [0] = 0
     13944
     13945  ;
     13946  return 0;
     13947}
     13948_ACEOF
     13949rm -f conftest.$ac_objext
     13950if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
     13951  (eval $ac_compile) 2>conftest.er1
     13952  ac_status=$?
     13953  grep -v '^ *+' conftest.er1 >conftest.err
     13954  rm -f conftest.er1
     13955  cat conftest.err >&5
     13956  echo "$as_me:$LINENO: \$? = $ac_status" >&5
     13957  (exit $ac_status); } &&
     13958         { ac_try='test -z "$ac_c_werror_flag"
     13959                         || test ! -s conftest.err'
     13960  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
     13961  (eval $ac_try) 2>&5
     13962  ac_status=$?
     13963  echo "$as_me:$LINENO: \$? = $ac_status" >&5
     13964  (exit $ac_status); }; } &&
     13965         { ac_try='test -s conftest.$ac_objext'
     13966  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
     13967  (eval $ac_try) 2>&5
     13968  ac_status=$?
     13969  echo "$as_me:$LINENO: \$? = $ac_status" >&5
     13970  (exit $ac_status); }; }; then
     13971  ac_lo=$ac_mid; break
     13972else
     13973  echo "$as_me: failed program was:" >&5
     13974sed 's/^/| /' conftest.$ac_ext >&5
     13975
     13976ac_hi=`expr '(' $ac_mid ')' - 1`
     13977                       if test $ac_mid -le $ac_hi; then
     13978                         ac_lo= ac_hi=
     13979                         break
     13980                       fi
     13981                       ac_mid=`expr 2 '*' $ac_mid`
     13982fi
     13983rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
     13984  done
     13985else
     13986  echo "$as_me: failed program was:" >&5
     13987sed 's/^/| /' conftest.$ac_ext >&5
     13988
     13989ac_lo= ac_hi=
     13990fi
     13991rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
     13992fi
     13993rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
     13994# Binary search between lo and hi bounds.
     13995while test "x$ac_lo" != "x$ac_hi"; do
     13996  ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
     13997  cat >conftest.$ac_ext <<_ACEOF
     13998/* confdefs.h.  */
     13999_ACEOF
     14000cat confdefs.h >>conftest.$ac_ext
     14001cat >>conftest.$ac_ext <<_ACEOF
     14002/* end confdefs.h.  */
     14003$ac_includes_default
     14004int
     14005main ()
     14006{
     14007static int test_array [1 - 2 * !(((long) (sizeof (int))) <= $ac_mid)];
     14008test_array [0] = 0
     14009
     14010  ;
     14011  return 0;
     14012}
     14013_ACEOF
     14014rm -f conftest.$ac_objext
     14015if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
     14016  (eval $ac_compile) 2>conftest.er1
     14017  ac_status=$?
     14018  grep -v '^ *+' conftest.er1 >conftest.err
     14019  rm -f conftest.er1
     14020  cat conftest.err >&5
     14021  echo "$as_me:$LINENO: \$? = $ac_status" >&5
     14022  (exit $ac_status); } &&
     14023         { ac_try='test -z "$ac_c_werror_flag"
     14024                         || test ! -s conftest.err'
     14025  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
     14026  (eval $ac_try) 2>&5
     14027  ac_status=$?
     14028  echo "$as_me:$LINENO: \$? = $ac_status" >&5
     14029  (exit $ac_status); }; } &&
     14030         { ac_try='test -s conftest.$ac_objext'
     14031  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
     14032  (eval $ac_try) 2>&5
     14033  ac_status=$?
     14034  echo "$as_me:$LINENO: \$? = $ac_status" >&5
     14035  (exit $ac_status); }; }; then
     14036  ac_hi=$ac_mid
     14037else
     14038  echo "$as_me: failed program was:" >&5
     14039sed 's/^/| /' conftest.$ac_ext >&5
     14040
     14041ac_lo=`expr '(' $ac_mid ')' + 1`
     14042fi
     14043rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
     14044done
     14045case $ac_lo in
     14046?*) ac_cv_sizeof_int=$ac_lo;;
     14047'') { { echo "$as_me:$LINENO: error: cannot compute sizeof (int), 77
     14048See \`config.log' for more details." >&5
     14049echo "$as_me: error: cannot compute sizeof (int), 77
     14050See \`config.log' for more details." >&2;}
     14051   { (exit 1); exit 1; }; } ;;
     14052esac
     14053else
     14054  if test "$cross_compiling" = yes; then
     14055  { { echo "$as_me:$LINENO: error: cannot run test program while cross compiling
     14056See \`config.log' for more details." >&5
     14057echo "$as_me: error: cannot run test program while cross compiling
     14058See \`config.log' for more details." >&2;}
    1375514059   { (exit 1); exit 1; }; }
    1375614060else
    1375714061  cat >conftest.$ac_ext <<_ACEOF
     
    1376014064cat confdefs.h >>conftest.$ac_ext
    1376114065cat >>conftest.$ac_ext <<_ACEOF
    1376214066/* end confdefs.h.  */
     14067$ac_includes_default
     14068long longval () { return (long) (sizeof (int)); }
     14069unsigned long ulongval () { return (long) (sizeof (int)); }
    1376314070#include <stdio.h>
    13764                 main()
    13765                 {
    13766                   FILE *f=fopen("conftestval", "w");
    13767                   if (!f) exit(1);
    13768                   fprintf(f, "%d\n", (int)sizeof(int));
    13769                   exit(0);
    13770                 }
     14071#include <stdlib.h>
     14072int
     14073main ()
     14074{
     14075
     14076  FILE *f = fopen ("conftest.val", "w");
     14077  if (! f)
     14078    exit (1);
     14079  if (((long) (sizeof (int))) < 0)
     14080    {
     14081      long i = longval ();
     14082      if (i != ((long) (sizeof (int))))
     14083        exit (1);
     14084      fprintf (f, "%ld\n", i);
     14085    }
     14086  else
     14087    {
     14088      unsigned long i = ulongval ();
     14089      if (i != ((long) (sizeof (int))))
     14090        exit (1);
     14091      fprintf (f, "%lu\n", i);
     14092    }
     14093  exit (ferror (f) || fclose (f) != 0);
     14094
     14095  ;
     14096  return 0;
     14097}
    1377114098_ACEOF
    1377214099rm -f conftest$ac_exeext
    1377314100if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
     
    1378014107  ac_status=$?
    1378114108  echo "$as_me:$LINENO: \$? = $ac_status" >&5
    1378214109  (exit $ac_status); }; }; then
    13783   ac_cv_sizeof_int=`cat conftestval`
     14110  ac_cv_sizeof_int=`cat conftest.val`
    1378414111else
    1378514112  echo "$as_me: program exited with status $ac_status" >&5
    1378614113echo "$as_me: failed program was:" >&5
    1378714114sed 's/^/| /' conftest.$ac_ext >&5
    1378814115
    1378914116( exit $ac_status )
    13790 ac_cv_sizeof_int=0
     14117{ { echo "$as_me:$LINENO: error: cannot compute sizeof (int), 77
     14118See \`config.log' for more details." >&5
     14119echo "$as_me: error: cannot compute sizeof (int), 77
     14120See \`config.log' for more details." >&2;}
     14121   { (exit 1); exit 1; }; }
    1379114122fi
    1379214123rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
    1379314124fi
    1379414125fi
    13795 
     14126rm -f conftest.val
     14127else
     14128  ac_cv_sizeof_int=0
     14129fi
     14130fi
    1379614131echo "$as_me:$LINENO: result: $ac_cv_sizeof_int" >&5
    1379714132echo "${ECHO_T}$ac_cv_sizeof_int" >&6
    1379814133cat >>confdefs.h <<_ACEOF
     
    1380014135_ACEOF
    1380114136
    1380214137
     14138
    1380314139echo "$as_me:$LINENO: checking whether memmove/bcopy/memcpy handle overlaps" >&5
    1380414140echo $ECHO_N "checking whether memmove/bcopy/memcpy handle overlaps... $ECHO_C" >&6
    1380514141bcopy_test_prog='
     
    1381814154
    1381914155
    1382014156if test "$cross_compiling" = yes; then
    13821   { { echo "$as_me:$LINENO: error: failed to compile test program" >&5
    13822 echo "$as_me: error: failed to compile test program" >&2;}
    13823    { (exit 1); exit 1; }; }
     14157  { echo "$as_me:$LINENO: WARNING: failed to compile test program" >&5
     14158echo "$as_me: WARNING: failed to compile test program" >&2;}
    1382414159else
    1382514160  cat >conftest.$ac_ext <<_ACEOF
    1382614161/* confdefs.h.  */
     
    1385314188
    1385414189( exit $ac_status )
    1385514190if test "$cross_compiling" = yes; then
    13856   { { echo "$as_me:$LINENO: error: failed to compile test program" >&5
    13857 echo "$as_me: error: failed to compile test program" >&2;}
    13858    { (exit 1); exit 1; }; }
     14191  { echo "$as_me:$LINENO: WARNING: failed to compile test program" >&5
     14192echo "$as_me: WARNING: failed to compile test program" >&2;}
    1385914193else
    1386014194  cat >conftest.$ac_ext <<_ACEOF
    1386114195/* confdefs.h.  */
     
    1388814222
    1388914223( exit $ac_status )
    1389014224if test "$cross_compiling" = yes; then
    13891   { { echo "$as_me:$LINENO: error: failed to compile test program" >&5
    13892 echo "$as_me: error: failed to compile test program" >&2;}
    13893    { (exit 1); exit 1; }; }
     14225  { echo "$as_me:$LINENO: WARNING: failed to compile test program" >&5
     14226echo "$as_me: WARNING: failed to compile test program" >&2;}
    1389414227else
    1389514228  cat >conftest.$ac_ext <<_ACEOF
    1389614229/* confdefs.h.  */
  • src/configure.in

    diff -Naur vim70.orig/src/configure.in vim70/src/configure.in
    old new  
    4747  fi
    4848fi
    4949
    50 dnl If configure thinks we are cross compiling, there is probably something
    51 dnl wrong with the CC or CFLAGS settings, give an understandable error message
    52 if test "$cross_compiling" = yes; then
    53   AC_MSG_ERROR([cannot compile a simple program, check CC and CFLAGS
    54   (cross compiling doesn't work)])
    55 fi
    56 
    5750dnl gcc-cpp has the wonderful -MM option to produce nicer dependencies.
    5851dnl But gcc 3.1 changed the meaning!  See near the end.
    5952test "$GCC" = yes && CPP_MM=M; AC_SUBST(CPP_MM)
     
    183176AC_SUBST(OS_EXTRA_SRC)
    184177AC_SUBST(OS_EXTRA_OBJ)
    185178
    186 dnl Add /usr/local/lib to $LDFLAGS and /usr/local/include to CFLAGS.
    187 dnl Only when the directory exists and it wasn't there yet.
    188 dnl For gcc don't do this when it is already in the default search path.
    189 have_local_include=''
    190 have_local_lib=''
    191 if test "$GCC" = yes; then
    192   echo 'void f(){}' > conftest.c
    193   dnl -no-cpp-precomp is needed for OS X 10.2 (Ben Fowler)
    194   have_local_include=`${CC-cc} -no-cpp-precomp -c -v conftest.c 2>&1 | grep '/usr/local/include'`
    195   have_local_lib=`${CC-cc} -c -v conftest.c 2>&1 | grep '/usr/local/lib'`
    196   rm -f conftest.c conftest.o
    197 fi
    198 if test -z "$have_local_lib" -a -d /usr/local/lib; then
    199   tt=`echo "$LDFLAGS" | sed -e 's+-L/usr/local/lib ++g' -e 's+-L/usr/local/lib$++g'`
    200   if test "$tt" = "$LDFLAGS"; then
    201     LDFLAGS="$LDFLAGS -L/usr/local/lib"
    202   fi
    203 fi
    204 if test -z "$have_local_include" -a -d /usr/local/include; then
    205   tt=`echo "$CPPFLAGS" | sed -e 's+-I/usr/local/include ++g' -e 's+-I/usr/local/include$++g'`
    206   if test "$tt" = "$CPPFLAGS"; then
    207     CPPFLAGS="$CPPFLAGS -I/usr/local/include"
    208   fi
    209 fi
    210 
    211179AC_MSG_CHECKING(--with-vim-name argument)
    212180AC_ARG_WITH(vim-name, [  --with-vim-name=NAME    what to call the Vim executable],
    213181        VIMNAME="$withval"; AC_MSG_RESULT($VIMNAME),
     
    19771945AC_TRY_RUN([#include <ctype.h>
    19781946main() { exit(toupper('A') == 'A' && tolower('z') == 'z'); }],
    19791947        AC_DEFINE(BROKEN_TOUPPER) AC_MSG_RESULT(bad),
    1980         AC_MSG_RESULT(good), AC_MSG_ERROR(failed to compile test program))
     1948        AC_MSG_RESULT(good), AC_MSG_WARN(failed to compile test program))
    19811949
    19821950AC_MSG_CHECKING(whether __DATE__ and __TIME__ work)
    19831951AC_TRY_COMPILE(, [printf("(" __DATE__ " " __TIME__ ")");],
     
    21972165{char *s; s=(char *)tgoto("%p1%d", 0, 1); exit(!strcmp(s==0 ? "" : s, "1")); }],
    21982166          AC_MSG_RESULT([no -- we are in termcap land]),
    21992167          AC_MSG_RESULT([yes -- terminfo spoken here]); AC_DEFINE(TERMINFO),
    2200           AC_MSG_ERROR(failed to compile test program.))
     2168          AC_MSG_WARN(failed to compile test program.)
     2169          AC_DEFINE(TERMINFO))
    22012170
    22022171if test "x$olibs" != "x$LIBS"; then
    22032172  AC_MSG_CHECKING(what tgetent() returns for an unknown terminal)
     
    23602329    fi
    23612330],
    23622331    AC_MSG_RESULT([can't determine - assume ptys are world accessable]),
    2363     AC_MSG_ERROR(failed to compile test program))
     2332    AC_MSG_WARN(failed to compile test program))
    23642333rm -f conftest_grp
    23652334
    23662335dnl Checks for library functions. ===================================
     
    24032372        AC_MSG_RESULT(it is usable),
    24042373        AC_MSG_RESULT(it stinks)
    24052374                AC_DEFINE(BAD_GETCWD),
    2406         AC_MSG_ERROR(failed to compile test program))
     2375        AC_MSG_WARN(failed to compile test program))
    24072376
    24082377dnl Check for functions in one big call, to reduce the size of configure
    24092378AC_CHECK_FUNCS(bcmp fchdir fchown fseeko fsync ftello getcwd getpseudotty \
     
    24272396        AC_MSG_RESULT(yes); AC_DEFINE(HAVE_ST_BLKSIZE),
    24282397        AC_MSG_RESULT(no))
    24292398
    2430 AC_MSG_CHECKING(whether stat() ignores a trailing slash)
     2399AC_CACHE_CHECK([whether stat() ignores a trailing slash],
     2400              [ac_cv_func_stat_ignores_trailing_slash],
    24312401AC_TRY_RUN(
    24322402[#include <sys/types.h>
    24332403#include <sys/stat.h>
    24342404main() {struct stat st;  exit(stat("configure/", &st) != 0); }],
    2435         AC_MSG_RESULT(yes); AC_DEFINE(STAT_IGNORES_SLASH),
    2436         AC_MSG_RESULT(no), AC_MSG_ERROR(failed to compile test program))
     2405       ac_cv_func_stat_ignores_trailing_slash=yes,
     2406       ac_cv_func_stat_ignores_trailing_slash=no,
     2407       ac_cv_func_stat_ignores_trailing_slash=no
     2408))
     2409
     2410if X"$ac_cv_func_stat_ignores_trailing_slash" = Xyes; then
     2411       AC_DEFINE(STAT_IGNORES_SLASH)
     2412fi
    24372413
    24382414dnl Link with iconv for charset translation, if not found without library.
    24392415dnl check for iconv() requires including iconv.h
     
    25972573        AC_MSG_RESULT(yes); AC_DEFINE(HAVE_SYSCONF),
    25982574        AC_MSG_RESULT(not usable))
    25992575
    2600 dnl Our own version of AC_CHECK_SIZEOF(int); fixes a bug when sizeof() can't
    2601 dnl be printed with "%d", and avoids a warning for cross-compiling.
    2602 
    2603 AC_MSG_CHECKING(size of int)
    2604 AC_CACHE_VAL(ac_cv_sizeof_int,
    2605         [AC_TRY_RUN([#include <stdio.h>
    2606                 main()
    2607                 {
    2608                   FILE *f=fopen("conftestval", "w");
    2609                   if (!f) exit(1);
    2610                   fprintf(f, "%d\n", (int)sizeof(int));
    2611                   exit(0);
    2612                 }],
    2613             ac_cv_sizeof_int=`cat conftestval`,
    2614             ac_cv_sizeof_int=0,
    2615             AC_MSG_ERROR(failed to compile test program))])
    2616 AC_MSG_RESULT($ac_cv_sizeof_int)
    2617 AC_DEFINE_UNQUOTED(SIZEOF_INT, $ac_cv_sizeof_int)
     2576AC_CHECK_SIZEOF(int)
    26182577
    26192578AC_MSG_CHECKING(whether memmove/bcopy/memcpy handle overlaps)
    26202579[bcopy_test_prog='
     
    26402599        AC_DEFINE(USEBCOPY) AC_MSG_RESULT(bcopy does),
    26412600        AC_TRY_RUN([#define mch_memmove(s,d,l) memcpy(d,s,l) $bcopy_test_prog],
    26422601            AC_DEFINE(USEMEMCPY) AC_MSG_RESULT(memcpy does), AC_MSG_RESULT(no),
    2643             AC_MSG_ERROR(failed to compile test program)),
    2644         AC_MSG_ERROR(failed to compile test program)),
    2645     AC_MSG_ERROR(failed to compile test program))
     2602            AC_MSG_WARN(failed to compile test program)),
     2603        AC_MSG_WARN(failed to compile test program)),
     2604    AC_MSG_WARN(failed to compile test program))
    26462605
    26472606dnl Check for multibyte locale functions
    26482607dnl Find out if _Xsetlocale() is supported by libX11.
Note: See TracBrowser for help on using the repository browser.