gap-packages / anupq

The ANUPQ GAP package
https://gap-packages.github.io/anupq/
Artistic License 2.0
4 stars 6 forks source link

Enforce a 32bit build resp. refuse 64bit builds? #17

Closed fingolfin closed 5 years ago

fingolfin commented 8 years ago

It seems anupq, when built in 64bit mode, may not work quite correctly. I don't have any hard evidence for this (and I did not try to get any so far), but some reports I got seem to make that plausible.

We should confirm or refute this. If confirmed, then let's collect examples where things don't work as they should in 64 bit mode. Using these, a proper fix can be developed. But until then, a workaround would be to always build anupq in 32 bit mode, even on 64 bit machines.

Of course it is also possible that nothing is wrong in 64 bit mode. In this case, this issue can just be closed.

olexandr-konovalov commented 8 years ago

Thanks - I've changed build instructions for nightly tests to use

./configure CFLAGS=-m32 LDFLAGS=-m32
make CFLAGS=-m32 LOPTS=-m32
olexandr-konovalov commented 8 years ago

This is used at the moment for 64-bit builds - see e.g. https://github.com/gap-system/gap-distribution/blob/master/testing/stable/InstPackages.sh.

fingolfin commented 8 years ago

Definitely need to do this. But then we also need to provide instructions as to how to do this. And I mean beyond passing the right flags (which coud be automated): The problem is how to tell the user to install a compiler which is 32bit enabled, as well as a version of GMP that is 32bit enabled.

On Mac OS X, the compiler is already 32bit ready, so that's fine, but getting a working GMP requires some extra work resp. documentation.

On Debian and Ubuntu, one may have to install various packages; the documentation should tell which those are. I suspect this should work (run as root / via sudo):

apt-get install libgmp-dev:i386 gcc-multilib

For other Linux distros, at least the popular ones, it would be nice to list recommendations, too. Finally, I have no idea about Windows / Cygwin in this regard.

fingolfin commented 7 years ago

I now released version 3.2 which enforces 32-bit mode for now -- but I am now less and less convinced this is needed. I'll experiment some more, and might soon release a 3.2.1 which re-enables 64-bit builds (and then adjust the anupq build routines in GAP's BuildPackages.sh

fingolfin commented 5 years ago

I just released 3.2.1, which indeed gets rid of the forced 32bit mode again. So far, all seems to work OK.