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

Skip protoc execution when tests are skipped #2530

Closed
shakuzen opened this issue Apr 23, 2019 · 4 comments · Fixed by #2532
Closed

Skip protoc execution when tests are skipped #2530

shakuzen opened this issue Apr 23, 2019 · 4 comments · Fixed by #2532

Comments

@shakuzen
Copy link
Member

We tried to use Jitpack to test a build of the Zipkin Server from a pull request (#2328), but the build failed with the following.

https://jitpack.io/com/github/ewhauser/zipkin/experimental-grpc-1.5.0-g7a0c3ce-1160/build.log

[INFO] --- protobuf-maven-plugin:0.6.1:test-compile (test-compile-proto) @ zipkin-server ---
[INFO] Compiling 1 proto file(s) to /home/jitpack/build/zipkin-server/target/generated-test-sources/protobuf/java
[ERROR] PROTOC FAILED: /home/jitpack/build/zipkin-server/target/protoc-plugins/protoc-3.7.0-linux-x86_64.exe: error while loading shared libraries: libatomic.so.1: cannot open shared object file: No such file or directory

[ERROR] /home/jitpack/build/zipkin-server/target/test/proto/zipkin.proto [0:0]: /home/jitpack/build/zipkin-server/target/protoc-plugins/protoc-3.7.0-linux-x86_64.exe: error while loading shared libraries: libatomic.so.1: cannot open shared object file: No such file or directory

Since this protoc execution is only for tests and the build is skipping tests, we should be able to disable it when tests are skipped so Jitpack succeeds. This can probably be done in a Maven profile.
Alternatively, we can customize the command Jitpack uses to build, but I do like it working out-of-the-box (as it did before the pull request added GRPC collector support) and I wonder if Zipkin developers wouldn't also run into this problem on their machines.
/cc @bsideup

@anuraaga
Copy link
Contributor

For reference, the libatomic dependency will go away in the next release of protoc I believe

protocolbuffers/protobuf#5875

@shakuzen
Copy link
Member Author

Thanks for the heads up. That's good to know.
@jorgheymans also mentioned that using -Dmaven.test.skip=true should skip compiling tests.

codefromthecrypt pushed a commit that referenced this issue Apr 23, 2019
Square Wire is a lot simpler setup, and it doesn't require installation
of binaries to compile proto files. This helps us and also anyone who
will be doing ASF source verification.

Fixes #2530
@codefromthecrypt
Copy link
Member

@codefromthecrypt
Copy link
Member

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

Successfully merging a pull request may close this issue.

3 participants