482
|
1 # Aap recipe for Yiddish Vim spell files.
|
474
|
2
|
|
3 # Use a freshly compiled Vim if it exists.
|
|
4 @if os.path.exists('../../../src/vim'):
|
|
5 VIM = ../../../src/vim
|
|
6 @else:
|
|
7 :progsearch VIM vim
|
|
8
|
482
|
9 SPELLDIR = ..
|
|
10 FILES = yi.dic yi.aff
|
|
11 WORDFILE = wordlist.utf8.txt
|
|
12 FILES_TR = yi_tr.dic yi_tr.aff
|
|
13 WORDFILE_TR = wordlist.txt
|
474
|
14
|
482
|
15 all: $SPELLDIR/yi.utf-8.spl $SPELLDIR/yi-tr.utf-8.spl \
|
|
16 $SPELLDIR/yi.latin1.spl ../README_yi.txt
|
474
|
17
|
482
|
18 $SPELLDIR/yi.utf-8.spl : $FILES
|
474
|
19 :sys $VIM -u NONE -e -c "set enc=utf-8"
|
481
|
20 -c "mkspell! $SPELLDIR/yi yi" -c q
|
474
|
21
|
482
|
22 $SPELLDIR/yi-tr.utf-8.spl : $FILES_TR
|
|
23 :sys $VIM -u NONE -e -c "set enc=utf-8"
|
|
24 -c "mkspell! $SPELLDIR/yi-tr yi_tr" -c q
|
|
25
|
|
26 $SPELLDIR/yi.latin1.spl : $FILES_TR
|
|
27 :sys $VIM -u NONE -e -c "set enc=latin1"
|
|
28 -c "mkspell! $SPELLDIR/yi yi_tr" -c q
|
|
29
|
474
|
30 ../README_yi.txt : README.txt
|
|
31 :copy $source $target
|
|
32
|
|
33 #
|
|
34 # Fetch the word list when needed.
|
|
35 #
|
|
36 URLDIR = http://www.cs.uky.edu/~raphael/yiddish
|
482
|
37 :attr {fetch = $URLDIR/%file%} $WORDFILE $WORDFILE_TR
|
474
|
38
|
476
|
39 # We use the word list as a .dic file, so that we can use an affix file to
|
|
40 # define a few extra things.
|
|
41 $FILES: {buildcheck=}
|
|
42 :assertpkg patch
|
|
43 :fetch $WORDFILE
|
|
44 :copy $WORDFILE yi.dic
|
|
45 :touch {force} yi.aff
|
|
46 @if os.path.exists('yi.diff'):
|
|
47 :sys patch < yi.diff
|
|
48
|
482
|
49 $FILES_TR: {buildcheck=}
|
|
50 :assertpkg patch
|
|
51 :fetch $WORDFILE_TR
|
|
52 :copy $WORDFILE_TR yi_tr.dic
|
|
53 :touch {force} yi_tr.aff
|
|
54 @if os.path.exists('yi_tr.diff'):
|
|
55 :sys patch < yi_tr.diff
|
|
56
|
|
57 diff {virtual}:
|
476
|
58 :assertpkg diff
|
|
59 # Using a context of two lines to work around a bug in FreeBSD patch.
|
482
|
60 :sys {force} diff -a -C 2 $WORDFILE yi.dic > yi.diff
|
|
61 :sys {force} diff -a -N -C 1 /dev/null yi.aff >> yi.diff
|
|
62 :sys {force} diff -a -C 2 $WORDFILE_TR yi_tr.dic > yi_tr.diff
|
|
63 :sys {force} diff -a -N -C 1 /dev/null yi_tr.aff >> yi_tr.diff
|
474
|
64
|
|
65 # vim: set sts=4 sw=4 :
|