RE: ASPELL aspell-0.60.8.1 compilation failure on MSYS2 + MINGW64

Vincent Belaïche <[email protected]> Fri, 16 May 2025 09:48:00 +0000
Newsgroups gmane.comp.gnu.aspell.devel
Message-ID <DBBP194MB1098674F2E080943835A16E78493A@DBBP194MB1098.EURP194.PROD.OUTLOOK.COM>
--_000_DBBP194MB1098674F2E080943835A16E78493ADBBP194MB1098EURP_
Content-Type: text/plain; charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable

Hello,

My answer inserted below,

>De : Kevin Atkinson <[email protected]>
>Envoy=E9 : jeudi 15 mai 2025 18:35
>=C0 : Vincent Bela=EFche <[email protected]>
>Cc : [email protected] <[email protected]>
>Objet : Re: ASPELL aspell-0.60.8.1 compilation failure on MSYS2 + MINGW64
>
>Hi Vincent,
>
>On Thu, 15 May 2025 07:46:42 +0000
>Vincent Bela=EFche <[email protected]> wrote:
>
>> After investigating why so, I found that although I had installed the
>> French dictionary properly the =AB aspell dict =BB command made empty
>> output. After compiling from sources I had the same problem. Looking
>> into this, I found that the dictionary path was hard coded in some
>> gen/dirs.h generated header as an MSYS2 path that cannot be
>> understood by the aspell native Windows application. When you compile
>> on MINGW64 with no --prefix option passed to configure you get this
>> into gen/dirs.h :
>>
>> #define PREFIX "/mingw64"
>>
>> This problem can be easily circumvented by passing an absolute
>> MSWindows path to configure, like this :
>>
>> ./configure '--prefix=3Dc:/msys64/mingw64'
>>
>> as MSYS unerstands both native mixed path (mixed =3D just replacing \
>> by /) and MSYS paths.
>
>Thanks for the tip.
>
>> However, this could be automated by having somewhere in the
>> m4/lib-link.m4 or m4/lib-prefix.m4 the appropriate autotools M4 macro
>> for calling (cygpath -m PREFIX) under the hood when the target is
>> MINGW. This would certainly greatly help MSYS2/pacman repo
>> maintainers to compile aspell properly.
>
>There is a chance this might already be fixed with newer versions of
>autotools.  If possible try updating the versions of autotools to the
>latest and see if that helps (the script ./maintainer/autogen might
>help if you are using the release tarball, although you might have
>better luck if you checkout the version from git).

Actually I had tried this, I have this error when lauching ./autogen.sh:

  /THE/BUILD/DIRECTORY/aspell/gnulib/gnulib-tool.py: *** minimum supported =
autoconf version is 2.64. Try adding AC_PREREQ([2.64]) to your configure.ac=
.
  /THE/BUILD/DIRECTORY/aspell/gnulib/gnulib-tool.py: *** Stop.


>
>> The other issue that I had is that Emacs ispell.el needs also to know
>> where the dictionaries are located because it builds some
>> auto-completion list to help the user select a dictionary amongst
>> those available. To get this, Emacs ispell calls =AB aspell -vv =BB and
>> expects to find something like
>>
>> LIBDIR =3D "c:/msys64/mingw64/lib/aspell-0.60"
>>
>> in the output, where "c:/msys64/mingw64" is whatever prefix the user
>> configured at install. This also does not work, so I did some hack
>> which I attached.
>
>This is not a windows specific issue.  The correct way to get this
>information from aspell is:
>
>  aspell config dict-dir
>
>Kevin

Great, when time allows I will submit a patch to Emacs ispell.el in
order to fix this and use the correct way.

  V.

--_000_DBBP194MB1098674F2E080943835A16E78493ADBBP194MB1098EURP_
Content-Type: text/html; charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable

<html>
<head>
<meta http-equiv=3D"Content-Type" content=3D"text/html; charset=3Diso-8859-=
1">
<style type=3D"text/css" style=3D"display:none;"> P {margin-top:0;margin-bo=
ttom:0;} </style>
</head>
<body dir=3D"ltr">
<div style=3D"font-family: &quot;Courier New&quot;, monospace; font-size: 1=
2pt; color: rgb(0, 0, 0);">
Hello,</div>
<div style=3D"font-family: &quot;Courier New&quot;, monospace; font-size: 1=
2pt; color: rgb(0, 0, 0);">
<br>
</div>
<div style=3D"font-family: &quot;Courier New&quot;, monospace; font-size: 1=
2pt; color: rgb(0, 0, 0);">
My answer inserted below,</div>
<div style=3D"font-family: &quot;Courier New&quot;, monospace; font-size: 1=
2pt; color: rgb(0, 0, 0);">
<br>
</div>
<div style=3D"font-family: &quot;Courier New&quot;, monospace; font-size: 1=
2pt; color: rgb(0, 0, 0);">
&gt;De : Kevin Atkinson &lt;[email protected]&gt;</div>
<div style=3D"font-family: &quot;Courier New&quot;, monospace; font-size: 1=
2pt; color: rgb(0, 0, 0);">
&gt;Envoy=E9 : jeudi 15 mai 2025 18:35</div>
<div style=3D"font-family: &quot;Courier New&quot;, monospace; font-size: 1=
2pt; color: rgb(0, 0, 0);">
&gt;=C0 : Vincent Bela=EFche &lt;[email protected]&gt;</div>
<div style=3D"font-family: &quot;Courier New&quot;, monospace; font-size: 1=
2pt; color: rgb(0, 0, 0);">
&gt;Cc : [email protected] &lt;[email protected]&gt;</div>
<div style=3D"font-family: &quot;Courier New&quot;, monospace; font-size: 1=
2pt; color: rgb(0, 0, 0);">
&gt;Objet : Re: ASPELL aspell-0.60.8.1 compilation failure on MSYS2 + MINGW=
64</div>
<div style=3D"font-family: &quot;Courier New&quot;, monospace; font-size: 1=
2pt; color: rgb(0, 0, 0);">
&gt;</div>
<div style=3D"font-family: &quot;Courier New&quot;, monospace; font-size: 1=
2pt; color: rgb(0, 0, 0);">
&gt;Hi Vincent,</div>
<div style=3D"font-family: &quot;Courier New&quot;, monospace; font-size: 1=
2pt; color: rgb(0, 0, 0);">
&gt;</div>
<div style=3D"font-family: &quot;Courier New&quot;, monospace; font-size: 1=
2pt; color: rgb(0, 0, 0);">
&gt;On Thu, 15 May 2025 07:46:42 +0000</div>
<div style=3D"font-family: &quot;Courier New&quot;, monospace; font-size: 1=
2pt; color: rgb(0, 0, 0);">
&gt;Vincent Bela=EFche &lt;[email protected]&gt; wrote:</div>
<div style=3D"font-family: &quot;Courier New&quot;, monospace; font-size: 1=
2pt; color: rgb(0, 0, 0);">
&gt;</div>
<div style=3D"font-family: &quot;Courier New&quot;, monospace; font-size: 1=
2pt; color: rgb(0, 0, 0);">
&gt;&gt; After investigating why so, I found that although I had installed =
the</div>
<div style=3D"font-family: &quot;Courier New&quot;, monospace; font-size: 1=
2pt; color: rgb(0, 0, 0);">
&gt;&gt; French dictionary properly the =AB aspell dict =BB command made em=
pty</div>
<div style=3D"font-family: &quot;Courier New&quot;, monospace; font-size: 1=
2pt; color: rgb(0, 0, 0);">
&gt;&gt; output. After compiling from sources I had the same problem. Looki=
ng</div>
<div style=3D"font-family: &quot;Courier New&quot;, monospace; font-size: 1=
2pt; color: rgb(0, 0, 0);">
&gt;&gt; into this, I found that the dictionary path was hard coded in some=
</div>
<div style=3D"font-family: &quot;Courier New&quot;, monospace; font-size: 1=
2pt; color: rgb(0, 0, 0);">
&gt;&gt; gen/dirs.h generated header as an MSYS2 path that cannot be</div>
<div style=3D"font-family: &quot;Courier New&quot;, monospace; font-size: 1=
2pt; color: rgb(0, 0, 0);">
&gt;&gt; understood by the aspell native Windows application. When you comp=
ile</div>
<div style=3D"font-family: &quot;Courier New&quot;, monospace; font-size: 1=
2pt; color: rgb(0, 0, 0);">
&gt;&gt; on MINGW64 with no --prefix option passed to configure you get thi=
s</div>
<div style=3D"font-family: &quot;Courier New&quot;, monospace; font-size: 1=
2pt; color: rgb(0, 0, 0);">
&gt;&gt; into gen/dirs.h :</div>
<div style=3D"font-family: &quot;Courier New&quot;, monospace; font-size: 1=
2pt; color: rgb(0, 0, 0);">
&gt;&gt;</div>
<div style=3D"font-family: &quot;Courier New&quot;, monospace; font-size: 1=
2pt; color: rgb(0, 0, 0);">
&gt;&gt; #define PREFIX &quot;/mingw64&quot;</div>
<div style=3D"font-family: &quot;Courier New&quot;, monospace; font-size: 1=
2pt; color: rgb(0, 0, 0);">
&gt;&gt;</div>
<div style=3D"font-family: &quot;Courier New&quot;, monospace; font-size: 1=
2pt; color: rgb(0, 0, 0);">
&gt;&gt; This problem can be easily circumvented by passing an absolute</di=
v>
<div style=3D"font-family: &quot;Courier New&quot;, monospace; font-size: 1=
2pt; color: rgb(0, 0, 0);">
&gt;&gt; MSWindows path to configure, like this :</div>
<div style=3D"font-family: &quot;Courier New&quot;, monospace; font-size: 1=
2pt; color: rgb(0, 0, 0);">
&gt;&gt;</div>
<div style=3D"font-family: &quot;Courier New&quot;, monospace; font-size: 1=
2pt; color: rgb(0, 0, 0);">
&gt;&gt; ./configure '--prefix=3Dc:/msys64/mingw64'</div>
<div style=3D"font-family: &quot;Courier New&quot;, monospace; font-size: 1=
2pt; color: rgb(0, 0, 0);">
&gt;&gt;</div>
<div style=3D"font-family: &quot;Courier New&quot;, monospace; font-size: 1=
2pt; color: rgb(0, 0, 0);">
&gt;&gt; as MSYS unerstands both native mixed path (mixed =3D just replacin=
g \</div>
<div style=3D"font-family: &quot;Courier New&quot;, monospace; font-size: 1=
2pt; color: rgb(0, 0, 0);">
&gt;&gt; by /) and MSYS paths.</div>
<div style=3D"font-family: &quot;Courier New&quot;, monospace; font-size: 1=
2pt; color: rgb(0, 0, 0);">
&gt;</div>
<div style=3D"font-family: &quot;Courier New&quot;, monospace; font-size: 1=
2pt; color: rgb(0, 0, 0);">
&gt;Thanks for the tip.</div>
<div style=3D"font-family: &quot;Courier New&quot;, monospace; font-size: 1=
2pt; color: rgb(0, 0, 0);">
&gt;</div>
<div style=3D"font-family: &quot;Courier New&quot;, monospace; font-size: 1=
2pt; color: rgb(0, 0, 0);">
&gt;&gt; However, this could be automated by having somewhere in the</div>
<div style=3D"font-family: &quot;Courier New&quot;, monospace; font-size: 1=
2pt; color: rgb(0, 0, 0);">
&gt;&gt; m4/lib-link.m4 or m4/lib-prefix.m4 the appropriate autotools M4 ma=
cro</div>
<div style=3D"font-family: &quot;Courier New&quot;, monospace; font-size: 1=
2pt; color: rgb(0, 0, 0);">
&gt;&gt; for calling (cygpath -m PREFIX) under the hood when the target is<=
/div>
<div style=3D"font-family: &quot;Courier New&quot;, monospace; font-size: 1=
2pt; color: rgb(0, 0, 0);">
&gt;&gt; MINGW. This would certainly greatly help MSYS2/pacman repo</div>
<div style=3D"font-family: &quot;Courier New&quot;, monospace; font-size: 1=
2pt; color: rgb(0, 0, 0);">
&gt;&gt; maintainers to compile aspell properly.</div>
<div style=3D"font-family: &quot;Courier New&quot;, monospace; font-size: 1=
2pt; color: rgb(0, 0, 0);">
&gt;</div>
<div style=3D"font-family: &quot;Courier New&quot;, monospace; font-size: 1=
2pt; color: rgb(0, 0, 0);">
&gt;There is a chance this might already be fixed with newer versions of</d=
iv>
<div style=3D"font-family: &quot;Courier New&quot;, monospace; font-size: 1=
2pt; color: rgb(0, 0, 0);">
&gt;autotools. &nbsp;If possible try updating the versions of autotools to =
the</div>
<div style=3D"font-family: &quot;Courier New&quot;, monospace; font-size: 1=
2pt; color: rgb(0, 0, 0);">
&gt;latest and see if that helps (the script ./maintainer/autogen might</di=
v>
<div style=3D"font-family: &quot;Courier New&quot;, monospace; font-size: 1=
2pt; color: rgb(0, 0, 0);">
&gt;help if you are using the release tarball, although you might have</div=
>
<div style=3D"font-family: &quot;Courier New&quot;, monospace; font-size: 1=
2pt; color: rgb(0, 0, 0);">
&gt;better luck if you checkout the version from git).</div>
<div style=3D"font-family: &quot;Courier New&quot;, monospace; font-size: 1=
2pt; color: rgb(0, 0, 0);">
<br>
</div>
<div style=3D"font-family: &quot;Courier New&quot;, monospace; font-size: 1=
2pt; color: rgb(0, 0, 0);">
Actually I had tried this, I have this error when lauching ./autogen.sh:</d=
iv>
<div style=3D"font-family: &quot;Courier New&quot;, monospace; font-size: 1=
2pt; color: rgb(0, 0, 0);">
<br>
</div>
<div style=3D"font-family: &quot;Courier New&quot;, monospace; font-size: 1=
2pt; color: rgb(0, 0, 0);">
&nbsp; /THE/BUILD/DIRECTORY/aspell/gnulib/gnulib-tool.py: *** minimum suppo=
rted autoconf version is 2.64. Try adding AC_PREREQ([2.64]) to your configu=
re.ac.</div>
<div style=3D"font-family: &quot;Courier New&quot;, monospace; font-size: 1=
2pt; color: rgb(0, 0, 0);">
&nbsp; /THE/BUILD/DIRECTORY/aspell/gnulib/gnulib-tool.py: *** Stop.</div>
<div style=3D"font-family: &quot;Courier New&quot;, monospace; font-size: 1=
2pt; color: rgb(0, 0, 0);">
<br>
</div>
<div style=3D"font-family: &quot;Courier New&quot;, monospace; font-size: 1=
2pt; color: rgb(0, 0, 0);">
<br>
</div>
<div style=3D"font-family: &quot;Courier New&quot;, monospace; font-size: 1=
2pt; color: rgb(0, 0, 0);">
&gt;</div>
<div style=3D"font-family: &quot;Courier New&quot;, monospace; font-size: 1=
2pt; color: rgb(0, 0, 0);">
&gt;&gt; The other issue that I had is that Emacs ispell.el needs also to k=
now</div>
<div style=3D"font-family: &quot;Courier New&quot;, monospace; font-size: 1=
2pt; color: rgb(0, 0, 0);">
&gt;&gt; where the dictionaries are located because it builds some</div>
<div style=3D"font-family: &quot;Courier New&quot;, monospace; font-size: 1=
2pt; color: rgb(0, 0, 0);">
&gt;&gt; auto-completion list to help the user select a dictionary amongst<=
/div>
<div style=3D"font-family: &quot;Courier New&quot;, monospace; font-size: 1=
2pt; color: rgb(0, 0, 0);">
&gt;&gt; those available. To get this, Emacs ispell calls =AB aspell -vv =
=BB and</div>
<div style=3D"font-family: &quot;Courier New&quot;, monospace; font-size: 1=
2pt; color: rgb(0, 0, 0);">
&gt;&gt; expects to find something like</div>
<div style=3D"font-family: &quot;Courier New&quot;, monospace; font-size: 1=
2pt; color: rgb(0, 0, 0);">
&gt;&gt;</div>
<div style=3D"font-family: &quot;Courier New&quot;, monospace; font-size: 1=
2pt; color: rgb(0, 0, 0);">
&gt;&gt; LIBDIR =3D &quot;c:/msys64/mingw64/lib/aspell-0.60&quot;</div>
<div style=3D"font-family: &quot;Courier New&quot;, monospace; font-size: 1=
2pt; color: rgb(0, 0, 0);">
&gt;&gt;</div>
<div style=3D"font-family: &quot;Courier New&quot;, monospace; font-size: 1=
2pt; color: rgb(0, 0, 0);">
&gt;&gt; in the output, where &quot;c:/msys64/mingw64&quot; is whatever pre=
fix the user</div>
<div style=3D"font-family: &quot;Courier New&quot;, monospace; font-size: 1=
2pt; color: rgb(0, 0, 0);">
&gt;&gt; configured at install. This also does not work, so I did some hack=
</div>
<div style=3D"font-family: &quot;Courier New&quot;, monospace; font-size: 1=
2pt; color: rgb(0, 0, 0);">
&gt;&gt; which I attached.</div>
<div style=3D"font-family: &quot;Courier New&quot;, monospace; font-size: 1=
2pt; color: rgb(0, 0, 0);">
&gt;</div>
<div style=3D"font-family: &quot;Courier New&quot;, monospace; font-size: 1=
2pt; color: rgb(0, 0, 0);">
&gt;This is not a windows specific issue. &nbsp;The correct way to get this=
</div>
<div style=3D"font-family: &quot;Courier New&quot;, monospace; font-size: 1=
2pt; color: rgb(0, 0, 0);">
&gt;information from aspell is:</div>
<div style=3D"font-family: &quot;Courier New&quot;, monospace; font-size: 1=
2pt; color: rgb(0, 0, 0);">
&gt;</div>
<div style=3D"font-family: &quot;Courier New&quot;, monospace; font-size: 1=
2pt; color: rgb(0, 0, 0);">
&gt; &nbsp;aspell config dict-dir</div>
<div style=3D"font-family: &quot;Courier New&quot;, monospace; font-size: 1=
2pt; color: rgb(0, 0, 0);">
&gt;</div>
<div style=3D"font-family: &quot;Courier New&quot;, monospace; font-size: 1=
2pt; color: rgb(0, 0, 0);">
&gt;Kevin</div>
<div style=3D"font-family: &quot;Courier New&quot;, monospace; font-size: 1=
2pt; color: rgb(0, 0, 0);">
<br>
</div>
<div style=3D"font-family: &quot;Courier New&quot;, monospace; font-size: 1=
2pt; color: rgb(0, 0, 0);">
Great, when time allows I will submit a patch to Emacs ispell.el in</div>
<div style=3D"font-family: &quot;Courier New&quot;, monospace; font-size: 1=
2pt; color: rgb(0, 0, 0);">
order to fix this and use the correct way.</div>
<div style=3D"font-family: &quot;Courier New&quot;, monospace; font-size: 1=
2pt; color: rgb(0, 0, 0);">
<br>
</div>
<div style=3D"font-family: &quot;Courier New&quot;, monospace; font-size: 1=
2pt; color: rgb(0, 0, 0);">
&nbsp; V.</div>
<div id=3D"appendonsend"></div>
</body>
</html>

--_000_DBBP194MB1098674F2E080943835A16E78493ADBBP194MB1098EURP_--