On Mon, Dec 11, 2017 at 9:56 AM, Glenn Morris <r...@gnu.org> wrote:
>
> Jim Meyering wrote (on Sun, 10 Dec 2017 at 17:01 -0800):
>
>> However, I don't see how "-f batch-byte-compile" can be used when
>> the .elc file must be created in a directory separate from the one
>> containing the .el file.
>
> I meant, instead of reinventing the wheel with this part:
>
>  --eval "(unless (byte-compile-file \"$<\") (kill-emacs 1))"
>
> Example:
>
> mkdir /tmp/foo /tmp/bar
> echo '(message "hi")' > /tmp/foo/foo.el
> emacs --batch \
>  --eval '(setq byte-compile-dest-file-function (lambda (x) 
> "/tmp/bar/foo.elc"))' \
>  -f batch-byte-compile /tmp/foo/foo.el
>
> -> generates /tmp/bar/foo.elc
>
> batch-byte-compile exists since forever.

Thank you. That looks better, indeed. I will see if I can adapt the
automake patch accordingly.

Reply via email to