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

Build of rav1e 0.3.5 on Alpine Linux fails for aarch64 and ppc64le with bus error #2637

Closed
OTLabs opened this issue Jan 13, 2021 · 14 comments
Closed

Comments

@OTLabs
Copy link

OTLabs commented Jan 13, 2021

Build for Alpine Linux [1] fails with same error for both architectures:

365    Finished release [optimized + debuginfo] target(s) in 13m 46s
366 Bus error (core dumped)
367 >>> ERROR: rav1e: build failed

Build log for aarch64 is here [2], for ppc64le is here [3].

[1] https://gitlab.alpinelinux.org/alpine/aports/-/merge_requests/16346
[2] https://gitlab.alpinelinux.org/otlabs/aports/-/jobs/292026#L366
[3] https://gitlab.alpinelinux.org/otlabs/aports/-/jobs/283623#L369

@lu-zero
Copy link
Collaborator

lu-zero commented Jan 13, 2021

Can you please provide the stand alone command that is failing? Which kind of hardware is used to run those jobs?

@OTLabs
Copy link
Author

OTLabs commented Jan 13, 2021

Sure, with pleasure.

I use:

build() {
	cargo build --release --frozen
	cargo cbuild --release --frozen --prefix /usr
}

It is the same build procedure used to successfully build rav1e 0.3.4.

I will investigate about used hardware and comment later.

@lu-zero
Copy link
Collaborator

lu-zero commented Jan 13, 2021

So to reproduce it I'd have to run cargo cbuild (which cargo-c version?) on native power9 and aarch64?

@OTLabs
Copy link
Author

OTLabs commented Jan 13, 2021

cargo-c (0.7.0-r0) was used.

Sorry, I still have no info about hardware.

@barrbrain
Copy link
Collaborator

From the build logs:

(12/15) Installing cargo-c (0.7.0-r0)

@Ikke
Copy link

Ikke commented Jan 13, 2021

Running this on our CI host (qemu) as our builders (LXC on baremetal) results in the same:

Program received signal SIGILL, Illegal instruction.
0x0000fffff7be64d0 in ?? () from /usr/bin/../lib/libcrypto.so.1.1

Our aarch64 builder runs on Ampere eMAG servers, but as this seems to happen on both qemu as baremetal, it does not seem to be hardware related.

@lu-zero
Copy link
Collaborator

lu-zero commented Jan 13, 2021

It seems that the openssl provider is doing something fishy.

@Ikke
Copy link

Ikke commented Jan 13, 2021

It's strange though that we get a SIGBUS normally, and a SIGILL when running under gdb.

@lu-zero
Copy link
Collaborator

lu-zero commented Mar 30, 2021

Can you confirm that the current cargo-c release does not show the problem?

@OTLabs
Copy link
Author

OTLabs commented Mar 30, 2021

Currently rav1e 0.4.0 was built with cago-c 0.7.1 without any problem.

@OTLabs
Copy link
Author

OTLabs commented Apr 2, 2021

Tried to build rav1e 0.4.1 with cargo-c 0.8.0 and got no any .so libraries built. I was expecting to get: librav1e.so.0 and librav1e.so.0.4.1.

@lu-zero
Copy link
Collaborator

lu-zero commented Apr 2, 2021

Could you please open an issue on cargo-c ? I think it is due how the musl target is managed, if you want shared libraries on a musl-based distribution it requires probably some cli overrides.

@OTLabs
Copy link
Author

OTLabs commented Apr 2, 2021

Done! lu-zero/cargo-c#180

@OTLabs
Copy link
Author

OTLabs commented Apr 4, 2021

rav1e 0.4.1 with cargo-c 0.8.0 builds as expected with --library-type staticlib --library-type cdylib.

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

No branches or pull requests

5 participants