Mailing List Archive

1.9.1 build error (cross-build for Windows)
Hello,

1.9.1 does not cross-build for Windows (on Linux):

libtool: compile: i686-w64-mingw32-gcc -DHAVE_CONFIG_H -I. -I../../random -I.. -I../src -I../../src -I/usr/i686-w64-mingw32/include -g -O0 -fno-delete-null-pointer-checks -Wall -c ../../random/rndjent.c -DDLL_EXPORT -DPIC -o .libs/rndjent.o
../../random/rndjent.c: In function 'is_rng_available':
../../random/rndjent.c:240:40: error: 'HWF_INTEL_RDTSC' undeclared (first use in this function)

libgcrypt is configureed with:
LDFLAGS="-Xlinker --no-insert-timestamp" CFLAGS="-g -Os" CPPFLAGS= ../configure \
--prefix=/usr/i686-w64-mingw32 \
--with-libgpg-error-prefix=/usr/i686-w64-mingw32 \
--disable-padlock-support --disable-asm \
--enable-static \
--host i686-w64-mingw32
[...]
configure:16746: checking architecture and mpi assembler functions
configure:16753: result: disabled
[...]


cu Andreas
--
`What a good friend you are to him, Dr. Maturin. His other friends are
so grateful to you.'
`I sew his ears on from time to time, sure'

_______________________________________________
Gcrypt-devel mailing list
Gcrypt-devel@gnupg.org
http://lists.gnupg.org/mailman/listinfo/gcrypt-devel
Re: 1.9.1 build error (cross-build for Windows) [ In reply to ]
Hello,

On 29.1.2021 21.23, Andreas Metzler wrote:
> Hello,
>
> 1.9.1 does not cross-build for Windows (on Linux):
>
> libtool: compile: i686-w64-mingw32-gcc -DHAVE_CONFIG_H -I. -I../../random -I.. -I../src -I../../src -I/usr/i686-w64-mingw32/include -g -O0 -fno-delete-null-pointer-checks -Wall -c ../../random/rndjent.c -DDLL_EXPORT -DPIC -o .libs/rndjent.o
> ../../random/rndjent.c: In function 'is_rng_available':
> ../../random/rndjent.c:240:40: error: 'HWF_INTEL_RDTSC' undeclared (first use in this function)
>
> libgcrypt is configureed with:
> LDFLAGS="-Xlinker --no-insert-timestamp" CFLAGS="-g -Os" CPPFLAGS= ../configure \
> --prefix=/usr/i686-w64-mingw32 \
> --with-libgpg-error-prefix=/usr/i686-w64-mingw32 \
> --disable-padlock-support --disable-asm \
> --enable-static \
> --host i686-w64-mingw32
> [...]
> configure:16746: checking architecture and mpi assembler functions
> configure:16753: result: disabled
> [...]
>

Building with --disable-asm is broken in 1.9.1. You can try building without --disable-asm or trying attached patch.

Sorry for the inconvenience.

-Jussi

>
> cu Andreas
>
Re: 1.9.1 build error (cross-build for Windows) [ In reply to ]
On Fri, 29 Jan 2021 20:23, Andreas Metzler said:

> 1.9.1 does not cross-build for Windows (on Linux):

Actually Windows is our mayor test platform and cross compiling is
mandatory for this. Please use the standard options and don't invent
your own:

./autogen.sh --build-w32

or

./autogen.sh --build-w64

is the correct way to run configure.


Salam-Shalom,

Werner

--
Die Gedanken sind frei. Ausnahmen regelt ein Bundesgesetz.
Re: 1.9.1 build error (cross-build for Windows) [ In reply to ]
On 2021-01-30 Jussi Kivilinna <jussi.kivilinna@iki.fi> wrote:
> On 29.1.2021 21.23, Andreas Metzler wrote:
> > 1.9.1 does not cross-build for Windows (on Linux):
[...]
> Building with --disable-asm is broken in 1.9.1. You can try building without --disable-asm or trying attached patch.
[...]

Thank you for providing a workaround immediately. Works for me.

cu Andreas

_______________________________________________
Gcrypt-devel mailing list
Gcrypt-devel@gnupg.org
http://lists.gnupg.org/mailman/listinfo/gcrypt-devel
Re: 1.9.1 build error (cross-build for Windows) [ In reply to ]
On 2021-01-30 Werner Koch <wk@gnupg.org> wrote:
> On Fri, 29 Jan 2021 20:23, Andreas Metzler said:

> > 1.9.1 does not cross-build for Windows (on Linux):

> Actually Windows is our mayor test platform and cross compiling is
> mandatory for this. Please use the standard options and don't invent
> your own:

> ./autogen.sh --build-w32

> or

> ./autogen.sh --build-w64

> is the correct way to run configure.
[...]

Hello,

I cannot use that since I need an out-of-tree-build. Looking at how
./configure is invoked by the abovementioned command

--enable-maintainer-mode --prefix=/home/ametzler/w32root --host=i686-w64-mingw32 --build=x86_64-pc-linux-gnu SYSROOT=/home/ametzler/w32root PKG_CONFIG_LIBDIR=/home/ametzler/w32root/lib/pkgconfig

I will test with simpler ./configure flags (host/build/prefix), letting
upstream choose optimization and assembly enablement.

cu Andreas
--
`What a good friend you are to him, Dr. Maturin. His other friends are
so grateful to you.'
`I sew his ears on from time to time, sure'

_______________________________________________
Gcrypt-devel mailing list
Gcrypt-devel@gnupg.org
http://lists.gnupg.org/mailman/listinfo/gcrypt-devel
Re: 1.9.1 build error (cross-build for Windows) [ In reply to ]
On Sun, 31 Jan 2021 14:24, Andreas Metzler said:

> I cannot use that since I need an out-of-tree-build. Looking at how
> ./configure is invoked by the abovementioned command

../../src/libgcrypt/autogen.sh --build-w32

works as well - after all it is just a wrapper around configure. But of
course you can also use the configure options provided by autogen.sh
directly wth configure.


Shalom-Salam,

Werner

--
Die Gedanken sind frei. Ausnahmen regelt ein Bundesgesetz.