Subject: bug#34215: 27.0.50; Provide elisp access to Chinese pinyin-to-character mapping

From: Eric Abrahamsen <[email-masked]>
Date: Wed, 30 Jan 2019 12:48:06 -0800

Eric Abrahamsen <[email-masked]> writes:

> Eli Zaretskii <[email-masked]> writes:
>
>>> From: Eric Abrahamsen <[email-masked]>
>>> Date: Tue, 29 Jan 2019 09:48:30 -0800
>>> 
>>> I've attached a diff adding the conversion function itself, but I'm not
>>> familiar with makefiles and so far haven't been able to figure out how
>>> to call it. It looks like the invocation I want will look like:
>>> 
>>> $(AM_V_GEN)${RUN_EMACS} -l titdic-cnv -f pinyin-convert \
>>>   ${srcdir}/MISC-DIC/pinyin.map ${srcdir}/../lisp/language/pinyin.el
>>> 
>>> Where ${srcdir} is the leim directory, but I don't actually know how to
>>> get this code called by make...
>>
>> Add a target that is the file produced by this command, then make the
>> above command the recipe of that target.  Similar to the
>> ${leimdir}/ja-dic/ja-dic.el target.
>>
>> But if the above doesn't help, someone else could do this part for
>> you.
>
> I've attached this as a commit patch -- it seems to work fine but I
> would appreciate it if you'd check it.

Oh, after reading a couple of "make" tutorials, I see maybe the make
rule could be simplified to:

${leimdir}/../lisp/language/pinyin.el: ${srcdir}/MISC-DIC/pinyin.map
  $(AM_V_GEN)${RUN_EMACS} -l titdic-cnv -f pinyin-convert $< $0