mirror of
https://github.com/luanti-org/luanti.git
synced 2025-06-27 16:36:03 +00:00
Enable IPO/LTO by default except for debug builds (#14198)
Test case: ``` $ cmake . -DRUN_IN_PLACE=TRUE -DCMAKE_BUILD_TYPE=Release -DBUILD_SERVER=TRUE -DENABLE_TOUCH=FALSE minetest minetestserver W/o LTO: 13M 7.3M W/ LTO: 11M 5.9M difference: 15% 19% ``` Also fixes various compiler warnings resulting from compilation using LTO. --------- Signed-off-by: David Heidelberg <david@ixit.cz>
This commit is contained in:
parent
adaa4cc2f3
commit
eb52a149a0
7 changed files with 49 additions and 33 deletions
|
@ -734,7 +734,7 @@ static void fillTileAttribs(ITextureSource *tsrc, TileLayer *layer,
|
|||
int frame_count = 1;
|
||||
if (layer->material_flags & MATERIAL_FLAG_ANIMATION) {
|
||||
assert(layer->texture);
|
||||
int frame_length_ms;
|
||||
int frame_length_ms = 0;
|
||||
tiledef.animation.determineParams(layer->texture->getOriginalSize(),
|
||||
&frame_count, &frame_length_ms, NULL);
|
||||
layer->animation_frame_count = frame_count;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue