Skip to content

set optimize mode and strip options #170

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

Merged
merged 2 commits into from
Feb 14, 2025
Merged

set optimize mode and strip options #170

merged 2 commits into from
Feb 14, 2025

Conversation

ivansantiagojr
Copy link
Contributor

Changes

  • Adds a preferred_optimize_mode to zigup binary;
  • Adds a strip = true option to zigup binary;

Result

These changes builds significantly smaller binary with no debug info (more suited to end users) when project is built with zig build --release.
image
note: this image is in text form on issue #169.

Todo

Fix GitHub Actions workflow to build and upload new files.

closes #169

@marler8997
Copy link
Owner

marler8997 commented Feb 14, 2025

strange we got a 404 downloading one of the packages:

error: could not download 'https://ziglang.org/builds/zig-linux-x86_64-0.14.0-dev.2465+70de2f3a7.tar.xz': the HTTP server replied with unsuccessful response '404 Not Found'

probably a temporary problem (looks like it's working now on master: https://github.com/marler8997/zigup/actions/runs/13330938692)

Other problem is the CI is looking for the PDB on windows. We could exclude the PDB but is there a way we can still keep it around?

error: path 'zigup.pdb' is not found

@ivansantiagojr
Copy link
Contributor Author

I think this is happening due to the strip option, I am not very familiar with windows, but from what I have searched, a .pdb is a file that holds debug information, right? And since the stripping process removes debug info, it might be it.

If keeping debugging information on windows is useful, we could set strip to false when build target is windows, what do you think?

@marler8997
Copy link
Owner

marler8997 commented Feb 14, 2025

From a cursory look it looks like setting strip to true means no pdb. That's ok though, not a big deal. I've pushed a commit to your branch that removes the PDB, we'll see how the CI does with it.

@ivansantiagojr
Copy link
Contributor Author

Since the CI seems to be working fine now, I will mark the PR as ready for review, and then if anything new seems wrong, we can keep working on it!

@ivansantiagojr ivansantiagojr marked this pull request as ready for review February 14, 2025 20:37
@marler8997 marler8997 merged commit 3d05f30 into marler8997:master Feb 14, 2025
3 checks passed
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 this pull request may close these issues.

Release binaries with debug info and not stripped
2 participants