Steps to reproduce:
1) on Linux,
2) run:
../configure --disable-netbeans --disable-xsmp --enable-gui=no
3) disable FEAT_SESSION:
patch -p0 < /tmp/vim-disable-session.diff
4) compile:
make

Result:
gcc   -L/usr/local/lib -Wl,--as-needed        -o vim objects/arabic.o
objects/beval.o objects/buffer.o objects/blowfish.o objects/crypt.o
objects/crypt_zip.o objects/dict.o objects/diff.o objects/digraph.o
objects/edit.o objects/eval.o objects/evalfunc.o objects/ex_cmds.o
objects/ex_cmds2.o objects/ex_docmd.o objects/ex_eval.o objects/ex_getln.o
objects/farsi.o objects/fileio.o objects/fold.o objects/getchar.o
objects/hardcopy.o objects/hashtab.o  objects/if_cscope.o objects/if_xcmdsrv.o
objects/list.o objects/mark.o objects/memline.o objects/menu.o objects/misc1.o
objects/misc2.o objects/move.o objects/mbyte.o objects/normal.o objects/ops.o
objects/option.o objects/os_unix.o objects/pathdef.o objects/popupmnu.o
objects/pty.o objects/quickfix.o objects/regexp.o objects/screen.o
objects/search.o objects/sha256.o objects/spell.o objects/spellfile.o
objects/syntax.o objects/tag.o objects/term.o objects/terminal.o objects/ui.o
objects/undo.o objects/userfunc.o objects/version.o objects/window.o
objects/term_encoding.o objects/term_keyboard.o objects/term_mouse.o
objects/term_parser.o objects/term_pen.o objects/term_screen.o
objects/term_state.o objects/term_unicode.o objects/term_vterm.o
objects/channel.o  objects/charset.o objects/json.o objects/main.o
objects/memfile.o objects/message.o    -lSM -lICE -lXpm -lXt -lX11 -lXdmcp
-lSM -lICE  -lm -lncurses -lelf -lnsl  -lacl -lattr -lgpm -ldl
objects/buffer.o: In function `do_autochdir':
/tmp/vim-git/src/buffer.c:1815: undefined reference to `vim_chdirfile'          
                                        
collect2: error: ld returned 1 exit status
link.sh: Linking failed
Makefile:1949: recipe for target 'vim' failed
make[1]: *** [vim] Error 1
make[1]: Leaving directory '/tmp/vim-git/src'
Makefile:26: recipe for target 'first' failed
make: *** [first] Error 2

The do_autochdir function (FEAT_AUTOCHDIR) is defined if:
FEAT_SUN_WORKSHOP || FEAT_NETBEANS_INTG || FEAT_BIG

The vim_chdirfile function is defined if:
FEAT_SUN_WORKSHOP || FEAT_NETBEANS_INTG || FEAT_SESSION || MSWIN
|| FEAT_GUI_MAC || FEAT_GUI_GTK

I've got it to link by adding FEAT_AUTOCHDIR to vim_chdirfile ifdefs (see
vim-chdirfile.diff), but I'm not sure if that is the correct way of addressing
the problem (maybe FEAT_BIG should be added instead?).

-- 
-- 
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 [email protected].
For more options, visit https://groups.google.com/d/optout.
--- ./src/feature.h.orig        2018-06-28 19:26:28.000000000 +0200
+++ ./src/feature.h     2018-06-28 20:19:42.958956487 +0200
@@ -577,9 +577,9 @@
  * +mksession          ":mksession" command.
  *                     Requires +windows and +vertsplit.
  */
-#if defined(FEAT_NORMAL)
-# define FEAT_SESSION
-#endif
+// #if defined(FEAT_NORMAL)
+// # define FEAT_SESSION
+// #endif
 
 /*
  * +multi_lang         Multi language support. ":menutrans", ":language", etc.
diff --git a/src/misc2.c b/src/misc2.c
--- a/src/misc2.c
+++ b/src/misc2.c
@@ -3384,6 +3384,7 @@ same_directory(char_u *f1, char_u *f2)
 #if defined(FEAT_SESSION) || defined(MSWIN) || defined(FEAT_GUI_MAC) \
        || defined(FEAT_GUI_GTK) \
        || defined(FEAT_SUN_WORKSHOP) || defined(FEAT_NETBEANS_INTG) \
+       || defined(FEAT_AUTOCHDIR) \
        || defined(PROTO)
 /*
  * Change to a file's directory.

Raspunde prin e-mail lui