Skip to content

Configure fails for emscripten/wasm build with 3.2.0-rc1 #2247

@oscarbenjamin

Description

@oscarbenjamin

Building FLINT for wasm fails with 3.2.0-rc1 although it previously worked for 3.1. The build fails to configure with:

checking if system can use FLINT's fft_small module... no
configure: WARNING: Currently no assembly available for 32-bit systems. Disabling assembly...
checking how to switch to text section... .text
configure: error: Cannot determine label suffix
emconfigure: error: './configure --disable-dependency-tracking --disable-shared --prefix=/home/runner/work/python-flint/python-flint/wasm-library-dir --with-gmp=/home/runner/work/python-flint/python-flint/wasm-library-dir --with-mpfr=/home/runner/work/python-flint/python-flint/wasm-library-dir' failed (returned 1)
checking for assembler label suffix... 

The configure script tries to determine the label suffix for assembly code but the assembly code cannot be used on wasm as it is only for x86_64 and arm64. I guess ideally configure would fall back on not using assembly here rather than erroring out.

To reproduce this first install emscripten (e.g.. sudo apt-get install emscripten) and then build GMP, MPFR and FLINT but using emconfigure and emmake instead of ./configure and make. I haven't actually tested these steps myself but you can see the commands in the CI job at https://github.com/flintlib/python-flint/pull/262/files.

This comes from flintlib/python-flint#262 (comment) which is trying to build python-flint with the latest version of FLINT to run in the browser.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions