Mercurial > vim
annotate src/po/Make_mvc.mak @ 34627:5071d4c3ff2e v9.1.0202
patch 9.1.0202: leaking memory in add_user() on failure
Commit: https://github.com/vim/vim/commit/7a2f217988afa1c35b9c093a9d3477198ea250b9
Author: Christian Brabandt <cb@256bit.org>
Date: Sun Mar 24 09:50:03 2024 +0100
patch 9.1.0202: leaking memory in add_user() on failure
Problem: leaking memory in add_user() (LuMingYinDetect)
Solution: free user_copy pointer instead of the user ptr
add_user() is called with a user pointer and the user pointer comes
from these functions:
- return value from the getpwent() function (Unix).
- return value from the getpwnam() function (Unix).
- return value from the NetUserEnum() function (MS Windows).
For the first 2 callers, the man page for those functions directly says,
one should not free the returned pointer (since it comes from static
memory).
For the third caller (on MS Windows), the returned buffer is already
freed directly after calling the add_user() function in
NetApiBufferFree(), so this would lead to a double free().
This all indicates, the user ptr is wrongly freed in the add_user()
function and the intention was to free the user_copy pointer instead in
case of an error.
So let's just use that now.
fixes: #14250
closes: #14260
Signed-off-by: Christian Brabandt <cb@256bit.org>
author | Christian Brabandt <cb@256bit.org> |
---|---|
date | Sun, 24 Mar 2024 10:00:09 +0100 |
parents | 748a8a413816 |
children | de4405462a2a |
rev | line source |
---|---|
32670
695b50472e85
Fix line endings issue
Christian Brabandt <cb@256bit.org>
parents:
32669
diff
changeset
|
1 # Makefile for the Vim message translations for MSVC |
695b50472e85
Fix line endings issue
Christian Brabandt <cb@256bit.org>
parents:
32669
diff
changeset
|
2 # (based on make_ming.mak) |
695b50472e85
Fix line endings issue
Christian Brabandt <cb@256bit.org>
parents:
32669
diff
changeset
|
3 # |
34178
c5a10c03afb8
patch 9.1.0044: po Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
33831
diff
changeset
|
4 # Mike Williams, <mrw@eandem.co.uk> |
c5a10c03afb8
patch 9.1.0044: po Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
33831
diff
changeset
|
5 # 06.01.24, Restorer, <restorer@mail2k.ru> |
32670
695b50472e85
Fix line endings issue
Christian Brabandt <cb@256bit.org>
parents:
32669
diff
changeset
|
6 # |
695b50472e85
Fix line endings issue
Christian Brabandt <cb@256bit.org>
parents:
32669
diff
changeset
|
7 # Please read README_mvc.txt before using this file. |
695b50472e85
Fix line endings issue
Christian Brabandt <cb@256bit.org>
parents:
32669
diff
changeset
|
8 # |
695b50472e85
Fix line endings issue
Christian Brabandt <cb@256bit.org>
parents:
32669
diff
changeset
|
9 |
34178
c5a10c03afb8
patch 9.1.0044: po Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
33831
diff
changeset
|
10 !IF [powershell.exe -nologo -noprofile "exit $$psversiontable.psversion.major"] == 2 |
33823
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
11 !ERROR The program "PowerShell" version 3.0 or higher is required to work |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
12 !ENDIF |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
13 |
34178
c5a10c03afb8
patch 9.1.0044: po Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
33831
diff
changeset
|
14 !IFNDEF LANGUAGE |
34543
748a8a413816
patch 9.1.0173: msgfmt ver. 0.22 forcibly converts text to UTF-8
Christian Brabandt <cb@256bit.org>
parents:
34178
diff
changeset
|
15 ! IF [powershell.exe -nologo -noprofile $$lng=(Get-UICulture).TwoLetterISOLanguageName; \ |
748a8a413816
patch 9.1.0173: msgfmt ver. 0.22 forcibly converts text to UTF-8
Christian Brabandt <cb@256bit.org>
parents:
34178
diff
changeset
|
16 $$Env:LANGUAGE=$$lng;Set-Content -Path .\lng.tmp -Value "LANGUAGE=$$lng"] |
34178
c5a10c03afb8
patch 9.1.0044: po Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
33831
diff
changeset
|
17 ! ENDIF |
c5a10c03afb8
patch 9.1.0044: po Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
33831
diff
changeset
|
18 # In order for the "install" and "cleanup-po" rule to work. |
c5a10c03afb8
patch 9.1.0044: po Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
33831
diff
changeset
|
19 # The others work with just setting the environment variable. |
c5a10c03afb8
patch 9.1.0044: po Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
33831
diff
changeset
|
20 # And to show in the message. |
c5a10c03afb8
patch 9.1.0044: po Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
33831
diff
changeset
|
21 ! INCLUDE lng.tmp |
c5a10c03afb8
patch 9.1.0044: po Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
33831
diff
changeset
|
22 ! IF [del /q .\lng.tmp] |
c5a10c03afb8
patch 9.1.0044: po Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
33831
diff
changeset
|
23 ! ENDIF |
c5a10c03afb8
patch 9.1.0044: po Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
33831
diff
changeset
|
24 ! MESSAGE |
c5a10c03afb8
patch 9.1.0044: po Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
33831
diff
changeset
|
25 ! MESSAGE The %LANGUAGE% environment variable is not set. |
c5a10c03afb8
patch 9.1.0044: po Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
33831
diff
changeset
|
26 ! MESSAGE This variable will be temporarily set to "$(LANGUAGE)" while "nmake.exe" is running. |
c5a10c03afb8
patch 9.1.0044: po Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
33831
diff
changeset
|
27 ! MESSAGE See README_mvc.txt for more information on the %LANGUAGE% environment variable. |
c5a10c03afb8
patch 9.1.0044: po Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
33831
diff
changeset
|
28 ! MESSAGE |
c5a10c03afb8
patch 9.1.0044: po Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
33831
diff
changeset
|
29 !ELSE |
c5a10c03afb8
patch 9.1.0044: po Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
33831
diff
changeset
|
30 ! MESSAGE LANGUAGE is already set "$(LANGUAGE)" |
c5a10c03afb8
patch 9.1.0044: po Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
33831
diff
changeset
|
31 !ENDIF |
c5a10c03afb8
patch 9.1.0044: po Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
33831
diff
changeset
|
32 |
34543
748a8a413816
patch 9.1.0173: msgfmt ver. 0.22 forcibly converts text to UTF-8
Christian Brabandt <cb@256bit.org>
parents:
34178
diff
changeset
|
33 # Get LANGUAGES, MOFILES, MOCONVERTED and others. |
33823
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
34 !INCLUDE Make_all.mak |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
35 |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
36 !IFNDEF VIMRUNTIME |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
37 VIMRUNTIME = ..\..\runtime |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
38 !ENDIF |
32670
695b50472e85
Fix line endings issue
Christian Brabandt <cb@256bit.org>
parents:
32669
diff
changeset
|
39 |
695b50472e85
Fix line endings issue
Christian Brabandt <cb@256bit.org>
parents:
32669
diff
changeset
|
40 PACKAGE = vim |
34178
c5a10c03afb8
patch 9.1.0044: po Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
33831
diff
changeset
|
41 # Correct the following line for the where executeable file vim is |
c5a10c03afb8
patch 9.1.0044: po Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
33831
diff
changeset
|
42 # installed. Please do not put the path in quotes. |
c5a10c03afb8
patch 9.1.0044: po Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
33831
diff
changeset
|
43 VIM = ..\vim.exe |
32670
695b50472e85
Fix line endings issue
Christian Brabandt <cb@256bit.org>
parents:
32669
diff
changeset
|
44 |
33831
2b222b99faec
patch 9.0.2130: some errors with translation Makefiles
Christian Brabandt <cb@256bit.org>
parents:
33823
diff
changeset
|
45 # Correct the following line for the directory where gettext et al is |
2b222b99faec
patch 9.0.2130: some errors with translation Makefiles
Christian Brabandt <cb@256bit.org>
parents:
33823
diff
changeset
|
46 # installed. Please do not put the path in quotes. |
33823
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
47 GETTEXT_PATH = D:\Programs\GetText\bin |
32670
695b50472e85
Fix line endings issue
Christian Brabandt <cb@256bit.org>
parents:
32669
diff
changeset
|
48 |
34543
748a8a413816
patch 9.1.0173: msgfmt ver. 0.22 forcibly converts text to UTF-8
Christian Brabandt <cb@256bit.org>
parents:
34178
diff
changeset
|
49 # Starting from version 0.22, msgfmt forcibly converts text to UTF-8 regardless |
748a8a413816
patch 9.1.0173: msgfmt ver. 0.22 forcibly converts text to UTF-8
Christian Brabandt <cb@256bit.org>
parents:
34178
diff
changeset
|
50 # of the value of the "charset" field. |
748a8a413816
patch 9.1.0173: msgfmt ver. 0.22 forcibly converts text to UTF-8
Christian Brabandt <cb@256bit.org>
parents:
34178
diff
changeset
|
51 !IF [%comspec% /v:on /e:on /c "for /F "tokens=4 delims= " %G in \ |
748a8a413816
patch 9.1.0173: msgfmt ver. 0.22 forcibly converts text to UTF-8
Christian Brabandt <cb@256bit.org>
parents:
34178
diff
changeset
|
52 ('"$(GETTEXT_PATH)\msgfmt.exe" --version^|findstr /rc:[0-9^]\.[0-9^][0-9^]') do \ |
748a8a413816
patch 9.1.0173: msgfmt ver. 0.22 forcibly converts text to UTF-8
Christian Brabandt <cb@256bit.org>
parents:
34178
diff
changeset
|
53 @(set "v=%G" && if !v:~2^,2! GEQ 22 exit /b 1)"] |
748a8a413816
patch 9.1.0173: msgfmt ver. 0.22 forcibly converts text to UTF-8
Christian Brabandt <cb@256bit.org>
parents:
34178
diff
changeset
|
54 MSGFMT = "$(GETTEXT_PATH)\msgfmt.exe" -v --no-convert |
748a8a413816
patch 9.1.0173: msgfmt ver. 0.22 forcibly converts text to UTF-8
Christian Brabandt <cb@256bit.org>
parents:
34178
diff
changeset
|
55 !ELSE |
34178
c5a10c03afb8
patch 9.1.0044: po Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
33831
diff
changeset
|
56 MSGFMT = "$(GETTEXT_PATH)\msgfmt.exe" -v |
34543
748a8a413816
patch 9.1.0173: msgfmt ver. 0.22 forcibly converts text to UTF-8
Christian Brabandt <cb@256bit.org>
parents:
34178
diff
changeset
|
57 !ENDIF |
34178
c5a10c03afb8
patch 9.1.0044: po Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
33831
diff
changeset
|
58 XGETTEXT = "$(GETTEXT_PATH)\xgettext.exe" |
c5a10c03afb8
patch 9.1.0044: po Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
33831
diff
changeset
|
59 MSGMERGE = "$(GETTEXT_PATH)\msgmerge.exe" |
32670
695b50472e85
Fix line endings issue
Christian Brabandt <cb@256bit.org>
parents:
32669
diff
changeset
|
60 |
33823
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
61 # In case some package like GnuWin32, UnixUtils, gettext |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
62 # or something similar is installed on the system. |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
63 # If the "iconv" program is installed on the system, but it is not registered |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
64 # in the %PATH% environment variable, then specify the full path to this file. |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
65 !IF EXIST ("iconv.exe") |
34543
748a8a413816
patch 9.1.0173: msgfmt ver. 0.22 forcibly converts text to UTF-8
Christian Brabandt <cb@256bit.org>
parents:
34178
diff
changeset
|
66 ICONV = iconv.exe |
33823
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
67 !ELSEIF EXIST ("$(GETTEXT_PATH)\iconv.exe") |
34543
748a8a413816
patch 9.1.0173: msgfmt ver. 0.22 forcibly converts text to UTF-8
Christian Brabandt <cb@256bit.org>
parents:
34178
diff
changeset
|
68 ICONV = "$(GETTEXT_PATH)\iconv.exe" |
33823
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
69 !ENDIF |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
70 |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
71 # In case some package like GnuWin32, UnixUtils |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
72 # or something similar is installed on the system. |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
73 # If the "touch" program is installed on the system, but it is not registered |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
74 # in the %PATH% environment variable, then specify the full path to this file. |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
75 !IF EXIST ("touch.exe") |
33831
2b222b99faec
patch 9.0.2130: some errors with translation Makefiles
Christian Brabandt <cb@256bit.org>
parents:
33823
diff
changeset
|
76 TOUCH_TARGET = touch.exe $@ |
33823
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
77 !ELSE |
33831
2b222b99faec
patch 9.0.2130: some errors with translation Makefiles
Christian Brabandt <cb@256bit.org>
parents:
33823
diff
changeset
|
78 TOUCH_TARGET = @if exist $@ ( copy /b $@+,, ) else ( type nul >$@ ) |
33823
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
79 !ENDIF |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
80 |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
81 MV = move /y |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
82 CP = copy /y |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
83 RM = del /q |
32670
695b50472e85
Fix line endings issue
Christian Brabandt <cb@256bit.org>
parents:
32669
diff
changeset
|
84 MKD = mkdir |
695b50472e85
Fix line endings issue
Christian Brabandt <cb@256bit.org>
parents:
32669
diff
changeset
|
85 LS = dir |
34178
c5a10c03afb8
patch 9.1.0044: po Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
33831
diff
changeset
|
86 PS = PowerShell.exe |
32670
695b50472e85
Fix line endings issue
Christian Brabandt <cb@256bit.org>
parents:
32669
diff
changeset
|
87 |
695b50472e85
Fix line endings issue
Christian Brabandt <cb@256bit.org>
parents:
32669
diff
changeset
|
88 LSFLAGS = /b /on /l /s |
34178
c5a10c03afb8
patch 9.1.0044: po Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
33831
diff
changeset
|
89 PSFLAGS = -NoLogo -NoProfile -Command |
32670
695b50472e85
Fix line endings issue
Christian Brabandt <cb@256bit.org>
parents:
32669
diff
changeset
|
90 |
695b50472e85
Fix line endings issue
Christian Brabandt <cb@256bit.org>
parents:
32669
diff
changeset
|
91 INSTALLDIR = $(VIMRUNTIME)\lang\$(LANGUAGE)\LC_MESSAGES |
695b50472e85
Fix line endings issue
Christian Brabandt <cb@256bit.org>
parents:
32669
diff
changeset
|
92 |
695b50472e85
Fix line endings issue
Christian Brabandt <cb@256bit.org>
parents:
32669
diff
changeset
|
93 .SUFFIXES: |
33823
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
94 .SUFFIXES: .po .mo .pot .ck |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
95 |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
96 all: $(MOFILES) $(MOCONVERTED) |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
97 |
34178
c5a10c03afb8
patch 9.1.0044: po Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
33831
diff
changeset
|
98 originals : $(MOFILES) |
c5a10c03afb8
patch 9.1.0044: po Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
33831
diff
changeset
|
99 |
c5a10c03afb8
patch 9.1.0044: po Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
33831
diff
changeset
|
100 converted: $(MOCONVERTED) |
c5a10c03afb8
patch 9.1.0044: po Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
33831
diff
changeset
|
101 |
33823
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
102 .po.ck: |
34178
c5a10c03afb8
patch 9.1.0044: po Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
33831
diff
changeset
|
103 "$(VIM)" -u NONE --noplugins -e -s -X --cmd "set enc=utf-8" -S check.vim \ |
33831
2b222b99faec
patch 9.0.2130: some errors with translation Makefiles
Christian Brabandt <cb@256bit.org>
parents:
33823
diff
changeset
|
104 -c "if error == 0 | q | else | num 2 | cq | endif" $< |
2b222b99faec
patch 9.0.2130: some errors with translation Makefiles
Christian Brabandt <cb@256bit.org>
parents:
33823
diff
changeset
|
105 $(TOUCH_TARGET) |
33823
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
106 |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
107 check: $(CHECKFILES) |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
108 |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
109 checkclean: |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
110 $(RM) *.ck |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
111 |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
112 nl.po: |
34178
c5a10c03afb8
patch 9.1.0044: po Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
33831
diff
changeset
|
113 @( echo ^# >> nl.po ) |
33823
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
114 |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
115 # Norwegian/Bokmal: "nb" is an alias for "no". |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
116 nb.po: no.po |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
117 $(CP) no.po nb.po |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
118 |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
119 # Convert ja.po to create ja.sjis.po. |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
120 ja.sjis.po: ja.po |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
121 @$(MAKE) -nologo -f Make_mvc.mak sjiscorr |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
122 -$(RM) $@ |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
123 !IF EXIST ("$(GETTEXT_PATH)\msgconv.exe") |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
124 "$(GETTEXT_PATH)\msgconv.exe" -t CP932 $? | .\sjiscorr.exe > $@ |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
125 !ELSEIF DEFINED (ICONV) |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
126 $(ICONV) -f UTF-8 -t CP932 $? | .\sjiscorr.exe > $@ |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
127 !ELSE |
34178
c5a10c03afb8
patch 9.1.0044: po Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
33831
diff
changeset
|
128 $(PS) $(PSFLAGS) [System.IO.File]::WriteAllText(\"$@\", \ |
33823
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
129 [System.IO.File]::ReadAllText(\"$?\", \ |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
130 [System.Text.Encoding]::GetEncoding(65001)), \ |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
131 [System.Text.Encoding]::GetEncoding(932)) |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
132 type $@ | .\sjiscorr.exe > tmp.$@ |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
133 @$(MV) tmp.$@ $@ |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
134 !ENDIF |
34178
c5a10c03afb8
patch 9.1.0044: po Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
33831
diff
changeset
|
135 $(PS) $(PSFLAGS) $$out = [System.IO.File]::ReadAllText(\"$@\", \ |
33823
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
136 [System.Text.Encoding]::GetEncoding(932)) \ |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
137 -replace \"`r`n\", \"`n\"; \ |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
138 [System.IO.File]::WriteAllText(\"$@\", $$out, \ |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
139 [System.Text.Encoding]::GetEncoding(932)) |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
140 |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
141 sjiscorr: sjiscorr.c |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
142 $(CC) sjiscorr.c |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
143 |
34543
748a8a413816
patch 9.1.0173: msgfmt ver. 0.22 forcibly converts text to UTF-8
Christian Brabandt <cb@256bit.org>
parents:
34178
diff
changeset
|
144 # Convert ja.po to create ja.euc-jp.po. |
33823
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
145 ja.euc-jp.po: ja.po |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
146 -$(RM) $@ |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
147 !IF EXIST ("$(GETTEXT_PATH)\msgconv.exe") |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
148 "$(GETTEXT_PATH)\msgconv.exe" -t EUC-JP -o $@ $? |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
149 !ELSE |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
150 ! IF DEFINED (ICONV) |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
151 $(ICONV) -f UTF-8 -t EUC-JP $? > $@ |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
152 ! ELSE |
34178
c5a10c03afb8
patch 9.1.0044: po Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
33831
diff
changeset
|
153 $(PS) $(PSFLAGS) [System.IO.File]::WriteAllText(\"$@\", \ |
33823
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
154 [System.IO.File]::ReadAllText(\"$?\", \ |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
155 [System.Text.Encoding]::GetEncoding(65001)), \ |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
156 [System.Text.Encoding]::GetEncoding(20932)) |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
157 ! ENDIF |
34178
c5a10c03afb8
patch 9.1.0044: po Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
33831
diff
changeset
|
158 $(PS) $(PSFLAGS) $$out = [System.IO.File]::ReadAllText(\"$@\", \ |
33823
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
159 [System.Text.Encoding]::GetEncoding(20932)) -replace \ |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
160 'charset=utf-8', 'charset=EUC-JP'; \ |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
161 [System.IO.File]::WriteAllText(\"$@\", $$out, \ |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
162 [System.Text.Encoding]::GetEncoding(20932)) |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
163 !ENDIF |
34178
c5a10c03afb8
patch 9.1.0044: po Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
33831
diff
changeset
|
164 $(PS) $(PSFLAGS) $$out = [System.IO.File]::ReadAllText(\"$@\", \ |
33823
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
165 [System.Text.Encoding]::GetEncoding(20932)) -replace \ |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
166 '# Original translations', \ |
34178
c5a10c03afb8
patch 9.1.0044: po Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
33831
diff
changeset
|
167 '# Generated from $?, DO NOT EDIT'; \ |
33823
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
168 [System.IO.File]::WriteAllText(\"$@\", $$out, \ |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
169 [System.Text.Encoding]::GetEncoding(20932)) |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
170 |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
171 # Convert cs.po to create cs.cp1250.po. |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
172 cs.cp1250.po: cs.po |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
173 -$(RM) $@ |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
174 !IF EXIST ("$(GETTEXT_PATH)\msgconv.exe") |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
175 "$(GETTEXT_PATH)\msgconv.exe" -t CP1250 -o $@ $? |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
176 !ELSE |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
177 ! IF DEFINED (ICONV) |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
178 $(ICONV) -f ISO-8859-2 -t CP1250 $? > $@ |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
179 ! ELSE |
34178
c5a10c03afb8
patch 9.1.0044: po Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
33831
diff
changeset
|
180 $(PS) $(PSFLAGS) [System.IO.File]::WriteAllText(\"$@\", \ |
33823
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
181 [System.IO.File]::ReadAllText(\"$?\", \ |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
182 [System.Text.Encoding]::GetEncoding(28592)), \ |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
183 [System.Text.Encoding]::GetEncoding(1250)) |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
184 ! ENDIF |
34178
c5a10c03afb8
patch 9.1.0044: po Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
33831
diff
changeset
|
185 $(PS) $(PSFLAGS) $$out = [System.IO.File]::ReadAllText(\"$@\", \ |
33823
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
186 [System.Text.Encoding]::GetEncoding(1250)) -replace \ |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
187 'charset=iso-8859-2', 'charset=CP1250'; \ |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
188 [System.IO.File]::WriteAllText(\"$@\", $$out, \ |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
189 [System.Text.Encoding]::GetEncoding(1250)) |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
190 !ENDIF |
34178
c5a10c03afb8
patch 9.1.0044: po Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
33831
diff
changeset
|
191 $(PS) $(PSFLAGS) $$out = [System.IO.File]::ReadAllText(\"$@\", \ |
33823
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
192 [System.Text.Encoding]::GetEncoding(1250)) -replace \ |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
193 '# Original translations', \ |
34178
c5a10c03afb8
patch 9.1.0044: po Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
33831
diff
changeset
|
194 '# Generated from $?, DO NOT EDIT'; \ |
33823
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
195 [System.IO.File]::WriteAllText(\"$@\", $$out, \ |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
196 [System.Text.Encoding]::GetEncoding(1250)) |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
197 |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
198 # Convert pl.po to create pl.cp1250.po. |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
199 pl.cp1250.po: pl.po |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
200 -$(RM) $@ |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
201 !IF EXIST ("$(GETTEXT_PATH)\msgconv.exe") |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
202 "$(GETTEXT_PATH)\msgconv.exe" -t CP1250 -o $@ $? |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
203 !ELSE |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
204 ! IF DEFINED (ICONV) |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
205 $(ICONV) -f ISO-8859-2 -t CP1250 $? > $@ |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
206 ! ELSE |
34178
c5a10c03afb8
patch 9.1.0044: po Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
33831
diff
changeset
|
207 $(PS) $(PSFLAGS) [System.IO.File]::WriteAllText(\"$@\", \ |
33823
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
208 [System.IO.File]::ReadAllText(\"$?\", \ |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
209 [System.Text.Encoding]::GetEncoding(28592)), \ |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
210 [System.Text.Encoding]::GetEncoding(1250)) |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
211 ! ENDIF |
34178
c5a10c03afb8
patch 9.1.0044: po Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
33831
diff
changeset
|
212 $(PS) $(PSFLAGS) $$out = [System.IO.File]::ReadAllText(\"$@\", \ |
33823
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
213 [System.Text.Encoding]::GetEncoding(1250)) -replace \ |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
214 'charset=iso-8859-2', 'charset=CP1250'; \ |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
215 [System.IO.File]::WriteAllText(\"$@\", $$out, \ |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
216 [System.Text.Encoding]::GetEncoding(1250)) |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
217 !ENDIF |
34178
c5a10c03afb8
patch 9.1.0044: po Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
33831
diff
changeset
|
218 $(PS) $(PSFLAGS) $$out = [System.IO.File]::ReadAllText(\"$@\", \ |
33823
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
219 [System.Text.Encoding]::GetEncoding(1250)) -replace \ |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
220 '# Original translations', \ |
34178
c5a10c03afb8
patch 9.1.0044: po Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
33831
diff
changeset
|
221 '# Generated from $?, DO NOT EDIT'; \ |
33823
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
222 [System.IO.File]::WriteAllText(\"$@\", $$out, \ |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
223 [System.Text.Encoding]::GetEncoding(1250)) |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
224 |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
225 # Convert pl.po to create pl.UTF-8.po. |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
226 pl.UTF-8.po: pl.po |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
227 -$(RM) $@ |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
228 !IF EXIST ("$(GETTEXT_PATH)\msgconv.exe") |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
229 "$(GETTEXT_PATH)\msgconv.exe" -t UTF-8 -o $@ $? |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
230 !ELSE |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
231 ! IF DEFINED (ICONV) |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
232 $(ICONV) -f ISO-8859-2 -t UTF-8 $? > $@ |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
233 ! ELSE |
34178
c5a10c03afb8
patch 9.1.0044: po Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
33831
diff
changeset
|
234 $(PS) $(PSFLAGS) [System.IO.File]::WriteAllText(\"$@\", \ |
33823
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
235 [System.IO.File]::ReadAllText(\"$?\", \ |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
236 [System.Text.Encoding]::GetEncoding(28592))) |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
237 ! ENDIF |
34178
c5a10c03afb8
patch 9.1.0044: po Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
33831
diff
changeset
|
238 $(PS) $(PSFLAGS) (Get-Content -Raw -Encoding UTF8 $@ \ |
33823
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
239 ^| % {$$_-replace 'charset=iso-8859-2', 'charset=UTF-8'}) \ |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
240 ^| 1>nul New-Item -Force -Path . -ItemType file -Name $@ |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
241 !ENDIF |
34178
c5a10c03afb8
patch 9.1.0044: po Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
33831
diff
changeset
|
242 $(PS) $(PSFLAGS) (Get-Content -Raw -Encoding UTF8 $@ \ |
33823
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
243 ^| % {$$_-replace '# Original translations', \ |
34178
c5a10c03afb8
patch 9.1.0044: po Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
33831
diff
changeset
|
244 '# Generated from $?, DO NOT EDIT'}) \ |
33823
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
245 ^| 1>nul New-Item -Force -Path . -ItemType file -Name $@ |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
246 |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
247 # Convert sk.po to create sk.cp1250.po. |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
248 sk.cp1250.po: sk.po |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
249 -$(RM) $@ |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
250 !IF EXIST ("$(GETTEXT_PATH)\msgconv.exe") |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
251 "$(GETTEXT_PATH)\msgconv.exe" -t CP1250 -o $@ $? |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
252 !ELSE |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
253 ! IF DEFINED (ICONV) |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
254 $(ICONV) -f ISO-8859-2 -t CP1250 $? > $@ |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
255 ! ELSE |
34178
c5a10c03afb8
patch 9.1.0044: po Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
33831
diff
changeset
|
256 $(PS) $(PSFLAGS) [System.IO.File]::WriteAllText(\"$@\", \ |
33823
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
257 [System.IO.File]::ReadAllText(\"$?\", \ |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
258 [System.Text.Encoding]::GetEncoding(28592)), \ |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
259 [System.Text.Encoding]::GetEncoding(1250)) |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
260 ! ENDIF |
34178
c5a10c03afb8
patch 9.1.0044: po Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
33831
diff
changeset
|
261 $(PS) $(PSFLAGS) $$out = [System.IO.File]::ReadAllText(\"$@\", \ |
33823
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
262 [System.Text.Encoding]::GetEncoding(1250)) -replace \ |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
263 'charset=iso-8859-2', 'charset=CP1250'; \ |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
264 [System.IO.File]::WriteAllText(\"$@\", $$out, \ |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
265 [System.Text.Encoding]::GetEncoding(1250)) |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
266 !ENDIF |
34178
c5a10c03afb8
patch 9.1.0044: po Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
33831
diff
changeset
|
267 $(PS) $(PSFLAGS) $$out = [System.IO.File]::ReadAllText(\"$@\", \ |
33823
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
268 [System.Text.Encoding]::GetEncoding(1250)) -replace \ |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
269 '# Original translations', \ |
34178
c5a10c03afb8
patch 9.1.0044: po Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
33831
diff
changeset
|
270 '# Generated from $?, DO NOT EDIT'; \ |
33823
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
271 [System.IO.File]::WriteAllText(\"$@\", $$out, \ |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
272 [System.Text.Encoding]::GetEncoding(1250)) |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
273 |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
274 # Convert zh_CN.UTF-8.po to create zh_CN.po. |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
275 zh_CN.po: zh_CN.UTF-8.po |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
276 -$(RM) $@ |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
277 !IF EXIST ("$(GETTEXT_PATH)\msgconv.exe") |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
278 "$(GETTEXT_PATH)\msgconv.exe" -t GB2312 -o $@ $? |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
279 !ELSE |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
280 ! IF DEFINED (ICONV) |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
281 $(ICONV) -f UTF-8 -t GB2312 $? > $@ |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
282 ! ELSE |
34178
c5a10c03afb8
patch 9.1.0044: po Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
33831
diff
changeset
|
283 $(PS) $(PSFLAGS) [System.IO.File]::WriteAllText(\"$@\", \ |
33823
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
284 [System.IO.File]::ReadAllText(\"$?\", \ |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
285 [System.Text.Encoding]::GetEncoding(65001)), \ |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
286 [System.Text.Encoding]::GetEncoding(936)) |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
287 |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
288 ! ENDIF |
34178
c5a10c03afb8
patch 9.1.0044: po Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
33831
diff
changeset
|
289 $(PS) $(PSFLAGS) $$out = [System.IO.File]::ReadAllText(\"$@\", \ |
33823
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
290 [System.Text.Encoding]::GetEncoding(936)) -replace \ |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
291 'charset=UTF-8', 'charset=GB2312'; \ |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
292 [System.IO.File]::WriteAllText(\"$@\", $$out, \ |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
293 [System.Text.Encoding]::GetEncoding(936)) |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
294 !ENDIF |
34178
c5a10c03afb8
patch 9.1.0044: po Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
33831
diff
changeset
|
295 $(PS) $(PSFLAGS) $$out = [System.IO.File]::ReadAllText(\"$@\", \ |
33823
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
296 [System.Text.Encoding]::GetEncoding(936)) -replace \ |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
297 '# Original translations', \ |
34178
c5a10c03afb8
patch 9.1.0044: po Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
33831
diff
changeset
|
298 '# Generated from $?, DO NOT EDIT'; \ |
33823
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
299 [System.IO.File]::WriteAllText(\"$@\", $$out, \ |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
300 [System.Text.Encoding]::GetEncoding(936)) |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
301 |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
302 # Convert zh_CN.UTF-8.po to create zh_CN.cp936.po. |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
303 # Set 'charset' to gbk to avoid that msfmt generates a warning. |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
304 # This used to convert from zh_CN.po, but that results in a conversion error. |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
305 zh_CN.cp936.po: zh_CN.UTF-8.po |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
306 -$(RM) $@ |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
307 !IF DEFINED (ICONV) |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
308 $(ICONV) -f UTF-8 -t CP936 $? > $@ |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
309 !ELSE |
34178
c5a10c03afb8
patch 9.1.0044: po Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
33831
diff
changeset
|
310 $(PS) $(PSFLAGS) [System.IO.File]::WriteAllText(\"$@\", \ |
33823
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
311 [System.IO.File]::ReadAllText(\"$?\", \ |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
312 [System.Text.Encoding]::GetEncoding(65001)), \ |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
313 [System.Text.Encoding]::GetEncoding(20936)) |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
314 |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
315 !ENDIF |
34178
c5a10c03afb8
patch 9.1.0044: po Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
33831
diff
changeset
|
316 $(PS) $(PSFLAGS) $$out = [System.IO.File]::ReadAllText(\"$@\", \ |
33823
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
317 [System.Text.Encoding]::GetEncoding(20936)) \ |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
318 -replace 'charset=UTF-8', 'charset=GBK'\ |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
319 -replace '# Original translations', \ |
34178
c5a10c03afb8
patch 9.1.0044: po Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
33831
diff
changeset
|
320 '# Generated from $?, DO NOT EDIT'; \ |
33823
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
321 [System.IO.File]::WriteAllText(\"$@\", $$out, \ |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
322 [System.Text.Encoding]::GetEncoding(20936)) |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
323 |
34543
748a8a413816
patch 9.1.0173: msgfmt ver. 0.22 forcibly converts text to UTF-8
Christian Brabandt <cb@256bit.org>
parents:
34178
diff
changeset
|
324 # Convert zh_TW.UTF-8.po to create zh_TW.po. |
33823
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
325 zh_TW.po: zh_TW.UTF-8.po |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
326 -$(RM) $@ |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
327 !IF EXIST ("$(GETTEXT_PATH)\msgconv.exe") |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
328 "$(GETTEXT_PATH)\msgconv.exe" -t BIG5 -o $@ $? |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
329 !ELSE |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
330 ! IF DEFINED (ICONV) |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
331 $(ICONV) -f UTF-8 -t BIG5 $? > $@ |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
332 ! ELSE |
34178
c5a10c03afb8
patch 9.1.0044: po Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
33831
diff
changeset
|
333 $(PS) $(PSFLAGS) [System.IO.File]::WriteAllText(\"$@\", \ |
33823
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
334 [System.IO.File]::ReadAllText(\"$?\", \ |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
335 [System.Text.Encoding]::GetEncoding(65001)), \ |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
336 [System.Text.Encoding]::GetEncoding(950)) |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
337 |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
338 ! ENDIF |
34178
c5a10c03afb8
patch 9.1.0044: po Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
33831
diff
changeset
|
339 $(PS) $(PSFLAGS) $$out = [System.IO.File]::ReadAllText(\"$@\", \ |
33823
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
340 [System.Text.Encoding]::GetEncoding(950)) -replace \ |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
341 'charset=UTF-8', 'charset=BIG5'; \ |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
342 [System.IO.File]::WriteAllText(\"$@\", $$out, \ |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
343 [System.Text.Encoding]::GetEncoding(950)) |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
344 !ENDIF |
34178
c5a10c03afb8
patch 9.1.0044: po Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
33831
diff
changeset
|
345 $(PS) $(PSFLAGS) $$out = [System.IO.File]::ReadAllText(\"$@\", \ |
33823
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
346 [System.Text.Encoding]::GetEncoding(950)) -replace \ |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
347 '# Original translations', \ |
34178
c5a10c03afb8
patch 9.1.0044: po Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
33831
diff
changeset
|
348 '# Generated from $?, DO NOT EDIT'; \ |
33823
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
349 [System.IO.File]::WriteAllText(\"$@\", $$out, \ |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
350 [System.Text.Encoding]::GetEncoding(950)) |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
351 |
34543
748a8a413816
patch 9.1.0173: msgfmt ver. 0.22 forcibly converts text to UTF-8
Christian Brabandt <cb@256bit.org>
parents:
34178
diff
changeset
|
352 # Convert zh_TW.UTF-8.po to create zh_TW.po with backslash characters. |
33823
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
353 # Requires doubling backslashes in the second byte. Don't depend on big5corr, |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
354 # it should only be compiled when zh_TW.po is outdated. |
34178
c5a10c03afb8
patch 9.1.0044: po Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
33831
diff
changeset
|
355 |
33823
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
356 # |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
357 # 06.11.23, added by Restorer: |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
358 # For more details, see: |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
359 # https://github.com/vim/vim/pull/3261 |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
360 # https://github.com/vim/vim/pull/3476 |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
361 # https://github.com/vim/vim/pull/12153 |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
362 # (read all comments) |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
363 # |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
364 # I checked the workability on the list of backslash characters |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
365 # specified in zh_TW.UTF-8.po. It works. |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
366 # But it is better to have someone native speaker check it. |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
367 # |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
368 |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
369 #zh_TW.po: zh_TW.UTF-8.po |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
370 # @$(MAKE) -nologo -f Make_mvc.mak big5corr |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
371 # -$(RM) $@ |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
372 #!IF EXIST ("$(GETTEXT_PATH)\msgconv.exe") |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
373 # "$(GETTEXT_PATH)\msgconv.exe" -t BIG5 $? | .\big5corr.exe > $@ |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
374 #!ELSEIF DEFINED (ICONV) |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
375 # $(ICONV) -f UTF-8 -t BIG5 $? | .\big5corr.exe > $@ |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
376 #!ELSE |
34178
c5a10c03afb8
patch 9.1.0044: po Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
33831
diff
changeset
|
377 # $(PS) $(PSFLAGS) [System.IO.File]::WriteAllText(\"$@\", \ |
33823
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
378 # [System.IO.File]::ReadAllText(\"$?\", \ |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
379 # [System.Text.Encoding]::GetEncoding(65001)), \ |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
380 # [System.Text.Encoding]::GetEncoding(950)) |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
381 # type $@ | .\big5corr.exe > tmp.$@ |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
382 # @$(MV) tmp.$@ $@ |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
383 #!ENDIF |
34178
c5a10c03afb8
patch 9.1.0044: po Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
33831
diff
changeset
|
384 # $(PS) $(PSFLAGS) $$out = [System.IO.File]::ReadAllText(\"$@\", \ |
33823
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
385 # [System.Text.Encoding]::GetEncoding(950)) \ |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
386 # -replace \"`r`n\", \"`n\"; \ |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
387 # [System.IO.File]::WriteAllText(\"$@\", $$out, \ |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
388 # [System.Text.Encoding]::GetEncoding(950)) |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
389 |
34543
748a8a413816
patch 9.1.0173: msgfmt ver. 0.22 forcibly converts text to UTF-8
Christian Brabandt <cb@256bit.org>
parents:
34178
diff
changeset
|
390 # See above in the zh_TW.po conversion section for backslashes. |
33823
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
391 #big5corr: big5corr.c |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
392 # $(CC) big5corr.c |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
393 |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
394 # Convert ko.UTF-8.po to create ko.po. |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
395 ko.po: ko.UTF-8.po |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
396 -$(RM) $@ |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
397 !IF EXIST ("$(GETTEXT_PATH)\msgconv.exe") |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
398 "$(GETTEXT_PATH)\msgconv.exe" -t EUC-KR -o $@ $? |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
399 !ELSE |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
400 ! IF DEFINED (ICONV) |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
401 $(ICONV) -f UTF-8 -t EUC-KR $? > $@ |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
402 ! ELSE |
34178
c5a10c03afb8
patch 9.1.0044: po Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
33831
diff
changeset
|
403 $(PS) $(PSFLAGS) [System.IO.File]::WriteAllText(\"$@\", \ |
33823
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
404 [System.IO.File]::ReadAllText(\"$?\", \ |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
405 [System.Text.Encoding]::GetEncoding(65001)), \ |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
406 [System.Text.Encoding]::GetEncoding(51949)) |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
407 |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
408 ! ENDIF |
34178
c5a10c03afb8
patch 9.1.0044: po Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
33831
diff
changeset
|
409 $(PS) $(PSFLAGS) $$out = [System.IO.File]::ReadAllText(\"$@\", \ |
33823
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
410 [System.Text.Encoding]::GetEncoding(51949)) -replace \ |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
411 'charset=UTF-8', 'charset=EUC-KR'; \ |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
412 [System.IO.File]::WriteAllText(\"$@\", $$out, \ |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
413 [System.Text.Encoding]::GetEncoding(51949)) |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
414 !ENDIF |
34178
c5a10c03afb8
patch 9.1.0044: po Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
33831
diff
changeset
|
415 $(PS) $(PSFLAGS) $$out = [System.IO.File]::ReadAllText(\"$@\", \ |
33823
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
416 [System.Text.Encoding]::GetEncoding(51949)) -replace \ |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
417 '# Original translations', \ |
34178
c5a10c03afb8
patch 9.1.0044: po Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
33831
diff
changeset
|
418 '# Generated from $?, DO NOT EDIT'; \ |
33823
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
419 [System.IO.File]::WriteAllText(\"$@\", $$out, \ |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
420 [System.Text.Encoding]::GetEncoding(51949)) |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
421 |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
422 # Convert ru.po to create ru.cp1251.po. |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
423 ru.cp1251.po: ru.po |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
424 -$(RM) $@ |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
425 !IF EXIST ("$(GETTEXT_PATH)\msgconv.exe") |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
426 "$(GETTEXT_PATH)\msgconv.exe" -t CP1251 -o $@ $? |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
427 !ELSE |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
428 ! IF DEFINED (ICONV) |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
429 $(ICONV) -f UTF-8 -t CP1251 $? > $@ |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
430 ! ELSE |
34178
c5a10c03afb8
patch 9.1.0044: po Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
33831
diff
changeset
|
431 $(PS) $(PSFLAGS) [System.IO.File]::WriteAllText(\"$@\", \ |
33823
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
432 [System.IO.File]::ReadAllText(\"$?\", \ |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
433 [System.Text.Encoding]::GetEncoding(65001)), \ |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
434 [System.Text.Encoding]::GetEncoding(1251)) |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
435 |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
436 ! ENDIF |
34178
c5a10c03afb8
patch 9.1.0044: po Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
33831
diff
changeset
|
437 $(PS) $(PSFLAGS) $$out = [System.IO.File]::ReadAllText(\"$@\", \ |
33823
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
438 [System.Text.Encoding]::GetEncoding(1251)) -replace \ |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
439 'charset=UTF-8', 'charset=CP1251'; \ |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
440 [System.IO.File]::WriteAllText(\"$@\", $$out, \ |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
441 [System.Text.Encoding]::GetEncoding(1251)) |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
442 !ENDIF |
34178
c5a10c03afb8
patch 9.1.0044: po Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
33831
diff
changeset
|
443 $(PS) $(PSFLAGS) $$out = [System.IO.File]::ReadAllText(\"$@\", \ |
33823
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
444 [System.Text.Encoding]::GetEncoding(1251)) -replace \ |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
445 '# Original translations', \ |
34178
c5a10c03afb8
patch 9.1.0044: po Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
33831
diff
changeset
|
446 '# Generated from $?, DO NOT EDIT'; \ |
33823
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
447 [System.IO.File]::WriteAllText(\"$@\", $$out, \ |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
448 [System.Text.Encoding]::GetEncoding(1251)) |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
449 |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
450 # Convert uk.po to create uk.cp1251.po. |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
451 uk.cp1251.po: uk.po |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
452 -$(RM) $@ |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
453 !IF EXIST ("$(GETTEXT_PATH)\msgconv.exe") |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
454 "$(GETTEXT_PATH)\msgconv.exe" -t CP1251 -o $@ $? |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
455 !ELSE |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
456 ! IF DEFINED (ICONV) |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
457 $(ICONV) -f UTF-8 -t CP1251 $? > $@ |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
458 ! ELSE |
34178
c5a10c03afb8
patch 9.1.0044: po Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
33831
diff
changeset
|
459 $(PS) $(PSFLAGS) [System.IO.File]::WriteAllText(\"$@\", \ |
33823
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
460 [System.IO.File]::ReadAllText(\"$?\", \ |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
461 [System.Text.Encoding]::GetEncoding(65001)), \ |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
462 [System.Text.Encoding]::GetEncoding(1251)) |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
463 |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
464 ! ENDIF |
34178
c5a10c03afb8
patch 9.1.0044: po Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
33831
diff
changeset
|
465 $(PS) $(PSFLAGS) $$out = [System.IO.File]::ReadAllText(\"$@\", \ |
33823
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
466 [System.Text.Encoding]::GetEncoding(1251)) -replace \ |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
467 'charset=UTF-8', 'charset=CP1251'; \ |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
468 [System.IO.File]::WriteAllText(\"$@\", $$out, \ |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
469 [System.Text.Encoding]::GetEncoding(1251)) |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
470 !ENDIF |
34178
c5a10c03afb8
patch 9.1.0044: po Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
33831
diff
changeset
|
471 $(PS) $(PSFLAGS) $$out = [System.IO.File]::ReadAllText(\"$@\", \ |
33823
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
472 [System.Text.Encoding]::GetEncoding(1251)) -replace \ |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
473 '# Original translations', \ |
34178
c5a10c03afb8
patch 9.1.0044: po Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
33831
diff
changeset
|
474 '# Generated from $?, DO NOT EDIT'; \ |
33823
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
475 [System.IO.File]::WriteAllText(\"$@\", $$out, \ |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
476 [System.Text.Encoding]::GetEncoding(1251)) |
32670
695b50472e85
Fix line endings issue
Christian Brabandt <cb@256bit.org>
parents:
32669
diff
changeset
|
477 |
695b50472e85
Fix line endings issue
Christian Brabandt <cb@256bit.org>
parents:
32669
diff
changeset
|
478 .po.mo: |
695b50472e85
Fix line endings issue
Christian Brabandt <cb@256bit.org>
parents:
32669
diff
changeset
|
479 set OLD_PO_FILE_INPUT=yes |
695b50472e85
Fix line endings issue
Christian Brabandt <cb@256bit.org>
parents:
32669
diff
changeset
|
480 $(MSGFMT) -o $@ $< |
695b50472e85
Fix line endings issue
Christian Brabandt <cb@256bit.org>
parents:
32669
diff
changeset
|
481 |
695b50472e85
Fix line endings issue
Christian Brabandt <cb@256bit.org>
parents:
32669
diff
changeset
|
482 PO_INPUTLIST = \ |
695b50472e85
Fix line endings issue
Christian Brabandt <cb@256bit.org>
parents:
32669
diff
changeset
|
483 ..\*.c \ |
695b50472e85
Fix line endings issue
Christian Brabandt <cb@256bit.org>
parents:
32669
diff
changeset
|
484 ..\if_perl.xs \ |
695b50472e85
Fix line endings issue
Christian Brabandt <cb@256bit.org>
parents:
32669
diff
changeset
|
485 ..\GvimExt\gvimext.cpp \ |
695b50472e85
Fix line endings issue
Christian Brabandt <cb@256bit.org>
parents:
32669
diff
changeset
|
486 ..\errors.h \ |
695b50472e85
Fix line endings issue
Christian Brabandt <cb@256bit.org>
parents:
32669
diff
changeset
|
487 ..\globals.h \ |
695b50472e85
Fix line endings issue
Christian Brabandt <cb@256bit.org>
parents:
32669
diff
changeset
|
488 ..\if_py_both.h \ |
695b50472e85
Fix line endings issue
Christian Brabandt <cb@256bit.org>
parents:
32669
diff
changeset
|
489 ..\vim.h \ |
695b50472e85
Fix line endings issue
Christian Brabandt <cb@256bit.org>
parents:
32669
diff
changeset
|
490 gvim.desktop.in \ |
695b50472e85
Fix line endings issue
Christian Brabandt <cb@256bit.org>
parents:
32669
diff
changeset
|
491 vim.desktop.in |
695b50472e85
Fix line endings issue
Christian Brabandt <cb@256bit.org>
parents:
32669
diff
changeset
|
492 |
695b50472e85
Fix line endings issue
Christian Brabandt <cb@256bit.org>
parents:
32669
diff
changeset
|
493 files: $(PO_INPUTLIST) |
695b50472e85
Fix line endings issue
Christian Brabandt <cb@256bit.org>
parents:
32669
diff
changeset
|
494 $(LS) $(LSFLAGS) $(PO_INPUTLIST) > .\files |
695b50472e85
Fix line endings issue
Christian Brabandt <cb@256bit.org>
parents:
32669
diff
changeset
|
495 |
34178
c5a10c03afb8
patch 9.1.0044: po Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
33831
diff
changeset
|
496 first_time: files |
c5a10c03afb8
patch 9.1.0044: po Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
33831
diff
changeset
|
497 "$(VIM)" -u NONE --not-a-term -S tojavascript.vim $(LANGUAGE).po \ |
33823
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
498 $(PO_VIM_INPUTLIST) |
32670
695b50472e85
Fix line endings issue
Christian Brabandt <cb@256bit.org>
parents:
32669
diff
changeset
|
499 set OLD_PO_FILE_INPUT=yes |
695b50472e85
Fix line endings issue
Christian Brabandt <cb@256bit.org>
parents:
32669
diff
changeset
|
500 set OLD_PO_FILE_OUTPUT=yes |
33823
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
501 $(XGETTEXT) --default-domain=$(LANGUAGE) --add-comments $(XGETTEXT_KEYWORDS) \ |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
502 --files-from=.\files $(PO_VIM_JSLIST) |
34178
c5a10c03afb8
patch 9.1.0044: po Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
33831
diff
changeset
|
503 "$(VIM)" -u NONE --not-a-term -S fixfilenames.vim $(LANGUAGE).po \ |
33823
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
504 $(PO_VIM_INPUTLIST) |
32670
695b50472e85
Fix line endings issue
Christian Brabandt <cb@256bit.org>
parents:
32669
diff
changeset
|
505 $(RM) *.js |
695b50472e85
Fix line endings issue
Christian Brabandt <cb@256bit.org>
parents:
32669
diff
changeset
|
506 |
695b50472e85
Fix line endings issue
Christian Brabandt <cb@256bit.org>
parents:
32669
diff
changeset
|
507 $(PACKAGE).pot: files |
34178
c5a10c03afb8
patch 9.1.0044: po Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
33831
diff
changeset
|
508 "$(VIM)" -u NONE --not-a-term -S tojavascript.vim $(PACKAGE).pot \ |
33823
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
509 $(PO_VIM_INPUTLIST) |
32670
695b50472e85
Fix line endings issue
Christian Brabandt <cb@256bit.org>
parents:
32669
diff
changeset
|
510 set OLD_PO_FILE_INPUT=yes |
695b50472e85
Fix line endings issue
Christian Brabandt <cb@256bit.org>
parents:
32669
diff
changeset
|
511 set OLD_PO_FILE_OUTPUT=yes |
33823
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
512 $(XGETTEXT) --default-domain=$(PACKAGE) --add-comments $(XGETTEXT_KEYWORDS) \ |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
513 --files-from=.\files $(PO_VIM_JSLIST) |
32670
695b50472e85
Fix line endings issue
Christian Brabandt <cb@256bit.org>
parents:
32669
diff
changeset
|
514 $(MV) $(PACKAGE).po $(PACKAGE).pot |
34178
c5a10c03afb8
patch 9.1.0044: po Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
33831
diff
changeset
|
515 "$(VIM)" -u NONE --not-a-term -S fixfilenames.vim $(PACKAGE).pot \ |
33823
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
516 $(PO_VIM_INPUTLIST) |
32670
695b50472e85
Fix line endings issue
Christian Brabandt <cb@256bit.org>
parents:
32669
diff
changeset
|
517 $(RM) *.js |
695b50472e85
Fix line endings issue
Christian Brabandt <cb@256bit.org>
parents:
32669
diff
changeset
|
518 |
34178
c5a10c03afb8
patch 9.1.0044: po Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
33831
diff
changeset
|
519 # Only original translations with default encoding should be updated. |
33823
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
520 # The files that are converted to a different encoding clearly state "DO NOT EDIT". |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
521 update-po: $(MOFILES:.mo=) |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
522 |
34543
748a8a413816
patch 9.1.0173: msgfmt ver. 0.22 forcibly converts text to UTF-8
Christian Brabandt <cb@256bit.org>
parents:
34178
diff
changeset
|
523 # Don't add a dependency here, we only want to update the .po files manually. |
32670
695b50472e85
Fix line endings issue
Christian Brabandt <cb@256bit.org>
parents:
32669
diff
changeset
|
524 $(LANGUAGES): |
34178
c5a10c03afb8
patch 9.1.0044: po Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
33831
diff
changeset
|
525 @$(MAKE) -nologo -f Make_mvc.mak GETTEXT_PATH="$(GETTEXT_PATH)" $(PACKAGE).pot |
32670
695b50472e85
Fix line endings issue
Christian Brabandt <cb@256bit.org>
parents:
32669
diff
changeset
|
526 $(CP) $@.po $@.po.orig |
695b50472e85
Fix line endings issue
Christian Brabandt <cb@256bit.org>
parents:
32669
diff
changeset
|
527 $(MV) $@.po $@.po.old |
695b50472e85
Fix line endings issue
Christian Brabandt <cb@256bit.org>
parents:
32669
diff
changeset
|
528 $(MSGMERGE) $@.po.old $(PACKAGE).pot -o $@.po |
695b50472e85
Fix line endings issue
Christian Brabandt <cb@256bit.org>
parents:
32669
diff
changeset
|
529 $(RM) $@.po.old |
695b50472e85
Fix line endings issue
Christian Brabandt <cb@256bit.org>
parents:
32669
diff
changeset
|
530 |
34178
c5a10c03afb8
patch 9.1.0044: po Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
33831
diff
changeset
|
531 install: $(LANGUAGE).mo |
34543
748a8a413816
patch 9.1.0173: msgfmt ver. 0.22 forcibly converts text to UTF-8
Christian Brabandt <cb@256bit.org>
parents:
34178
diff
changeset
|
532 if not exist "$(INSTALLDIR)" $(MKD) "$(INSTALLDIR)" |
748a8a413816
patch 9.1.0173: msgfmt ver. 0.22 forcibly converts text to UTF-8
Christian Brabandt <cb@256bit.org>
parents:
34178
diff
changeset
|
533 $(CP) $(LANGUAGE).mo "$(INSTALLDIR)\$(PACKAGE).mo" |
32670
695b50472e85
Fix line endings issue
Christian Brabandt <cb@256bit.org>
parents:
32669
diff
changeset
|
534 |
695b50472e85
Fix line endings issue
Christian Brabandt <cb@256bit.org>
parents:
32669
diff
changeset
|
535 install-all: all |
34543
748a8a413816
patch 9.1.0173: msgfmt ver. 0.22 forcibly converts text to UTF-8
Christian Brabandt <cb@256bit.org>
parents:
34178
diff
changeset
|
536 for %%l in ($(LANGUAGES)) do @if not exist "$(VIMRUNTIME)\lang\%%l\LC_MESSAGES" \ |
748a8a413816
patch 9.1.0173: msgfmt ver. 0.22 forcibly converts text to UTF-8
Christian Brabandt <cb@256bit.org>
parents:
34178
diff
changeset
|
537 $(MKD) "$(VIMRUNTIME)\lang\%%l\LC_MESSAGES" |
33823
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
538 for %%l in ($(LANGUAGES)) do @$(CP) %%l.mo \ |
34543
748a8a413816
patch 9.1.0173: msgfmt ver. 0.22 forcibly converts text to UTF-8
Christian Brabandt <cb@256bit.org>
parents:
34178
diff
changeset
|
539 "$(VIMRUNTIME)\lang\%%l\LC_MESSAGES\$(PACKAGE).mo" |
32670
695b50472e85
Fix line endings issue
Christian Brabandt <cb@256bit.org>
parents:
32669
diff
changeset
|
540 |
34178
c5a10c03afb8
patch 9.1.0044: po Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
33831
diff
changeset
|
541 cleanup-po: $(LANGUAGE).po |
c5a10c03afb8
patch 9.1.0044: po Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
33831
diff
changeset
|
542 "$(VIM)" -u NONE -e -X -S cleanup.vim -c wq $(LANGUAGE).po |
33823
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
543 |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
544 cleanup-po-all: $(POFILES) |
34178
c5a10c03afb8
patch 9.1.0044: po Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
33831
diff
changeset
|
545 !"$(VIM)" -u NONE -e -X -S cleanup.vim -c wq $** |
33823
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
546 |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
547 clean: checkclean |
32670
695b50472e85
Fix line endings issue
Christian Brabandt <cb@256bit.org>
parents:
32669
diff
changeset
|
548 $(RM) *.mo |
695b50472e85
Fix line endings issue
Christian Brabandt <cb@256bit.org>
parents:
32669
diff
changeset
|
549 $(RM) *.pot |
34178
c5a10c03afb8
patch 9.1.0044: po Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
33831
diff
changeset
|
550 $(RM) *.orig |
32670
695b50472e85
Fix line endings issue
Christian Brabandt <cb@256bit.org>
parents:
32669
diff
changeset
|
551 $(RM) files |
33823
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
552 $(RM) sjiscorr.obj sjiscorr.exe |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
553 # $(RM) big5corr.obj big5corr.exe |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
554 |
45c0a5330758
patch 9.0.2127: translation Makefiles can be improved
Christian Brabandt <cb@256bit.org>
parents:
32670
diff
changeset
|
555 # vim: set noet sw=8 ts=8 sts=0 wm=0 tw=0 ft=make: |