Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 854162 - [guru] dev-lang/harec-0_pre20220624 fails to compile: check.c:3231:17: error: -Werror=maybe-uninitialized
Summary: [guru] dev-lang/harec-0_pre20220624 fails to compile: check.c:3231:17: error:...
Status: RESOLVED FIXED
Alias: None
Product: GURU
Classification: Unclassified
Component: Package issues (show other bugs)
Hardware: All Linux
: Normal normal
Assignee: Haelwenn (lanodan) Monnier
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2022-06-25 06:41 UTC by Agostino Sarubbo
Modified: 2022-06-28 15:38 UTC (History)
1 user (show)

See Also:
Package list:
Runtime testing required: ---


Attachments
build.log (build.log,43.42 KB, text/plain)
2022-06-25 06:41 UTC, Agostino Sarubbo
Details
Fix compilation error from uninitialized variable (fix-O2.patch,343 bytes, patch)
2022-06-28 15:35 UTC, Christopher Steward
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Agostino Sarubbo gentoo-dev 2022-06-25 06:41:19 UTC
https://blogs.gentoo.org/ago/2020/07/04/gentoo-tinderbox/

Issue: dev-lang/harec-0_pre20220624 fails to compile.
Discovered on: amd64 (internal ref: guru_ci)
Comment 1 Agostino Sarubbo gentoo-dev 2022-06-25 06:41:21 UTC
Created attachment 787469 [details]
build.log

build log and emerge --info
Comment 2 Christopher Steward 2022-06-28 15:35:10 UTC
Created attachment 788510 [details, diff]
Fix compilation error from uninitialized variable

I believe this is due to using optimizing compiler flags as it doesn't happen with the default flags from upstream but does when building with emerge.

I was able to fix it with a simple patch assign NULL to the variable "flag" in the default label of the switch in the "check_function" function. I don't think this should change any behaviour of the code since the variable was uninitialized in that case anyway.
Comment 3 Larry the Git Cow gentoo-dev 2022-06-28 15:38:36 UTC
The bug has been closed via the following commit(s):

https://gitweb.gentoo.org/repo/proj/guru.git/commit/?id=d2a1cda96e2a7d809d6b3ec53cf6312aeb2e394f

commit d2a1cda96e2a7d809d6b3ec53cf6312aeb2e394f
Author:     Haelwenn (lanodan) Monnier <contact@hacktivis.me>
AuthorDate: 2022-06-27 02:55:30 +0000
Commit:     Haelwenn (lanodan) Monnier <contact@hacktivis.me>
CommitDate: 2022-06-27 02:56:24 +0000

    dev-lang/harec: Remove -Werror
    
    Closes: https://bugs.gentoo.org/854162
    Signed-off-by: Haelwenn (lanodan) Monnier <contact@hacktivis.me>

 dev-lang/harec/harec-0_pre20220624.ebuild | 6 ++++++
 dev-lang/harec/harec-9999.ebuild          | 6 ++++++
 2 files changed, 12 insertions(+)