0
0
mirror of https://github.com/vim/vim.git synced 2025-09-01 21:03:39 -04:00

runtime(doc): Update doc Makefiles with comments from #13567 (#13577)

Signed-off-by: Christian Brabandt <cb@256bit.org>
This commit is contained in:
Restorer 2023-11-25 14:39:51 +00:00 committed by GitHub
parent 813a538bb3
commit 8c14e79737
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 74 additions and 39 deletions

View File

@ -10,20 +10,22 @@
# TODO: to think about what to use instead of awk. PowerShell? # TODO: to think about what to use instead of awk. PowerShell?
#AWK = #AWK =
# Correct the following line for the where executeable file vim is installed # Correct the following line for the where executeable file vim is installed.
# Please do not put the path in quotes.
VIMEXE = D:\Programs\Vim\vim90\vim.exe VIMEXE = D:\Programs\Vim\vim90\vim.exe
# Correct the following line for the directory where gettext et al is installed # Correct the following line for the directory where iconv installed.
GETTEXT_PATH = D:\Programs\GetText\bin # Please do not put the path in quotes.
ICONV_PATH = D:\Programs\GetText\bin
# In case some package like GnuWin32, UnixUtils # In case some package like GnuWin32, UnixUtils
# or something similar is installed on the system. # or something similar is installed on the system.
# If the "touch" program is installed on the system, but it is not registered # If the "touch" program is installed on the system, but it is not registered
# in the %PATH% environment variable, then specify the full path to this file. # in the %PATH% environment variable, then specify the full path to this file.
!IF EXIST ("touch.exe") !IF EXIST ("touch.exe")
TOUCH = touch.exe $@ TOUCH = "touch.exe" %1
!ELSE !ELSE
TOUCH = @if exist $@ ( copy /b $@+,, ) else ( type nul >$@ ) TOUCH = if exist %1 ( copy /b %1+,, ) else ( type nul >%1 )
!ENDIF !ENDIF
# In case some package like GnuWin32, UnixUtils, gettext # In case some package like GnuWin32, UnixUtils, gettext
@ -31,9 +33,9 @@ TOUCH = @if exist $@ ( copy /b $@+,, ) else ( type nul >$@ )
# If the "iconv" program is installed on the system, but it is not registered # If the "iconv" program is installed on the system, but it is not registered
# in the %PATH% environment variable, then specify the full path to this file. # in the %PATH% environment variable, then specify the full path to this file.
!IF EXIST ("iconv.exe") !IF EXIST ("iconv.exe")
ICONV = iconv.exe ICONV = "iconv.exe"
!ELSEIF EXIST ("$(GETTEXT_PATH)\iconv.exe") !ELSEIF EXIST ("$(ICONV_PATH)\iconv.exe")
ICONV="$(GETTEXT_PATH)\iconv.exe" ICONV = "$(ICONV_PATH)\iconv.exe"
!ENDIF !ENDIF
RM = del /q RM = del /q
@ -46,7 +48,7 @@ all : tags perlhtml $(CONVERTED)
# Use "doctags" to generate the tags file. Only works for English! # Use "doctags" to generate the tags file. Only works for English!
tags : doctags $(DOCS) tags : doctags $(DOCS)
doctags $(DOCS) | sort /L C /O tags doctags.exe $(DOCS) | sort /L C /O tags
powershell -nologo -noprofile -Command \ powershell -nologo -noprofile -Command \
"(Get-Content -Raw tags | Get-Unique | % {$$_ -replace \"`r\", \"\"}) \ "(Get-Content -Raw tags | Get-Unique | % {$$_ -replace \"`r\", \"\"}) \
| New-Item -Force -Path . -ItemType file -Name tags" | New-Item -Force -Path . -ItemType file -Name tags"
@ -58,15 +60,15 @@ doctags : doctags.c
# Use Vim to generate the tags file. Can only be used when Vim has been # Use Vim to generate the tags file. Can only be used when Vim has been
# compiled and installed. Supports multiple languages. # compiled and installed. Supports multiple languages.
vimtags : $(DOCS) vimtags : $(DOCS)
$(VIMEXE) --clean -esX -V1 -u doctags.vim @"$(VIMEXE)" --clean -esX -V1 -u doctags.vim
uganda.nsis.txt : uganda.* uganda.nsis.txt : uganda.???
!powershell -nologo -noprofile -Command \ !@powershell -nologo -noprofile -Command \
$$ext=(Get-Item $?).Extension; (Get-Content $? ^| \ $$ext=(Get-Item $?).Extension; (Get-Content $? ^| \
% {$$_ -replace '\s*\*[-a-zA-Z0-9.]*\*', '' -replace 'vim:tw=78:.*', ''}) \ % {$$_ -replace '\s*\*[-a-zA-Z0-9.]*\*', '' -replace 'vim:tw=78:.*', ''}) \
^| Set-Content $*$$ext ^| Set-Content $*$$ext
!powershell -nologo -noprofile -Command \ !@powershell -nologo -noprofile -Command \
$$ext=(Get-Item $?).Extension; \ $$ext=(Get-Item $?).Extension; \
(Get-Content -Raw $(@B)$$ext).Trim() -replace '(\r\n){3,}', '$$1$$1' \ (Get-Content -Raw $(@B)$$ext).Trim() -replace '(\r\n){3,}', '$$1$$1' \
^| Set-Content $(@B)$$ext ^| Set-Content $(@B)$$ext
@ -103,68 +105,102 @@ perlhtml : tags $(DOCS)
# Check URLs in the help with "curl" or "powershell". # Check URLs in the help with "curl" or "powershell".
test_urls : test_urls :
$(VIMEXE) -S test_urls.vim "$(VIMEXE)" -S test_urls.vim
clean : clean :
$(RM) doctags.exe doctags.obj $(RM) doctags.exe doctags.obj
$(RM) *.html vim-stylesheet.css $(RM) *.html vim-stylesheet.css
arabic.txt : arabic.txt :
$(TOUCH) <<touch.bat $@
@$(TOUCH)
<<
farsi.txt : farsi.txt :
$(TOUCH) <<touch.bat $@
@$(TOUCH)
<<
hebrew.txt : hebrew.txt :
$(TOUCH) <<touch.bat $@
@$(TOUCH)
<<
russian.txt : russian.txt :
$(TOUCH) <<touch.bat $@
@$(TOUCH)
<<
gui_w32.txt : gui_w32.txt :
$(TOUCH) <<touch.bat $@
@$(TOUCH)
<<
if_ole.txt : if_ole.txt :
$(TOUCH) <<touch.bat $@
@$(TOUCH)
<<
os_390.txt : os_390.txt :
$(TOUCH) <<touch.bat $@
@$(TOUCH)
<<
os_amiga.txt : os_amiga.txt :
$(TOUCH) <<touch.bat $@
@$(TOUCH)
<<
os_beos.txt : os_beos.txt :
$(TOUCH) <<touch.bat $@
@$(TOUCH)
<<
os_dos.txt : os_dos.txt :
$(TOUCH) <<touch.bat $@
@$(TOUCH)
<<
os_haiku.txt : os_haiku.txt :
$(TOUCH) <<touch.bat $@
@$(TOUCH)
<<
os_mac.txt : os_mac.txt :
$(TOUCH) <<touch.bat $@
@$(TOUCH)
<<
os_mint.txt : os_mint.txt :
$(TOUCH) <<touch.bat $@
@$(TOUCH)
<<
os_msdos.txt : os_msdos.txt :
$(TOUCH) <<touch.bat $@
@$(TOUCH)
<<
os_os2.txt : os_os2.txt :
$(TOUCH) <<touch.bat $@
@$(TOUCH)
<<
os_qnx.txt : os_qnx.txt :
$(TOUCH) <<touch.bat $@
@$(TOUCH)
<<
os_risc.txt : os_risc.txt :
$(TOUCH) <<touch.bat $@
@$(TOUCH)
<<
os_win32.txt : os_win32.txt :
$(TOUCH) <<touch.bat $@
@$(TOUCH)
<<
convert-all : $(CONVERTED) convert-all : $(CONVERTED)
!IF [powershell -nologo -noprofile "exit $$psversiontable.psversion.major"] == 2 !IF [powershell -nologo -noprofile "exit $$psversiontable.psversion.major"] == 2
@ -451,6 +487,4 @@ vimtutor-tr.UTF-8.1 : vimtutor-tr.1
1>nul New-Item -Force -Path . -ItemType file -Name $@ 1>nul New-Item -Force -Path . -ItemType file -Name $@
!ENDIF !ENDIF
# vim: set noet sw=8 ts=8 sts=0 wm=0 tw=0 ft=make: # vim: set noet sw=8 ts=8 sts=0 wm=0 tw=0 ft=make:

View File

@ -10,7 +10,8 @@
# Common components # Common components
!INCLUDE Make_all.mak !INCLUDE Make_all.mak
# Correct the following line for the directory where iconv is installed # Correct the following line for the directory where iconv is installed.
# Please do not put the path in quotes.
ICONV_PATH = D:\Programs\GetText\bin ICONV_PATH = D:\Programs\GetText\bin
# In case some package like GnuWin32, UnixUtils, gettext # In case some package like GnuWin32, UnixUtils, gettext
@ -18,9 +19,9 @@ ICONV_PATH = D:\Programs\GetText\bin
# If the "iconv" program is installed on the system, but it is not registered # If the "iconv" program is installed on the system, but it is not registered
# in the %PATH% environment variable, then specify the full path to this file. # in the %PATH% environment variable, then specify the full path to this file.
!IF EXIST ("iconv.exe") !IF EXIST ("iconv.exe")
ICONV = iconv.exe ICONV = "iconv.exe"
!ELSEIF EXIST ("$(ICONV_PATH)\iconv.exe") !ELSEIF EXIST ("$(ICONV_PATH)\iconv.exe")
ICONV="$(ICONV_PATH)\iconv.exe" ICONV = "$(ICONV_PATH)\iconv.exe"
!ENDIF !ENDIF
RM = del /q RM = del /q