Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!

Bug 875506

Summary: dev-util/yacc-1.9.1-r7 - closure.c: error: type specifier missing, defaults to int; ISO C99 and
Product: Gentoo Linux Reporter: Toralf Förster <toralf>
Component: Current packagesAssignee: No maintainer - Look at https://wiki.gentoo.org/wiki/Project:Proxy_Maintainers if you want to take care of it <maintainer-needed>
Status: RESOLVED FIXED    
Severity: normal CC: seal331gentoo
Priority: Normal    
Version: unspecified   
Hardware: All   
OS: Linux   
Whiteboard: fixed in 1.9.1-r8
Package list:
Runtime testing required: ---
Bug Depends on:    
Bug Blocks: 870412    
Attachments: emerge-info.txt
dev-util:yacc-1.9.1-r6:20221005-174305.log
emerge-history.txt
environment
etc.portage.tar.bz2
temp.tar.bz2
C99 patch

Description Toralf Förster gentoo-dev 2022-10-05 18:15:58 UTC
make -j4 clean 
rm yacc
make -j4 CC=clang 'CFLAGS=-pipe -march=native -fno-diagnostics-color -O2 -Werror=implicit-function-declaration -Werror=implicit-int' 
clang -pipe -march=native -fno-diagnostics-color -O2 -Werror=implicit-function-declaration -Werror=implicit-int -Wl,-O1 -Wl,--as-needed -Wl,--defsym=__gentoo_check_ldflags__=0 -o yacc closure.c error.c lalr.c lr0.c main.c mkpar.c output.c reader.c skeleton.c symtab.c verbose.c warshall.c
closure.c:15:1: error: type specifier missing, defaults to 'int'; ISO C99 and
      later do not support implicit int [-Werror,-Wimplicit-int]
set_EFF()

  -------------------------------------------------------------------

  This is an unstable amd64 chroot image at a tinderbox (==build bot)
  name: 17.1-j4-20221005-091815

  -------------------------------------------------------------------

gcc-config -l:
 [1] x86_64-pc-linux-gnu-12.2.0 *
clang/llvm (if any):
clang version 15.0.2
Target: x86_64-pc-linux-gnu
Thread model: posix
InstalledDir: /usr/lib/llvm/15/bin
Configuration file: /etc/clang/clang.cfg
/usr/lib/llvm/15
15.0.2
Python 3.10.7
Available Rust versions:
  [1]   rust-bin-1.64.0 *
The Glorious Glasgow Haskell Compilation System, version 9.0.2
php cli (if any):
GNU Make 4.3

  HEAD of ::gentoo
commit 6f6c428a48fa244afc99865a8904c6020960703f
Author: Repository mirror & CI <repomirrorci@gentoo.org>
Date:   Wed Oct 5 16:19:00 2022 +0000

    2022-10-05 16:18:59 UTC

emerge -qpvO dev-util/yacc
[ebuild  N    ] dev-util/yacc-1.9.1-r6
Comment 1 Toralf Förster gentoo-dev 2022-10-05 18:15:59 UTC
Created attachment 821569 [details]
emerge-info.txt
Comment 2 Toralf Förster gentoo-dev 2022-10-05 18:16:01 UTC
Created attachment 821572 [details]
dev-util:yacc-1.9.1-r6:20221005-174305.log
Comment 3 Toralf Förster gentoo-dev 2022-10-05 18:16:02 UTC
Created attachment 821575 [details]
emerge-history.txt
Comment 4 Toralf Förster gentoo-dev 2022-10-05 18:16:03 UTC
Created attachment 821578 [details]
environment
Comment 5 Toralf Förster gentoo-dev 2022-10-05 18:16:04 UTC
Created attachment 821581 [details]
etc.portage.tar.bz2
Comment 6 Toralf Förster gentoo-dev 2022-10-05 18:16:05 UTC
Created attachment 821584 [details]
temp.tar.bz2
Comment 7 Sam James archtester Gentoo Infrastructure gentoo-dev Security 2022-11-20 20:56:11 UTC
*** Bug 882297 has been marked as a duplicate of this bug. ***
Comment 8 Agostino Sarubbo gentoo-dev 2023-12-30 09:45:24 UTC
gcc14_tinderbox has reproduced this issue with version 1.9.1-r7 - Updating summary.
Comment 9 Vladislav Dudar 2024-07-31 17:49:58 UTC
Created attachment 898709 [details, diff]
C99 patch

Wrote a patch to fix this and quite likely #730802. Purely converting K&R declarations to ANSI C, this was easy. Tested with GCC 13 + C99 porting flags, for me gets rid of all warnings and errors except 3 "ignoring return value of mkstemp" warnings.
Comment 10 Larry the Git Cow gentoo-dev 2024-10-20 17:30:04 UTC
The bug has been closed via the following commit(s):

https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=9e9f43129927504a22efd67e1ff1320d55d84a56

commit 9e9f43129927504a22efd67e1ff1320d55d84a56
Author:     Arthur Zamarin <arthurzam@gentoo.org>
AuthorDate: 2024-10-20 17:29:14 +0000
Commit:     Arthur Zamarin <arthurzam@gentoo.org>
CommitDate: 2024-10-20 17:29:48 +0000

    dev-util/yacc: fix modern C
    
    Closes: https://bugs.gentoo.org/875506
    Closes: https://bugs.gentoo.org/730802
    Signed-off-by: Arthur Zamarin <arthurzam@gentoo.org>

 dev-util/yacc/Manifest                                       |  1 +
 dev-util/yacc/{yacc-1.9.1-r7.ebuild => yacc-1.9.1-r8.ebuild} | 10 ++++++++--
 2 files changed, 9 insertions(+), 2 deletions(-)