diff --git a/runtime/colors/habamax.vim b/runtime/colors/habamax.vim index ff8a80be99c65..b709eb8f024fb 100644 --- a/runtime/colors/habamax.vim +++ b/runtime/colors/habamax.vim @@ -4,7 +4,7 @@ " Maintainer: Maxim Kim " Website: https://github.com/vim/colorschemes " License: Same as Vim -" Last Updated: Tue 30 Jul 2024 11:07:38 AM AEST +" Last Updated: 2024 Aug 02 " Generated by Colortemplate v2.2.3 @@ -22,7 +22,6 @@ hi! link Terminal Normal hi! link StatuslineTerm Statusline hi! link StatuslineTermNC StatuslineNC hi! link MessageWindow Pmenu -hi! link PopupNotification Todo hi! link javaScriptFunction Statement hi! link javaScriptIdentifier Statement hi! link sqlKeyword Statement @@ -73,7 +72,7 @@ hi ModeMsg guifg=NONE guibg=NONE gui=bold ctermfg=NONE ctermbg=NONE cterm=bold hi MoreMsg guifg=#5faf5f guibg=NONE gui=NONE cterm=NONE hi Question guifg=#d7af87 guibg=NONE gui=NONE cterm=NONE hi WarningMsg guifg=#d75f87 guibg=NONE gui=NONE cterm=NONE -hi Todo guifg=#d787d7 guibg=#1c1c1c gui=reverse cterm=reverse +hi Todo guifg=#dadada guibg=NONE gui=bold cterm=bold hi MatchParen guifg=#ff00af guibg=NONE gui=bold cterm=bold hi Search guifg=#5fafd7 guibg=#1c1c1c gui=reverse cterm=reverse hi IncSearch guifg=#ffaf5f guibg=#1c1c1c gui=reverse cterm=reverse @@ -119,7 +118,6 @@ if s:t_Co >= 256 hi! link StatuslineTerm Statusline hi! link StatuslineTermNC StatuslineNC hi! link MessageWindow Pmenu - hi! link PopupNotification Todo hi! link javaScriptFunction Statement hi! link javaScriptIdentifier Statement hi! link sqlKeyword Statement @@ -170,7 +168,7 @@ if s:t_Co >= 256 hi MoreMsg ctermfg=71 ctermbg=NONE cterm=NONE hi Question ctermfg=180 ctermbg=NONE cterm=NONE hi WarningMsg ctermfg=168 ctermbg=NONE cterm=NONE - hi Todo ctermfg=176 ctermbg=234 cterm=reverse + hi Todo ctermfg=253 ctermbg=NONE cterm=bold hi MatchParen ctermfg=199 ctermbg=NONE cterm=bold hi Search ctermfg=74 ctermbg=234 cterm=reverse hi IncSearch ctermfg=215 ctermbg=234 cterm=reverse @@ -248,7 +246,7 @@ if s:t_Co >= 16 hi MoreMsg ctermfg=darkgreen ctermbg=NONE cterm=NONE hi Question ctermfg=yellow ctermbg=NONE cterm=NONE hi WarningMsg ctermfg=red ctermbg=NONE cterm=NONE - hi Todo ctermfg=magenta ctermbg=black cterm=reverse + hi Todo ctermfg=white ctermbg=NONE cterm=bold hi MatchParen ctermfg=magenta ctermbg=NONE cterm=bold hi Search ctermfg=blue ctermbg=black cterm=reverse hi IncSearch ctermfg=red ctermbg=black cterm=reverse @@ -326,7 +324,7 @@ if s:t_Co >= 8 hi MoreMsg ctermfg=darkgreen ctermbg=NONE cterm=NONE hi Question ctermfg=darkyellow ctermbg=NONE cterm=NONE hi WarningMsg ctermfg=darkred ctermbg=NONE cterm=NONE - hi Todo ctermfg=darkmagenta ctermbg=black cterm=reverse + hi Todo ctermfg=gray ctermbg=NONE cterm=bold hi MatchParen ctermfg=magenta ctermbg=NONE cterm=bold hi Search ctermfg=black ctermbg=darkblue cterm=NONE hi IncSearch ctermfg=black ctermbg=darkyellow cterm=NONE diff --git a/runtime/doc/starting.txt b/runtime/doc/starting.txt index ebd60febcf194..cdc0f16a9b321 100644 --- a/runtime/doc/starting.txt +++ b/runtime/doc/starting.txt @@ -1,4 +1,4 @@ -*starting.txt* For Vim version 9.1. Last change: 2024 Jul 08 +*starting.txt* For Vim version 9.1. Last change: 2024 Aug 03 VIM REFERENCE MANUAL by Bram Moolenaar @@ -540,6 +540,7 @@ a slash. Thus "-R" means recovery and "-/R" readonly. not needed when reading a file, because there is a check if the file that is being read has been encrypted, and Vim asks for a key automatically. |encryption| + {only available when compiled with the |+cryptv| feature} *-X* -X Do not try connecting to the X server to get the current diff --git a/runtime/doc/syntax.txt b/runtime/doc/syntax.txt index a93db65c3af0c..59638a23b2707 100644 --- a/runtime/doc/syntax.txt +++ b/runtime/doc/syntax.txt @@ -1,4 +1,4 @@ -*syntax.txt* For Vim version 9.1. Last change: 2024 Jul 31 +*syntax.txt* For Vim version 9.1. Last change: 2024 Aug 03 VIM REFERENCE MANUAL by Bram Moolenaar @@ -5143,7 +5143,7 @@ matches, nextgroup, etc. But there are a few differences: line (or group of continued lines). - When a match with a sync pattern is found, the rest of the line (or group of continued lines) is searched for another match. The last match is used. - This is used when a line can contain both the start end the end of a region + This is used when a line can contain both the start and the end of a region (e.g., in a C-comment like /* this */, the last "*/" is used). There are two ways how a match with a sync pattern can be used: diff --git a/runtime/doc/vim.1 b/runtime/doc/vim.1 index a180a6222e165..88dd32f69c222 100644 --- a/runtime/doc/vim.1 +++ b/runtime/doc/vim.1 @@ -1,4 +1,4 @@ -.TH VIM 1 "2024 Jun 04" +.TH VIM 1 "2024 Aug 03" .SH NAME vim \- Vi IMproved, a programmer's text editor .SH SYNOPSIS @@ -433,7 +433,10 @@ If the {scriptout} file exists, characters are appended. Like \-w, but an existing file is overwritten. .TP \-x -Use encryption when writing files. Will prompt for a crypt key. +If +.B Vim +has been compiled with encryption support, use encryption when writing files. +Will prompt for a crypt key. .TP \-X Don't connect to the X server. Shortens startup time in a terminal, but the diff --git a/runtime/doc/vim.man b/runtime/doc/vim.man index 4ce444ec78781..340d0eca4c8bb 100644 --- a/runtime/doc/vim.man +++ b/runtime/doc/vim.man @@ -1,7 +1,5 @@ VIM(1) General Commands Manual VIM(1) - - NAME vim - Vi IMproved, a programmer's text editor @@ -38,11 +36,11 @@ DESCRIPTION vim [options] [filelist] If the filelist is missing, the editor will start with an empty buffer. - Otherwise exactly one out of the following four may be used to choose + Otherwise exactly one out of the following four may be used to choose one or more files to be edited. - file .. A list of filenames. The first one will be the current - file and read into the buffer. The cursor will be posi‐ + file .. A list of filenames. The first one will be the current + file and read into the buffer. The cursor will be posi‐ tioned on the first line of the buffer. You can get to the other files with the ":next" command. To edit a file that starts with a dash, precede the filelist with "--". @@ -51,18 +49,18 @@ DESCRIPTION from stderr, which should be a tty. -t {tag} The file to edit and the initial cursor position depends on - a "tag", a sort of goto label. {tag} is looked up in the + a "tag", a sort of goto label. {tag} is looked up in the tags file, the associated file becomes the current file and the associated command is executed. Mostly this is used for C programs, in which case {tag} could be a function name. The effect is that the file containing that function - becomes the current file and the cursor is positioned on + becomes the current file and the cursor is positioned on the start of the function. See ":help tag-commands". -q [errorfile] - Start in quickFix mode. The file [errorfile] is read and - the first error is displayed. If [errorfile] is omitted, - the filename is obtained from the 'errorfile' option (de‐ + Start in quickFix mode. The file [errorfile] is read and + the first error is displayed. If [errorfile] is omitted, + the filename is obtained from the 'errorfile' option (de‐ faults to "AztecC.Err" for the Amiga, "errors.err" on other systems). Further errors can be jumped to with the ":cn" command. See ":help quickfix". @@ -72,10 +70,10 @@ DESCRIPTION vim The "normal" way, everything is default. - ex Start in Ex mode. Go to Normal mode with the ":vi" command. + ex Start in Ex mode. Go to Normal mode with the ":vi" command. Can also be done with the "-e" argument. - view Start in read-only mode. You will be protected from writing + view Start in read-only mode. You will be protected from writing the files. Can also be done with the "-R" argument. gvim gview @@ -119,20 +117,20 @@ OPTIONS (only works when -S is the last argument). --cmd {command} - Like using "-c", but the command is executed just before - processing any vimrc file. You can use up to 10 of these + Like using "-c", but the command is executed just before + processing any vimrc file. You can use up to 10 of these commands, independently from "-c" commands. - -A If Vim has been compiled with ARABIC support for editing - right-to-left oriented files and Arabic keyboard mapping, - this option starts Vim in Arabic mode, i.e. 'arabic' is + -A If Vim has been compiled with ARABIC support for editing + right-to-left oriented files and Arabic keyboard mapping, + this option starts Vim in Arabic mode, i.e. 'arabic' is set. Otherwise an error message is given and Vim aborts. - -b Binary mode. A few options will be set that makes it pos‐ + -b Binary mode. A few options will be set that makes it pos‐ sible to edit a binary or executable file. - -C Compatible. Set the 'compatible' option. This will make - Vim behave mostly like Vi, even though a .vimrc file ex‐ + -C Compatible. Set the 'compatible' option. This will make + Vim behave mostly like Vi, even though a .vimrc file ex‐ ists. -d Start in diff mode. There should between two to eight file @@ -162,13 +160,13 @@ OPTIONS --nofork Foreground. For the GUI version, Vim will not fork and de‐ tach from the shell it was started in. - -F If Vim has been compiled with FKMAP support for editing - right-to-left oriented files and Farsi keyboard mapping, - this option starts Vim in Farsi mode, i.e. 'fkmap' and - 'rightleft' are set. Otherwise an error message is given + -F If Vim has been compiled with FKMAP support for editing + right-to-left oriented files and Farsi keyboard mapping, + this option starts Vim in Farsi mode, i.e. 'fkmap' and + 'rightleft' are set. Otherwise an error message is given and Vim aborts. - -g If Vim has been compiled with GUI support, this option en‐ + -g If Vim has been compiled with GUI support, this option en‐ ables the GUI. If no GUI support was compiled in, an error message is given and Vim aborts. @@ -230,9 +228,9 @@ OPTIONS each file. -P {parent-title} - Win32 GUI only: Specify the title of the parent applica‐ - tion. When possible, Vim will run in an MDI window inside - the application. {parent-title} must appear in the window + Win32 GUI only: Specify the title of the parent applica‐ + tion. When possible, Vim will run in an MDI window inside + the application. {parent-title} must appear in the window title of the parent application. Make sure that it is spe‐ cific enough. Note that the implementation is still primi‐ tive. It won't work with all applications and the menu @@ -254,12 +252,12 @@ OPTIONS filename as the text file with ".swp" appended. See ":help recovery". - -s Silent mode. Only when started as "Ex" or when the "-e" + -s Silent mode. Only when started as "Ex" or when the "-e" option was given before the "-s" option. -s {scriptin} - The script file {scriptin} is read. The characters in the - file are interpreted as if you had typed them. The same + The script file {scriptin} is read. The characters in the + file are interpreted as if you had typed them. The same can be done with the command ":source! {scriptin}". If the end of the file is reached before the editor exits, further characters are read from the keyboard. @@ -296,12 +294,12 @@ OPTIONS -V[N]{filename} Like -V and set 'verbosefile' to {filename}. The result is - that messages are not displayed but written to the file + that messages are not displayed but written to the file {filename}. {filename} must not start with a digit. --log {filename} - If Vim has been compiled with eval and channel feature, - start logging and write entries to {filename}. This works + If Vim has been compiled with eval and channel feature, + start logging and write entries to {filename}. This works like calling ch_logfile({filename}, 'ao') very early during startup. @@ -321,11 +319,11 @@ OPTIONS -W {scriptout} Like -w, but an existing file is overwritten. - -x Use encryption when writing files. Will prompt for a crypt - key. + -x If Vim has been compiled with encryption support, use en‐ + cryption when writing files. Will prompt for a crypt key. - -X Don't connect to the X server. Shortens startup time in a - terminal, but the window title and clipboard will not be + -X Don't connect to the X server. Shortens startup time in a + terminal, but the window title and clipboard will not be used. -y Start Vim in easy mode, just like the executable was called @@ -378,7 +376,7 @@ OPTIONS List the names of all Vim servers that can be found. --servername {name} - Use {name} as the server name. Used for the current Vim, + Use {name} as the server name. Used for the current Vim, unless used with a --remote argument, then it's the name of the server to connect to. @@ -405,12 +403,12 @@ ON-LINE HELP FILES /usr/local/share/vim/vim??/doc/*.txt - The Vim documentation files. Use ":help doc-file-list" + The Vim documentation files. Use ":help doc-file-list" to get the complete list. vim?? is short version number, like vim91 for Vim 9.1 /usr/local/share/vim/vim??/doc/tags - The tags file used for finding information in the docu‐ + The tags file used for finding information in the docu‐ mentation files. /usr/local/share/vim/vim??/syntax/syntax.vim @@ -423,18 +421,18 @@ FILES System wide Vim initializations. ~/.vimrc, ~/.vim/vimrc, $XDG_CONFIG_HOME/vim/vimrc - Your personal Vim initializations (first one found is + Your personal Vim initializations (first one found is used). /usr/local/share/vim/gvimrc System wide gvim initializations. ~/.gvimrc, ~/.vim/gvimrc, $XDG_CONFIG_HOME/vim/gvimrc - Your personal gvim initializations (first one found is + Your personal gvim initializations (first one found is used). /usr/local/share/vim/vim??/optwin.vim - Script used for the ":options" command, a nice way to + Script used for the ":options" command, a nice way to view and set options. /usr/local/share/vim/vim??/menu.vim @@ -444,11 +442,11 @@ FILES Script to generate a bug report. See ":help bugs". /usr/local/share/vim/vim??/filetype.vim - Script to detect the type of a file by its name. See + Script to detect the type of a file by its name. See ":help 'filetype'". /usr/local/share/vim/vim??/scripts.vim - Script to detect the type of a file by its contents. + Script to detect the type of a file by its contents. See ":help 'filetype'". /usr/local/share/vim/vim??/print/*.ps @@ -476,6 +474,4 @@ BUGS vi_diff.txt when in Vim). Also have a look at the 'compatible' and 'cpoptions' options. - - - 2024 Jun 04 VIM(1) + 2024 Aug 03 VIM(1) diff --git a/src/GvimExt/Make_mvc.mak b/src/GvimExt/Make_mvc.mak index 7068d8f70e3dd..132a584ba426a 100644 --- a/src/GvimExt/Make_mvc.mak +++ b/src/GvimExt/Make_mvc.mak @@ -19,25 +19,24 @@ WINVER = 0x0601 NODEBUG = 1 !endif -!ifdef PROCESSOR_ARCHITECTURE -# On Windows NT -! ifndef CPU +!ifndef CPU CPU = i386 -! if !defined(PLATFORM) && defined(TARGET_CPU) +! ifndef PLATFORM +! ifdef TARGET_CPU PLATFORM = $(TARGET_CPU) +! elseif defined(VSCMD_ARG_TGT_ARCH) +PLATFORM = $(VSCMD_ARG_TGT_ARCH) ! endif -! ifdef PLATFORM -! if ("$(PLATFORM)" == "x64") || ("$(PLATFORM)" == "X64") +! endif +! ifdef PLATFORM +! if ("$(PLATFORM)" == "x64") || ("$(PLATFORM)" == "X64") CPU = AMD64 -! elseif ("$(PLATFORM)" == "arm64") || ("$(PLATFORM)" == "ARM64") +! elseif ("$(PLATFORM)" == "arm64") || ("$(PLATFORM)" == "ARM64") CPU = ARM64 -! elseif ("$(PLATFORM)" != "x86") && ("$(PLATFORM)" != "X86") -! error *** ERROR Unknown target platform "$(PLATFORM)". Make aborted. -! endif +! elseif ("$(PLATFORM)" != "x86") && ("$(PLATFORM)" != "X86") +! error *** ERROR Unknown target platform "$(PLATFORM)". Make aborted. ! endif ! endif -!else -CPU = i386 !endif !ifdef SDK_INCLUDE_DIR @@ -80,7 +79,6 @@ all: gvimext.dll gvimext.dll: gvimext.obj \ gvimext.res $(link) $(lflags) -dll -def:gvimext.def -base:$(OFFSET) -out:$*.dll $** $(olelibsdll) shell32.lib comctl32.lib -subsystem:$(SUBSYSTEM) - if exist $*.dll.manifest mt -nologo -manifest $*.dll.manifest -outputresource:$*.dll;2 gvimext.obj: gvimext.h @@ -96,4 +94,3 @@ clean: - if exist gvimext.exp del gvimext.exp - if exist gvimext.obj del gvimext.obj - if exist gvimext.res del gvimext.res - - if exist gvimext.dll.manifest del gvimext.dll.manifest diff --git a/src/Make_mvc.mak b/src/Make_mvc.mak index 64f5149d80660..611bc8f5f4bee 100644 --- a/src/Make_mvc.mak +++ b/src/Make_mvc.mak @@ -127,10 +127,15 @@ # # Optimization: OPTIMIZE=[SPACE, SPEED, MAXSPEED] (default is MAXSPEED) # -# Processor Version: CPUNR=[any, i686, sse, sse2, avx, avx2] (default is -# sse2) +# Processor Version: +# For x86: CPUNR=[any, i686, sse, sse2, avx, avx2, avx512] +# For x64: CPUNR=[sse2, avx, avx2, avx512] +# (default is sse2 (both x86 and x64)) # avx is available on Visual C++ 2010 and after. # avx2 is available on Visual C++ 2013 Update 2 and after. +# avx512 is available on Visual C++ 2017 and after. +# For ARM64: +# See: https://learn.microsoft.com/en-us/cpp/build/reference/arch-arm64 # # Version Support: WINVER=[0x0601, 0x0602, 0x0603, 0x0A00] (default is # 0x0601) @@ -158,14 +163,14 @@ # nmake -f Make_mvc.mvc "DEFINES=-DEMACS_TAGS" RM = del /f /q -PS = powershell.exe -PSFLAGS = -NoLogo -NoProfile -Command +# Read MAJOR and MINOR from version.h. +!IF ![for /f "tokens=2,3" %I in (version.h) do \ + @if "%I"=="VIM_VERSION_MAJOR" ( echo MAJOR=%J>.\major.tmp ) \ + else if "%I"=="VIM_VERSION_MINOR" ( echo MINOR=%J>.\minor.tmp )] +!ENDIF -!IF ![$(PS) $(PSFLAGS) try{Out-File -FilePath '.\major.tmp' -InputObject \ - \"MAJOR=$$(((Select-String -Pattern 'VIM_VERSION_MAJOR\s+\d{1,2}' \ - -Path '.\version.h').Line[-2..-1^]-join '').Trim())\"} \ - catch{exit 1}] +!IF EXIST(.\major.tmp) ! INCLUDE .\major.tmp ! IF [$(RM) .\major.tmp] ! ENDIF @@ -174,10 +179,7 @@ PSFLAGS = -NoLogo -NoProfile -Command MAJOR = 9 !ENDIF -!IF ![$(PS) $(PSFLAGS) try{Out-File -FilePath '.\minor.tmp' -InputObject \ - \"MINOR=$$(((Select-String -Pattern 'VIM_VERSION_MINOR\s+\d{1,2}' \ - -Path '.\version.h').Line[-2..-1^]-join '').Trim())\"} \ - catch{exit 1}] +!IF EXIST(.\minor.tmp) ! INCLUDE .\minor.tmp ! IF [$(RM) .\minor.tmp] ! ENDIF @@ -186,24 +188,23 @@ MAJOR = 9 MINOR = 1 !ENDIF -!IF ![$(PS) $(PSFLAGS) try{Out-File -FilePath '.\patchlvl.tmp' -InputObject \ - \"PATCHLEVEL=$$([decimal^]((Get-Content -Path '.\version.c' \ - -TotalCount ((Select-String -Pattern 'static int included_patches' \ - -Path '.\version.c').LineNumber+3))[-1^]).Trim().TrimEnd(','))\"} \ - catch{exit 1}] +# Read PATCHLEVEL from version.c. +!IF ![cmd.exe /V:ON /C "echo off && set LINE=0&& set FIND=0&& \ + for /f "tokens=1,3 delims=,[ " %I in (version.c) do \ + ( set /A LINE+=1 > NUL && \ + if "%J"=="included_patches" ( set /A FIND=LINE+3 > NUL ) \ + else if "!LINE!"=="!FIND!" ( echo PATCHLEVEL=%I>.\patchlvl.tmp && exit ) )"] +!ENDIF +!IF EXIST(.\patchlvl.tmp) ! INCLUDE .\patchlvl.tmp ! IF [$(RM) .\patchlvl.tmp] ! ENDIF !ENDIF - -# Build on Windows NT/XP - -TARGETOS = WINNT - !IFDEF PATCHLEVEL RCFLAGS = -DVIM_VERSION_PATCHLEVEL=$(PATCHLEVEL) !ENDIF +!message Vim version: $(MAJOR).$(MINOR).$(PATCHLEVEL) !if "$(VIMDLL)" == "yes" @@ -257,38 +258,29 @@ OBJDIR = $(OBJDIR)V OBJDIR = $(OBJDIR)d !endif -!ifdef PROCESSOR_ARCHITECTURE -# We're on Windows NT or using VC 6+ -! ifdef CPU -ASSEMBLY_ARCHITECTURE = $(CPU) -# Using I386 for $ASSEMBLY_ARCHITECTURE doesn't work for VC7. -! if "$(CPU)" == "I386" +!ifdef CPU +! if "$(CPU)" == "I386" CPU = i386 -! endif -! else # !CPU +! endif +!else # !CPU CPU = i386 -! ifndef PLATFORM -! ifdef TARGET_CPU +! ifndef PLATFORM +! ifdef TARGET_CPU PLATFORM = $(TARGET_CPU) -! elseif defined(VSCMD_ARG_TGT_ARCH) +! elseif defined(VSCMD_ARG_TGT_ARCH) PLATFORM = $(VSCMD_ARG_TGT_ARCH) -! endif ! endif -! ifdef PLATFORM -! if ("$(PLATFORM)" == "x64") || ("$(PLATFORM)" == "X64") +! endif +! ifdef PLATFORM +! if ("$(PLATFORM)" == "x64") || ("$(PLATFORM)" == "X64") CPU = AMD64 -! elseif ("$(PLATFORM)" == "arm64") || ("$(PLATFORM)" == "ARM64") +! elseif ("$(PLATFORM)" == "arm64") || ("$(PLATFORM)" == "ARM64") CPU = ARM64 -! elseif ("$(PLATFORM)" != "x86") && ("$(PLATFORM)" != "X86") -! error *** ERROR Unknown target platform "$(PLATFORM)". Make aborted. -! endif -! endif # !PLATFORM -! endif -!else # !PROCESSOR_ARCHITECTURE -# We're on Windows 95 -CPU = i386 -!endif # !PROCESSOR_ARCHITECTURE -ASSEMBLY_ARCHITECTURE = $(CPU) +! elseif ("$(PLATFORM)" != "x86") && ("$(PLATFORM)" != "X86") +! error *** ERROR Unknown target platform "$(PLATFORM)". Make aborted. +! endif +! endif # !PLATFORM +!endif OBJDIR = $(OBJDIR)$(CPU) # Build a retail version by default @@ -303,7 +295,9 @@ MAKEFLAGS_GVIMEXT = DEBUG=yes LINK = link # Check VC version. -!if [echo MSVCVER=_MSC_VER> msvcver.c && $(CC) /EP msvcver.c > msvcver.~ 2> nul] +!if [echo MSVCVER=_MSC_VER> msvcver.c && \ + echo MSVC_FULL=_MSC_FULL_VER>> msvcver.c && \ + $(CC) /EP msvcver.c > msvcver.~ 2> nul] ! message *** ERROR ! message Cannot run Visual C to determine its version. Make sure cl.exe is in your PATH. ! message This can usually be done by running "vcvarsall.bat", located in the bin directory where Visual Studio was installed. @@ -324,19 +318,6 @@ LINK = link MSVC_MAJOR = ($(MSVCVER) / 100 - 5) MSVCRT_VER = ($(MSVCVER) / 100 * 10 - 50) -# Calculate MSVC_FULL. -!if [echo MSVC_FULL=_MSC_FULL_VER> msvcfullver.c && $(CC) /EP msvcfullver.c > msvcfullver.~ 2> nul] -! message *** ERROR -! message Cannot run Visual C to determine its version. Make sure cl.exe is in your PATH. -! message This can usually be done by running "vcvarsall.bat", located in the bin directory where Visual Studio was installed. -! error Make aborted. -!else -! include msvcfullver.~ -! if [del msvcfullver.c msvcfullver.~] -! endif -!endif - - # Calculate MSVCRT_VER !if [(set /a MSVCRT_VER="$(MSVCRT_VER)" > nul) && set MSVCRT_VER > msvcrtver.~] == 0 ! include msvcrtver.~ @@ -344,6 +325,11 @@ MSVCRT_VER = ($(MSVCVER) / 100 * 10 - 50) ! endif !endif +# Show the versions (for debugging). +#!message _MSC_VER=$(MSVCVER) +#!message _MSC_FULL_VER=$(MSVC_FULL) +#!message MSVCRT_VER=$(MSVCRT_VER) + # Base name of the msvcrXX.dll (vcruntimeXXX.dll) MSVCRT_NAME = vcruntime$(MSVCRT_VER) @@ -553,40 +539,53 @@ INTDIR = $(OBJDIR) OUTDIR = $(OBJDIR) ### Validate CPUNR -!ifndef CPUNR +!if "$(CPU)" == "i386" || "$(CPU)" == "AMD64" +! ifndef CPUNR # default to SSE2 CPUNR = sse2 -!elseif "$(CPUNR)" == "i386" || "$(CPUNR)" == "i486" || "$(CPUNR)" == "i586" +! elseif "$(CPU)" == "i386" \ + && ("$(CPUNR)" == "i386" || "$(CPUNR)" == "i486" || "$(CPUNR)" == "i586") # alias i386, i486 and i586 to i686 -! message *** WARNING CPUNR=$(CPUNR) is not a valid target architecture. -! message Windows 7 is the minimum target OS, with a minimum target -! message architecture of i686. -! message Retargeting to i686 +! message *** WARNING CPUNR=$(CPUNR) is not a valid target architecture. +! message Windows 7 is the minimum target OS, with a minimum target +! message architecture of i686. +! message Retargeting to i686 CPUNR = i686 -!elseif "$(CPUNR)" == "pentium4" +! elseif "$(CPUNR)" == "pentium4" # alias pentium4 to sse2 -! message *** WARNING CPUNR=pentium4 is deprecated in favour of sse2. -! message Retargeting to sse2. +! message *** WARNING CPUNR=pentium4 is deprecated in favour of sse2. +! message Retargeting to sse2. CPUNR = sse2 -!elseif "$(CPUNR)" != "any" && "$(CPUNR)" != "i686" \ - && "$(CPUNR)" != "sse" && "$(CPUNR)" != "sse2" \ - && "$(CPUNR)" != "avx" && "$(CPUNR)" != "avx2" -! error *** ERROR Unknown target architecture "$(CPUNR)". Make aborted. +! elseif ("$(CPU)" != "i386" \ + || ("$(CPUNR)" != "any" && "$(CPUNR)" != "i686" \ + && "$(CPUNR)" != "sse" )) \ + && "$(CPUNR)" != "sse2" && "$(CPUNR)" != "avx" \ + && "$(CPUNR)" != "avx2" && "$(CPUNR)" != "avx512" +! error *** ERROR Unknown target architecture "$(CPUNR)". Make aborted. +! endif +!elseif "$(CPU)" == "ARM64" +# TODO: Validate CPUNR. !endif # Convert processor ID to MVC-compatible number +!if "$(CPU)" == "i386" || "$(CPU)" == "AMD64" # IA32/SSE/SSE2 are only supported on x86 -!if "$(ASSEMBLY_ARCHITECTURE)" == "i386" \ +! if "$(CPU)" == "i386" \ && ("$(CPUNR)" == "i686" || "$(CPUNR)" == "any") CPUARG = /arch:IA32 -!elseif "$(ASSEMBLY_ARCHITECTURE)" == "i386" && "$(CPUNR)" == "sse" +! elseif "$(CPU)" == "i386" && "$(CPUNR)" == "sse" CPUARG = /arch:SSE -!elseif "$(ASSEMBLY_ARCHITECTURE)" == "i386" && "$(CPUNR)" == "sse2" +! elseif "$(CPU)" == "i386" && "$(CPUNR)" == "sse2" CPUARG = /arch:SSE2 -!elseif "$(CPUNR)" == "avx" +! elseif "$(CPUNR)" == "avx" CPUARG = /arch:AVX -!elseif "$(CPUNR)" == "avx2" +! elseif "$(CPUNR)" == "avx2" CPUARG = /arch:AVX2 +! elseif "$(CPUNR)" == "avx512" +CPUARG = /arch:AVX512 +! endif +!elseif "$(CPU)" == "ARM64" && defined(CPUNR) +CPUARG = /arch:$(CPUNR) !endif # Pass CPUARG to GvimExt, to avoid using version-dependent defaults @@ -594,7 +593,7 @@ MAKEFLAGS_GVIMEXT = $(MAKEFLAGS_GVIMEXT) CPUARG="$(CPUARG)" !if "$(VIMDLL)" == "yes" VIMDLLBASE = vim -! if "$(ASSEMBLY_ARCHITECTURE)" == "i386" +! if "$(CPU)" == "i386" VIMDLLBASE = $(VIMDLLBASE)32 ! else VIMDLLBASE = $(VIMDLLBASE)64 diff --git a/src/help.c b/src/help.c index a792bf3cc3f6c..106236201188e 100644 --- a/src/help.c +++ b/src/help.c @@ -813,6 +813,8 @@ fix_help_buffer(void) f1 = fnames[i1]; t1 = gettail(f1); e1 = vim_strrchr(t1, '.'); + if (e1 == NULL) + continue; if (fnamecmp(e1, ".txt") != 0 && fnamecmp(e1, fname + 4) != 0) { @@ -828,6 +830,8 @@ fix_help_buffer(void) continue; t2 = gettail(f2); e2 = vim_strrchr(t2, '.'); + if (e2 == NULL) + continue; if (e1 - f1 != e2 - f2 || fnamencmp(f1, f2, e1 - f1) != 0) continue; diff --git a/src/version.c b/src/version.c index 2ffe50e289837..808b7d4b7a033 100644 --- a/src/version.c +++ b/src/version.c @@ -709,6 +709,12 @@ static char *(features[]) = static int included_patches[] = { /* Add new patch number below this line */ +/**/ + 658, +/**/ + 657, +/**/ + 656, /**/ 655, /**/