Subject: bug#65190: 30.0.50; Emacs doesn't build with `--with-mailutils` by default when mailutils is installed on macOS

From: Po Lu <[email-masked]>
Date: Thu, 10 Aug 2023 10:37:26 +0800

Mou Tong <[email-masked]> writes:

> After the android branch merged, the file `configure.ac`'s section about
> `mailutils` changed.
>
> When I build Emacs on macOS with `./configure`, cli will remind me:
>
> ```
> configure: WARNING: This configuration installs a 'movemail' program
> that does not retrieve POP3 email.  By default, Emacs 25 and earlier
> installed a 'movemail' program that retrieved POP3 email via only
> insecure channels, a practice that is no longer recommended but that
> you can continue to support by using './configure --with-pop'.
> configure: You might want to use './configure --with-mailutils'.
> ```
>
> I have installed mailtuils by homebrew (a package manager on macOS), and
> it works fine before the android branch got merged.
>
> I guess the problem occurs in this line
>
> https://git.savannah.gnu.org/cgit/emacs.git/tree/configure.ac?id=e1d08e9e11d2bd5e93c8ae4ea4a8e27129b316cb#n349
>
> But I don't know how to fix this :(

Does the problem resolve itself if you change:

     [AS_IF([test "x$XCONFIGURE" != "xandroid" \
             && test "$with_android" = "no"],
       [(movemail --version) >/dev/null 2>&1 || with_mailutils=no],

to read

     [AS_IF([test "x$XCONFIGURE" != "xandroid"],
       [(movemail --version) >/dev/null 2>&1 || with_mailutils=no],

?