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

regression: builds broken on musl #21

Closed
skeet70 opened this issue Dec 15, 2022 · 2 comments · Fixed by #22
Closed

regression: builds broken on musl #21

skeet70 opened this issue Dec 15, 2022 · 2 comments · Fixed by #22

Comments

@skeet70
Copy link
Contributor

skeet70 commented Dec 15, 2022

Apologies for only noticing/opening this now, but the change to this repo only just came into our CI systems (through the release of rust-zmq 0.10.0 and tmq consuming it once our lockfile was updated).

On a MacOS M1 Mini, running docker run -it rust:alpine3.16, with all build dependencies installed (as far as I can tell), #17 appears to have broken the build. Each master commit up to that point the testcrate builds, ex:

/zeromq-src-rs/testcrate # git checkout --recurse-submodules fb822b870ac737aa63bbdafea0182debd66d7858
Previous HEAD position was fa5c11c Cleanup previous merge (#18)
HEAD is now at fb822b8 Prepare for release 0.1.10
/zeromq-src-rs/testcrate # cargo b
    Updating crates.io index
   Compiling zeromq-src v0.1.10+4.3.2 (/zeromq-src-rs)
   Compiling testcrate v0.1.0 (/zeromq-src-rs/testcrate)
    Finished dev [unoptimized + debuginfo] target(s) in 9.35s

and each master commit after that point fails to build with this message, the same one I see upstream trying to build zmq-sys (or up the dependency chain rust-zmq -> tmq -> our binary):

/zeromq-src-rs/testcrate # git checkout --recurse-submodules c3fc02d42a928538e7d6c21f6a5816fd3b2ea4e6
Previous HEAD position was 649b49e Remove `cmake` (#17)
HEAD is now at c3fc02d Prepare for new release
/zeromq-src-rs/testcrate # cargo b
    Updating crates.io index
   Compiling zeromq-src v0.2.2+4.3.4 (/zeromq-src-rs)
   Compiling testcrate v0.1.0 (/zeromq-src-rs/testcrate)
The following warnings were emitted during compilation:

warning: In file included from /zeromq-src-rs/vendor/src/ipc_address.cpp:31:
warning: /zeromq-src-rs/vendor/src/compat.hpp:45:1: error: 'size_t strlcpy(char*, const char*, size_t)' was declared 'extern' and later 'static' [-fpermissive]
warning:    45 | strlcpy (char *dest_, const char *src_, const size_t dest_size_)
warning:       | ^~~~~~~
warning: In file included from /usr/include/fortify/string.h:22,
warning:                  from /zeromq-src-rs/vendor/src/compat.hpp:34,
warning:                  from /zeromq-src-rs/vendor/src/ipc_address.cpp:31:
warning: /usr/include/string.h:86:8: note: previous declaration of 'size_t strlcpy(char*, const char*, size_t)'
warning:    86 | size_t strlcpy (char *, const char *, size_t);
warning:       |        ^~~~~~~
warning: /zeromq-src-rs/vendor/src/ip.cpp: In function 'void zmq::set_socket_priority(zmq::fd_t, int)':
warning: /zeromq-src-rs/vendor/src/ip.cpp:233:37: warning: unused parameter 's_' [-Wunused-parameter]
warning:   233 | void zmq::set_socket_priority (fd_t s_, int priority_)
warning:       |                                ~~~~~^~
warning: /zeromq-src-rs/vendor/src/ip.cpp:233:45: warning: unused parameter 'priority_' [-Wunused-parameter]
warning:   233 | void zmq::set_socket_priority (fd_t s_, int priority_)
warning:       |                                         ~~~~^~~~~~~~~

error: failed to run custom build command for `testcrate v0.1.0 (/zeromq-src-rs/testcrate)`

Full output is available here in case it's useful. I'm going to keep looking into it to see if I can open a PR fixing it, since I'm assuming it'll be hard for you or anyone downstream to reproduce, given that no one in that chain ran into the issue.

@skeet70
Copy link
Contributor Author

skeet70 commented Dec 15, 2022

I opened a PR fixing this. I also confirmed it's an issue on all our musl builders/targets, not just our MacOS M1 ARM64 one.

@skeet70 skeet70 changed the title regression: builds broken on ARM Alpine regression: builds broken on musl Dec 15, 2022
@jean-airoldie
Copy link
Owner

Fixed as of 0.2.3

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

Successfully merging a pull request may close this issue.

2 participants