Patch 8.0.1686 (after 8.0.1683)
Problem:    Python does not work when configuring with specific dir. (Rajdeep)
Solution:   Do define PYTHON_HOME and PYTHON3_HOME in configure if the Python
            config dir was specified.
Files:      src/configure.ac, src/auto/configure


*** ../vim-8.0.1685/src/configure.ac    2018-04-10 13:26:44.747724302 +0200
--- src/configure.ac    2018-04-10 18:07:25.590443393 +0200
***************
*** 1157,1163 ****
  
        AC_ARG_WITH(python-config-dir,
        [  --with-python-config-dir=PATH  Python's config directory],
!       [ vi_cv_path_python_conf="${withval}" ] )
  
        AC_CACHE_CHECK(Python's configuration directory,vi_cv_path_python_conf,
        [
--- 1157,1163 ----
  
        AC_ARG_WITH(python-config-dir,
        [  --with-python-config-dir=PATH  Python's config directory],
!       [ vi_cv_path_python_conf="${withval}"; have_python_config_dir=1 ] )
  
        AC_CACHE_CHECK(Python's configuration directory,vi_cv_path_python_conf,
        [
***************
*** 1255,1260 ****
--- 1255,1265 ----
        else
          
PYTHON_CFLAGS="-I${vi_cv_path_python_pfx}/include/python${vi_cv_var_python_version}
 -I${vi_cv_path_python_epfx}/include/python${vi_cv_var_python_version}"
        fi
+       if test "X$have_python_config_dir" = "X1"; then
+         dnl Define PYTHON_HOME if --with-python-config-dir was used
+         PYTHON_CFLAGS="${PYTHON_CFLAGS} 
-DPYTHON_HOME='\"${vi_cv_path_python_pfx}\"'"
+ 
+       fi
        PYTHON_SRC="if_python.c"
        PYTHON_OBJ="objects/if_python.o"
        if test "${vi_cv_var_python_version}" = "1.4"; then
***************
*** 1399,1405 ****
    
        AC_ARG_WITH(python3-config-dir,
         [  --with-python3-config-dir=PATH  Python's config directory],
!        [ vi_cv_path_python3_conf="${withval}" ] )
    
        AC_CACHE_CHECK(Python's configuration directory,vi_cv_path_python3_conf,
        [
--- 1404,1410 ----
    
        AC_ARG_WITH(python3-config-dir,
         [  --with-python3-config-dir=PATH  Python's config directory],
!        [ vi_cv_path_python3_conf="${withval}"; have_python3_config_dir=1 ] )
    
        AC_CACHE_CHECK(Python's configuration directory,vi_cv_path_python3_conf,
        [
***************
*** 1464,1469 ****
--- 1469,1478 ----
          else
            
PYTHON3_CFLAGS="-I${vi_cv_path_python3_pfx}/include/python${vi_cv_var_python3_version}${vi_cv_var_python3_abiflags}
 
-I${vi_cv_path_python3_epfx}/include/python${vi_cv_var_python3_version}${vi_cv_var_python3_abiflags}"
          fi
+       if test "X$have_python3_config_dir" = "X1"; then
+         dnl Define PYTHON3_HOME if --with-python-config-dir was used
+         PYTHON3_CFLAGS="${PYTHON3_CFLAGS}  
-DPYTHON3_HOME='L\"${vi_cv_path_python3_pfx}\"'"
+       fi
          PYTHON3_SRC="if_python3.c"
          PYTHON3_OBJ="objects/if_python3.o"
    
*** ../vim-8.0.1685/src/auto/configure  2018-04-10 13:26:44.751724271 +0200
--- src/auto/configure  2018-04-10 18:07:28.322424752 +0200
***************
*** 5955,5961 ****
  
  # Check whether --with-python-config-dir was given.
  if test "${with_python_config_dir+set}" = set; then :
!   withval=$with_python_config_dir;  vi_cv_path_python_conf="${withval}"
  fi
  
  
--- 5955,5961 ----
  
  # Check whether --with-python-config-dir was given.
  if test "${with_python_config_dir+set}" = set; then :
!   withval=$with_python_config_dir;  vi_cv_path_python_conf="${withval}"; 
have_python_config_dir=1
  fi
  
  
***************
*** 6062,6067 ****
--- 6062,6071 ----
        else
          
PYTHON_CFLAGS="-I${vi_cv_path_python_pfx}/include/python${vi_cv_var_python_version}
 -I${vi_cv_path_python_epfx}/include/python${vi_cv_var_python_version}"
        fi
+       if test "X$have_python_config_dir" = "X1"; then
+                 PYTHON_CFLAGS="${PYTHON_CFLAGS} 
-DPYTHON_HOME='\"${vi_cv_path_python_pfx}\"'"
+ 
+       fi
        PYTHON_SRC="if_python.c"
        PYTHON_OBJ="objects/if_python.o"
        if test "${vi_cv_var_python_version}" = "1.4"; then
***************
*** 6312,6318 ****
  
  # Check whether --with-python3-config-dir was given.
  if test "${with_python3_config_dir+set}" = set; then :
!   withval=$with_python3_config_dir;  vi_cv_path_python3_conf="${withval}"
  fi
  
  
--- 6316,6322 ----
  
  # Check whether --with-python3-config-dir was given.
  if test "${with_python3_config_dir+set}" = set; then :
!   withval=$with_python3_config_dir;  vi_cv_path_python3_conf="${withval}"; 
have_python3_config_dir=1
  fi
  
  
***************
*** 6394,6399 ****
--- 6398,6406 ----
          else
            
PYTHON3_CFLAGS="-I${vi_cv_path_python3_pfx}/include/python${vi_cv_var_python3_version}${vi_cv_var_python3_abiflags}
 
-I${vi_cv_path_python3_epfx}/include/python${vi_cv_var_python3_version}${vi_cv_var_python3_abiflags}"
          fi
+       if test "X$have_python3_config_dir" = "X1"; then
+                 PYTHON3_CFLAGS="${PYTHON3_CFLAGS}  
-DPYTHON3_HOME='L\"${vi_cv_path_python3_pfx}\"'"
+       fi
          PYTHON3_SRC="if_python3.c"
          PYTHON3_OBJ="objects/if_python3.o"
  
*** ../vim-8.0.1685/src/version.c       2018-04-10 15:59:04.295392601 +0200
--- src/version.c       2018-04-10 18:12:07.196518596 +0200
***************
*** 764,765 ****
--- 764,767 ----
  {   /* Add new patch number below this line */
+ /**/
+     1686,
  /**/

-- 
We are the Borg of GNU GPL.  We will assimilate your source code.
Resistance is futile.

 /// Bram Moolenaar -- b...@moolenaar.net -- 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

--- 
You received this message because you are subscribed to the Google Groups 
"vim_dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to vim_dev+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Raspunde prin e-mail lui