Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

openfst fails to compile on i686 #4808

Closed
johngebbie opened this issue Nov 15, 2022 · 5 comments
Closed

openfst fails to compile on i686 #4808

johngebbie opened this issue Nov 15, 2022 · 5 comments
Labels

Comments

@johngebbie
Copy link

Hello, I'm trying to package my program which uses Vosk which is built upon Kaldi.
I also need to package openfst which is what is giving me trouble.

Openfst compiles just fine on my x86_64 machine, and even cross compiling to i686, but a test fails in the continuous integration when compiling i686 natively.

It is the float equality from the ./configure file which runs during the install phase (it's run again during the check phase).

This is the output of the build system:

configure: error: Test float equality failed! Compile with -msse -mfpmath=sse if using g++.
See `config.log' for more details
=> ERROR: vosk-api-0.3.43_1: pre_build: './configure --host="${XBPS_TRIPLET}" ${CROSS_BUILD:+--host="${XBPS_CROSS_TRIPLET}"} --build="${XBPS_TRIPLET}" --prefix="${wrksrc}/kaldi-${_kaldi_commit}/tools/openfst" --enable-static --enable-shared --enable-far --enable-ngram-fsts --enable-lookahead-fsts --with-pic --disable-bin' exited with 1
=> ERROR:   in pre_build() at srcpkgs/vosk-api/template:57

I have tried adding the options it suggests and some, but I get the same error.

I think it passes when cross compiling because it's actually testing my x86_64.
That said, I'm concerned about the underlying float equality issue on i686, even if I skip the test when cross compiling.

I asked the Vosk developer here but didn't get anywhere:
alphacep/vosk-api#1161

This is my build template for Void Linux:
void-linux/void-packages#39015

This is someone elses build template for Alpine Linux:
https://gitlab.alpinelinux.org/alpine/aports/-/merge_requests/41097
I see they have had the same issue and limited the architectures to 64 bit.

I will only target 64 bit architectures if necessary, but I'd be shame, my program seems to work well on my old i686 laptop when cross compiled.

Any thoughts? Is this a build issue or are 32 bit architectures not supported?

Thank you. Sorry this is more an openfst issue than a kaldi one but I saw you had accepted similar issues, and openfst doesn't seem to have a good place for issues.

@johngebbie johngebbie added the bug label Nov 15, 2022
@nshmyrev
Copy link
Contributor

As we discussed in the issue you linked, you can build for 32-bit but you need to cross-compile. And you need to disable runtime checks.

@johngebbie
Copy link
Author

johngebbie commented Nov 21, 2022

Sorry @nshmyrev, I was unsure because you said it was a technical limitation of memory space, but it does compile natively on i686 as long as I remove the float equality tests.
Do you think it's safe to patch out the float equality tests so it compiles natively?

Only cross-compiling does not seem to be a template option in the xbps-src build system, and precompiled binaries are not accepted.

@stale
Copy link

stale bot commented Jan 21, 2023

This issue has been automatically marked as stale by a bot solely because it has not had recent activity. Please add any comment (simply 'ping' is enough) to prevent the issue from being closed for 60 more days if you believe it should be kept open.

@stale stale bot added the stale Stale bot on the loose label Jan 21, 2023
@johngebbie
Copy link
Author

ping. Because of this the void linux and the upcoming alipine packages of vosk and numen are limited to x86_64 and aarch64.

@stale stale bot removed the stale Stale bot on the loose label Jan 25, 2023
@jtrmal
Copy link
Contributor

jtrmal commented Jan 25, 2023 via email

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants