Annotation of src/usr.bin/vim/version.c, Revision 1.2
1.2 ! downsj 1: /* $OpenBSD: version.c,v 1.1.1.1 1996/09/07 21:40:24 downsj Exp $ */
1.1 downsj 2: /* vi:set ts=4 sw=4:
3: *
4: * VIM - Vi IMproved by Bram Moolenaar
5: *
6: * Do ":help uganda" in Vim to read copying and usage conditions.
7: * Do ":help credits" in Vim to see a list of people who contributed.
8: */
9:
10: #include "vim.h"
11: #include "globals.h"
12: #include "proto.h"
13:
14: /*
15: * Vim originated from Stevie version 3.6 (Fish disk 217) by GRWalter (Fred)
16: * It has been changed beyond recognition since then.
17: *
18: * All the remarks about older versions have been removed, they are not very
1.2 ! downsj 19: * interesting. Differences between version 3.0 and 4.x can be found in
1.1 downsj 20: * "../doc/vim_40.txt".
21: *
1.2 ! downsj 22: * Changes between version 4.3 BETA and 4.4 BETA:
! 23: * - Moved outputting newline from getout() to mch_windexit(). Helps when
! 24: * switching display pages in xterm after an error message for ":!".
! 25: * - Fixed problem: Not executing BufEnter autocommands for first buffer.
! 26: * - Fixed Makefile: "make shadow" didn't make ctags and xxd directories. Now
! 27: * passes CC and CFLAGS to ctags and xxd makefiles.
! 28: * - Removed use of #elif, some old compilers don't understand it.
! 29: * - Included version 1.4 of ctags. New Makefile.bcc, supports wildcards for
! 30: * 16 bit DOS version.
! 31: * - Fixed mouse positioning in wrong column for MSDOS 16 and 32 bit versions.
! 32: * - Fixed: Delay in updating Visual area when using "/pat".
! 33: * - Fixed: With some shells gvim could be killed with CTRL-C in the shell
! 34: * where it was started.
! 35: * - Fixed: For abbreviations entered with ":noreab" only the first two
! 36: * characters were not re-mapped instead of all.
! 37: * - Added help tags for search pattern special characters. Adjusted
! 38: * doctags.c to insert a backslash before a backslash.
! 39: * - Fixed Vi incompatibility: If the rhs of a mapping starts with the lhs,
! 40: * remapping is only disabled for the first character, not the whole lhs.
! 41: * - Fixed: Default padding character was a space, which caused trouble on
! 42: * some systems. Now it's a NUL.
! 43: * - Fixed: With GUI Athena the scrollbar could get stuck at the bottom.
! 44: * - Fixed: When using :imenu to insert more than one line of text, only the
! 45: * first line could be undone.
! 46: * - Fixed: Word completion (CTRL-N) in Insert mode, when there was not
! 47: * matching word, the "Pattern not found" message was not shown.
! 48: * - Fixed: Pattern completion (CTRL-X I) in Insert mode; the file name shown
! 49: * was overwritten with the mode message.
! 50: * - Added ":if" and ":endif" commands. Everything in between them is
! 51: * ingored. Just to allow for future expansion that is backwards compatible.
! 52: * - Fixed: Starting Vim without a file, then ":e file", ":sp" and ":q"
! 53: * unloaded the buffer.
! 54: * - Fixed: execution of autocommands could not be interrupted.
! 55: * - Fixed: "ga" on an empty line gave a misleading message, now it prints
! 56: * "empty line".
! 57: * - Fixed: With 'number' set mouse positioning was wrong when lines wrap, and
! 58: * in the GUI horizontal scrolling didn't work properly.
! 59: * - Removed "src/tags" from the source distribution; you can generate it
! 60: * yourself now that ctags is included.
! 61: * - Included "macros/life", macros to run Conway's game of life.
! 62: * - Fixed using "set go=r" in gvimrc problem for Motif GUI.
! 63: * - Fixed problems when using autocommands with ":next" et. al.. Made
! 64: * "line1", "line2" and "forceit" local variables, instead of global. Lots
! 65: * of function have to pass it as an argument, which is required to avoid
! 66: * the vars to get mixed up with recursive Ex commands.
! 67: * - Removed the use of "want_start" in search.c. Fixes bug when using a
! 68: * search string that starts with "^" and contains "\|".
! 69: *
! 70: * Changes between version 4.2 and 4.3 BETA:
! 71: * - Moved ctags, tee and xxd sources from the binary to the source archive.
! 72: * - OS/2: Adjusted ExpandWildCards again, fixed alloc/free error.
! 73: * - Fixed: "Nothing in register ^@", ^@ for buffer 0 is now "
! 74: * - Fixed: Was outputting CR CR LF instead of CR LF for termios.
! 75: * - Fixed: cindent didn't handle "} else" and "} while (cond);".
! 76: * - Fixed: Was using killpg(0, SIGINT) to interrupt external commands in the
! 77: * GUI, which isn't documented on all systems. Use kill(0, SIGINT) instead.
! 78: * - Updated version number that is compared with for the ":version" command.
! 79: * - Fixed: ":0put" inserted text below line 1; now it inserts above line 1.
! 80: * - Fixed: "/t/e" would not find the last character in a line.
! 81: * - Fixed: Unloading the current buffer could load another unloaded buffer.
! 82: * Use a loaded buffer if there is one.
! 83: * - Improved: ":dis" now shows "^J" at the end of linewise registers.
! 84: * - Fixed: Using ":q" to close a window didn't execute the BufEnter
! 85: * autocommands for the new current window.
! 86: * - Forbid the reading of a file after *ReadPre autocommands, this could give
! 87: * unpredictable results.
! 88: * - Fixed: ":sball" didn't work correctly with autocommands that contain a
! 89: * ":normal" command.
! 90: * - Fixed: was accepting a mapping after CTRL-W count.
! 91: * - Fixed: a '[' in a regexp was special, made "/[z[]/" fail.
! 92: * - Amiga, DICE: included a few patches to amiga.c.
! 93: * - Fixed: Could crash when completing a setting, e.g. ":set <t_K<Tab>"
! 94: * - Fixed: Using "new fname" in a vimrc caused a window with a non-existing
! 95: * buffer.
! 96: * - Added support for keypad keys <kHome>, <kEnd>, <kPageUp> and <kPageDown>.
! 97: * They only work when they send a different code from <Home>, etc..
! 98: * - Swapped the arguments to LINKIT in Makefile, was making a link from Vim,
! 99: * instead of to Vim.
! 100: * - Fixed: Not all parts of the swap file were cleared before using them,
! 101: * could include any data in the swap file (mostly the password file!).
! 102: * - Fixed: Could get an extra swap file when using ":au BufLeave xx bd xx".
! 103: * - Fixed: ":set comment=n:" didn't give an error message; formatting would
! 104: * cause a hang.
! 105: * - Use off_t for lseek; FreeBSD and others use long long instead of long.
! 106: * - Fixed: ":/pat" didn't match at first column in the next line.
! 107: * - Fixed: CTRL-F at end of file with 'scrolloff' non-zero would make the
! 108: * screen jump up and down and didn't beep when no more scrolling was
! 109: * possible. When last two lines didn't fit on the screen together, the
! 110: * last one was never shown.
! 111: * - When Vim is not compiled with AUTOCMD, "<afile>" is not included.
! 112: * - Fixed: ":au BufWritePre xx bunload" caused empty file to be written, now
! 113: * it gives an error message.
! 114: * - Added "<Bar>", to be used in mappings where a '|' is needed.
! 115: * - Moved "Changing readonly file" message, In insert mode, to after the mode
! 116: * message, it would otherwise be hidden.
! 117: * - Fixed: Putting a temp file in current directory for MS-DOS causes
! 118: * problems on readonly devices. Try several directories to put the temp
! 119: * file in.
! 120: * - Changed default for Unix 'errorformat' to include a few more compilers.
! 121: * - Fixed: When exiting because of a non-existing file after the "-e"
! 122: * argument, there was no newline.
! 123: * - When writing part of a buffer to a file, don't add a end-of-line for the
! 124: * last line, if 'binary' is set and the previous read didn't have an
! 125: * end-of-line for the same line. For FileWritePre autocommands that filter
! 126: * the lines through gzip.
! 127: * - Fixed: When not writing the eol for the last line, this was not visible,
! 128: * and the line count was one too low.
! 129: * - Fixed: BufNewFile autocommands that do ":r file" sometimes didn't work,
! 130: * because the cursor was in an invalid line.
! 131: * - Fixed: a *ReadFile autocommand that changed the file to be read didn't
! 132: * work, because the file was already opened.
! 133: * - Fixed: When doing ":bdel", buf_copy_options() could copy options from
! 134: * already freed memory. Would cause any combination of strange settings.
! 135: * - Check for errors while reading the viminfo file. When there are more
! 136: * than 10 errors, quit reading it. When there is any error, don't
! 137: * overwrite it with a new viminfo file. Prevents trashing a file when
! 138: * accidently doing "vim -i file" instead of "vim -v file".
! 139: * - Added "ZQ", alias for ":q!". Elvis compatible.
! 140: * - Fixed: "vim -g" would crash when .gvimrc contains ":set go=r".
! 141: * - Fixed: ":set go&" didn't work, the default contained an illegal 'A'.
! 142: * - Added 'titlelen' option: percentage of 'columns' to use for the title.
! 143: * Reduces problems with truncating long path names.
! 144: * - Added "tee" for OS/2. Very useful for ":make".
! 145: * - Fixed: Setting 'title' in the gvimrc messed up the title of the xterm
! 146: * where Vim was started when doing ":gui".
! 147: * - Fixed: When expanding "~/file" with CTRL-X CTRL-F in insert mode, the
! 148: * "~/" would get expanded into a full path. For "~user/file" the problem
! 149: * still exists though.
! 150: * - Fixed: ":set path=../b" didn't work as expected, any path starting with a
! 151: * dot would get expanded to the directory of the current file.
! 152: * - Fixed: Any dir name in 'directory' and 'backupdir' starting with '.' was
! 153: * considered to be in the current directory, also "..". Now using "./dir"
! 154: * means using a directory relative to where the file is.
! 155: * - Fixed: ":all", ":ball" and "-o" command line option would execute
! 156: * Buf/Win Enter/Leave autocommands for first buffer a few times. Now
! 157: * they are only done when really entering a buffer/window.
! 158: * - Fixed: ":all", change in first buffer, ":all" would give an error message
! 159: * for not writing the file.
! 160: * - Added 'shellcmdflag' and 'shellquote' options, mainly for Win32 when
! 161: * using different kinds of shell.
! 162: * - Fixed: "unmenu *" in .gvimrc caused a crash on some machines.
! 163: * - Fixed: ":buf" (go to current buffer) should not do anything. It executed
! 164: * autocommands and set the previous context mark.
! 165: * - Fixed: "*``" moved the cursor back to the start of the word, instead of
! 166: * where the cursor was within or before the word.
! 167: * - Fixed: ":e %:p:h" removed the head of the path ("/" for unix, "d:\" for
! 168: * DOS, "drive:" for Amiga.
! 169: * - Fixed: for the Win32 version, 'term' must be "win32", don't init it with
! 170: * $TERM.
! 171: * - Fixed: Filename completion with <Tab>, when there are several matches,
! 172: * but only one without ignored suffix, next <Tab> obtained second match,
! 173: * not the one after the previous one. Now the files without matching
! 174: * suffix are put in front of the list.
! 175: * - Fixed: DJGPP version of system() was eating file descriptors, after a few
! 176: * filter commands there would be an "Out of file handles" error.
! 177: * - Fixed: for MS-DOS: ":n doc\*.txt" didn't work, it became "doc*.txt".
! 178: * - Added: MS-DOS and WIN32 now expand $ENV in a filename. ":e $VIM/_vimrc"
! 179: * works now.
! 180: * - Fixed: MS-DOS: after ":mode 1" mouse didn't move correctly. Now it
! 181: * mostly works for the display modes up to 0x13.
! 182: * - Fixed: In Insert mode, the message from "^O:set tw" would be overwritten
! 183: * by "--INSERT--". Now there is a 10 second delay to be able to read the
! 184: * message.
! 185: *
1.1 downsj 186: * Changes between version 4.1 and 4.2:
187: * - Included ctags version 1.3.
188: * - Included xxd.c version 1.4 (only one change since 1.3m)
189: * - Unix: Adjusted check for child finished again. Now use != ECHILD
190: * instead of == EINTR.
191: * - Fixed: loading compressed files (with autocommands) didn't work when
192: * 'textmode' was previously set.
193: * - Fixed: When executing a shell, a window resize was not recognized for
194: * Unix.
195: * - Fixed: For GUI, when executing an external command, a window resize
196: * caused the buffer to be redrawn.
197: * - Fixed: Error message for not being able to open the .viminfo file could
198: * report the wrong filename.
199: * - MS-DOS, Win32, OS/2: When $HOME is not set, use "C:/".
200: * - OS/2: Improved handling of wildcards again. Didn't ignore case, didn't
201: * work with backslashes.
202: * - Fixed: ":s/pat<Tab>" could cause a core dump or other problems.
203: * - Fixed: When entering a hidden buffer with ":e", the BufEnter autocommands
204: * were not executed.
205: * - Fixed: Ignoring a CTRL-Z at end-of-file was only done on MS-DOS. Now it
206: * also works on other systems, but only in textmode.
207: * - Fixed: In the GUI special characters were not passed on to external
208: * commands, typeahead was truncated.
209: * - Added "gq" as an alias to "Q". Should be used when "Q" is made to be Vi
210: * compatible: go to Ex mode.
211: * - Fixed: "gu" in Visual mode could not be redone with "." correctly.
212: * - Fixed: ":normal" command made any typeahead executed right away, causing
213: * unpredictable problems.
214: * - Fixed: ":normal atest^[" didn't update the screen.
215: * - Fixed: Redoing blockwise visual delete at the end of the file could cause
216: * "invalid line number" errors.
217: * - Fixed: vim_rename() didn't open the output file in binary mode, could
218: * cause the .viminfo file to contain CR-LF on OS/2.
219: * - Fixed: OS/2 was using /tmp/xxx for temporary file name, would fail if
220: * there is no /tmp directory. Now use $TMP/xxx, defaulting to c:/ if $TMP
221: * is not set.
222: * - Fixed: When USE_TMPNAM was defined, was using the wrong array size for
223: * the viminfo temporary file.
224: *
225: * Changes between version 4.0 and 4.1:
226: *
227: * - Included xxd.c version 1.3m.
228: * - Included ctags version 1.2.
229: * - Included tools/efm_filt.er.
230: * - Included changes for port to Atari MiNT, including makefile.mint.
231: * - Included a few changes for OS/2: Improved executing external commands,
232: * depending on the shell; Handle resize after executing an external
233: * command; Handle wildcard expansion for more than one argument (e.g.
234: * ":n *.c *.h").
235: * - Include a lot of small changes to the docs.
236: * - Fixed: GUI version would busy-loop and mappings didn't work. Was caused
237: * by gui_mch_wait_for_chars() not working properly. This fix was the main
238: * reason for releasing 4.1.
239: * - Fixed: setting 'term' while GUI is active was possible, and caused
240: * problems.
241: * - Fixed: When the "to" part of a mapping or menu command was long (more
242: * than 24 chars on 32 bit MS-DOS, 128 chars on other systems), any <> were
243: * not translated and CTRL-Vs not removed.
244: * - Fixed: 'modified' option was included for ":mkvimrc", it shouldn't.
245: * - Included a few changes for that Atari MiNT port (vt52 builtin term
246: * entry).
247: * - Fixed: on MS-DOS a file name pattern for an autocommand that contains
248: * "\*" or "\?" didn't work.
249: * - On MS-DOS and Amiga, ignore case when matching the file name pattern for
250: * autocommands.
251: * - Fixed: using :set to show the value of two options gave an error message
252: * (e.g. ":set so sj").
253: * - Fixed: Non-printable characters in a file name caused trouble when
254: * displayed in a status line.
255: * - Pack the MS-DOS zip files with Infozip, under Unix. Preserves the long
256: * filenames and case. Files with two dots don't work though, the first dot
257: * is replaced with an underscore.
258: * - Fixed: Pasting more than one line with the mouse in insert mode, didn't
259: * put the cursor after the last pasted character.
260: * - When pasting linewise text, put the '] mark on the last character of the
261: * last line, instead of the first character of the last line.
262: * - Fixed: on some Unix systems, when resizing the window while in a external
263: * command (e.g., ":!cat"), Vim would stop waiting for the child, causing
264: * trouble, because the child is still running.
265: * - Fixed: resizing the window while executing an external command, and
266: * 't_ti' and 't_te' are defined to swap display buffers, Vim would redraw
267: * in the wrong display buffer after the "hit RETURN" message.
268: * - Fixed: "va", "vA", "Vp", "VP", "Vs" and "VS" didn't set the cursor
269: * position used for up/down movements (e.g., when using "j" after them).
270: * - Fixed: in GUI version, after using "cw" visual selection by dragging the
271: * mouse didn't work.
272: * - Fixed: setting 'ttyscroll' to 0 caused scrolling of message to stop
273: * working.
274: * - Fixed: the "WARNING: file changed" message caused buffers to be flushed
275: * and subsequent commands not to be executed.
276: * - Fixed: in Insert mode, the message from "^O^G" would be
277: * overwritten by the mode message if 'showmode' set.
278: * - Fixed: Using ":bdel" when there is only one buffer with two windows,
279: * could cause a crash.
280: * - Changed: the '<' flag in 'cpoptions' now only switches off the
281: * recognizing of the <> form of key codes. The 'k' flag is now used for
282: * the recognizing of raw key codes.
283: * - Fixed: Typing ':' at the --more-- prompt, when displaying autocommands,
284: * caused extra linefeeds to be produced.
285: * - Fixed: Using 'tagrelative' and ":set tags=./../tags", filenames would
286: * contain "../" as many times as CTRL-] would be used. These are removed
287: * now.
288: * - Fixed: Extremely long error message could cause a crash (e.g., when
289: * using ":help ^A<CR>").
290: * - Added check for negative value of 'textwidth'.
291: * - Fixed: On MS-DOS, getting the value of $HOME would cause the current
292: * directory for the drive to be changed.
293: */
294:
295: /*
296: * Version[] is copied into the swap file (max. length is 10 chars).
297: * longVersion[] is used for the ":version" command and "Vim -h".
298: * Don't forget to update the numbers in version.h for Win32!!!
299: */
300:
1.2 ! downsj 301: #include "version.h"
! 302:
! 303: char *Version = "VIM 4.4";
1.1 downsj 304: #ifdef HAVE_DATE_TIME
1.2 ! downsj 305: char *longVersion = "VIM - Vi IMproved 4.4 BETA (1996 Sep 11, compiled " __DATE__ " " __TIME__ ")";
1.1 downsj 306: #else
1.2 ! downsj 307: char *longVersion = "VIM - Vi IMproved 4.4 BETA (1996 Sep 11)";
1.1 downsj 308: #endif
309:
310: static void version_msg __ARGS((char *s));
311:
312: void
313: do_version(arg)
314: char_u *arg;
315: {
316: long n;
317:
318: if (*arg != NUL)
319: {
320: found_version = getdigits(&arg) * 100;
321: if (*arg == '.' && isdigit(arg[1]))
322: {
323: /* "4.1" -> 401, "4.10" -> 410 */
324: n = arg[1] - '0';
325: if (isdigit(arg[2]))
326: found_version += (arg[2] - '0') + n * 10;
327: else
328: found_version += n;
329: }
1.2 ! downsj 330: if (found_version > VIM_VERSION_MAJOR * 100 + VIM_VERSION_MINOR)
1.1 downsj 331: {
332: MSG("Warning: Found newer version command");
333: if (sourcing_name != NULL)
334: {
335: MSG_OUTSTR(" in: \"");
336: msg_outstr(sourcing_name);
337: MSG_OUTSTR("\" line: ");
338: msg_outnum((long)sourcing_lnum);
339: }
340: }
341: }
342: else
343: {
344: msg_outchar('\n');
345: MSG(longVersion);
346: #ifdef WIN32
347: MSG_OUTSTR("\nWindows NT / Windows 95 version");
348: #endif
349: #ifdef MSDOS
350: # ifdef DJGPP
351: MSG_OUTSTR("\n32 bit MS-DOS version");
352: # else
353: MSG_OUTSTR("\n16 bit MS-DOS version");
354: # endif
355: #endif
356: MSG_OUTSTR("\nCompiled with (+) or without (-):\n");
357: #ifdef AMIGA /* only for Amiga systems */
358: # ifdef NO_ARP
359: version_msg("-ARP ");
360: # else
361: version_msg("+ARP ");
362: # endif
363: #endif
364: #ifdef AUTOCMD
365: version_msg("+autocmd ");
366: #else
367: version_msg("-autocmd ");
368: #endif
369: #ifdef NO_BUILTIN_TCAPS
370: version_msg("-builtin_terms ");
371: #endif
372: #ifdef SOME_BUILTIN_TCAPS
373: version_msg("+builtin_terms ");
374: #endif
375: #ifdef ALL_BUILTIN_TCAPS
376: version_msg("++builtin_terms ");
377: #endif
378: #ifdef CINDENT
379: version_msg("+cindent ");
380: #else
381: version_msg("-cindent ");
382: #endif
383: #ifdef COMPATIBLE
384: version_msg("+compatible ");
385: #else
386: version_msg("-compatible ");
387: #endif
388: #ifdef DEBUG
389: version_msg("+debug ");
390: #endif
391: #ifdef DIGRAPHS
392: version_msg("+digraphs ");
393: #else
394: version_msg("-digraphs ");
395: #endif
396: #ifdef EMACS_TAGS
397: version_msg("+emacs_tags ");
398: #else
399: version_msg("-emacs_tags ");
400: #endif
401: /* only interesting on Unix systems */
402: #if !defined(USE_SYSTEM) && defined(UNIX)
403: version_msg("+fork() ");
404: #endif
405: #ifdef UNIX
406: # ifdef USE_GUI_MOTIF
407: version_msg("+GUI_Motif ");
408: # else
409: # ifdef USE_GUI_ATHENA
410: version_msg("+GUI_Athena ");
411: # else
412: version_msg("-GUI ");
413: # endif
414: # endif
415: #endif
416: #ifdef INSERT_EXPAND
417: version_msg("+insert_expand ");
418: #else
419: version_msg("-insert_expand ");
420: #endif
421: #ifdef HAVE_LANGMAP
422: version_msg("+langmap ");
423: #else
424: version_msg("-langmap ");
425: #endif
426: #ifdef LISPINDENT
427: version_msg("+lispindent ");
428: #else
429: version_msg("-lispindent ");
430: #endif
431: #ifdef RIGHTLEFT
432: version_msg("+rightleft ");
433: #else
434: version_msg("-rightleft ");
435: #endif
436: #ifdef SMARTINDENT
437: version_msg("+smartindent ");
438: #else
439: version_msg("-smartindent ");
440: #endif
441: /* only interesting on Unix systems */
442: #if defined(USE_SYSTEM) && (defined(UNIX) || defined(__EMX__))
443: version_msg("+system() ");
444: #endif
445: #if defined(UNIX) || defined(__EMX__)
446: /* only unix (or OS/2 with EMX!) can have terminfo instead of termcap */
447: # ifdef TERMINFO
448: version_msg("+terminfo ");
449: # else
450: version_msg("-terminfo ");
451: # endif
452: #else /* unix always includes termcap support */
453: # ifdef HAVE_TGETENT
454: version_msg("+tgetent ");
455: # else
456: version_msg("-tgetent ");
457: # endif
458: #endif
459: #ifdef VIMINFO
460: version_msg("+viminfo ");
461: #else
462: version_msg("-viminfo ");
463: #endif
464: #ifdef WRITEBACKUP
465: version_msg("+writebackup ");
466: #else
467: version_msg("-writebackup ");
468: #endif
469: #ifdef UNIX
470: # if defined(WANT_X11) && defined(HAVE_X11)
471: version_msg("+X11 ");
472: # else
473: version_msg("-X11 ");
474: # endif
475: #endif
476: msg_outchar('\n');
477: #ifdef USR_VIMRC_FILE
478: version_msg("user vimrc file: \"");
479: version_msg(USR_VIMRC_FILE);
480: version_msg("\" ");
481: #endif
482: #ifdef USR_EXRC_FILE
483: version_msg("user exrc file: \"");
484: version_msg(USR_EXRC_FILE);
485: version_msg("\" ");
486: #endif
487: #ifdef USE_GUI
488: version_msg("user gvimrc file: \"");
489: version_msg(USR_GVIMRC_FILE);
490: version_msg("\" ");
491: #endif
492: #if defined(HAVE_CONFIG_H) || defined(OS2)
493: msg_outchar('\n');
494: version_msg("system vimrc file: \"");
495: version_msg((char *)sys_vimrc_fname);
496: version_msg("\"");
497: msg_outchar('\n');
498: version_msg("system compatrc file: \"");
499: version_msg((char *)sys_compatrc_fname);
500: version_msg("\"");
501: # ifdef USE_GUI
502: msg_outchar('\n');
503: version_msg("system gvimrc file: \"");
504: version_msg((char *)sys_gvimrc_fname);
505: MSG_OUTSTR("\"");
506: # endif
507: msg_outchar('\n');
508: version_msg("Compilation: ");
509: version_msg((char *)all_cflags);
510: #endif
511: }
512: }
513:
514: /*
515: * Output a string for the version message. If it's going to wrap, output a
516: * newline, unless the message is too long to fit on the screen anyway.
517: */
518: static void
519: version_msg(s)
520: char *s;
521: {
522: int len = strlen(s);
523:
524: if (len < (int)Columns && msg_col + len >= (int)Columns)
525: msg_outchar('\n');
526: MSG_OUTSTR(s);
527: }