flavorjones / mini_portile

mini_portile and mini_portile2 - Simple autoconf and cmake builder for developers
MIT License
114 stars 51 forks source link

Create release binary with cmake explicitly #136

Closed Watson1978 closed 11 months ago

Watson1978 commented 11 months ago

When I built library with the default setting, its compilation has no optimized in my environment. I want it has release binary by default.

Ref. https://cmake.org/cmake/help/latest/variable/CMAKE_BUILD_TYPE.html

flavorjones commented 11 months ago

@Watson1978 Thank you for submitting this pull request and updating the tests!

I'm not a CMake user, so I want to check with one other person who's contributed improvements to CMake: @stanhu what do you think of default to Release? Should we provide the ability to configure that setting?

stanhu commented 11 months ago

Default to Release sounds reasonable. It appears that this shrinks the re2 gem .so from 2766744 bytes to 1506992 bytes.

It would be nice to configure this in order to see backtraces, but I suppose that could also be done by adding CMAKE_BUILD_TYPE since I think the last value specified wins.

flavorjones commented 11 months ago

@stanhu Thanks for the fast feedback. I'm going to add a config param / env var override like mini_portile already provides for the cmake command.

flavorjones commented 11 months ago

@stanhu @Watson1978 would love feedback on the commit I appended

stanhu commented 11 months ago

Looks good to me, thanks!

Watson1978 commented 11 months ago

@flavorjones Thank you for your improvement. Looks good to me!

flavorjones commented 11 months ago

I'll make time to cut a release in the next day or two.

Watson1978 commented 11 months ago

thanks!!

stanhu commented 11 months ago

@flavorjones Thanks for this! Could you cut a release?

flavorjones commented 11 months ago

@stanhu Thanks for the poke. I'm traveling this week and it's been challenging to find time. I delayed because I was nervous about the not-fully baked pkgconfig feature on main, but will just pull the trigger. Expect a release tomorrow.

stanhu commented 11 months ago

I delayed because I was nervous about the not-fully baked pkgconfig feature on main, but will just pull the trigger.

I'll take a look in the context of https://github.com/mudge/re2/issues/109.

flavorjones commented 10 months ago

@stanhu Cut Release 2.8.5 / 2023-10-22 · flavorjones/mini_portile