Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 949567 - net-analyzer/ippl-1.4.14-r7 - [meson] [gcc-15] [ffmpeg] configuration.c: error: type of last_message does not match original declaration [-Werror=lto-type-mismatch]
Summary: net-analyzer/ippl-1.4.14-r7 - [meson] [gcc-15] [ffmpeg] configuration.c: erro...
Status: CONFIRMED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: Normal normal
Assignee: Gentoo Netmon project
URL:
Whiteboard:
Keywords: PATCH
Depends on:
Blocks: lto
  Show dependency tree
 
Reported: 2025-02-10 17:26 UTC by Toralf Förster
Modified: 2025-02-12 14:33 UTC (History)
2 users (show)

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


Attachments
emerge-info.txt (emerge-info.txt,19.59 KB, text/plain)
2025-02-10 17:26 UTC, Toralf Förster
Details
emerge-history.txt (emerge-history.txt,200.69 KB, text/plain)
2025-02-10 17:26 UTC, Toralf Förster
Details
environment (environment,68.18 KB, text/plain)
2025-02-10 17:26 UTC, Toralf Förster
Details
etc.clang.tar.xz (etc.clang.tar.xz,1.20 KB, application/x-xz)
2025-02-10 17:26 UTC, Toralf Förster
Details
etc.portage.tar.xz (etc.portage.tar.xz,22.88 KB, application/x-xz)
2025-02-10 17:26 UTC, Toralf Förster
Details
logs.tar.xz (logs.tar.xz,4.25 KB, application/x-xz)
2025-02-10 17:26 UTC, Toralf Förster
Details
net-analyzer:ippl-1.4.14-r7:20250210-121047.log (net-analyzer:ippl-1.4.14-r7:20250210-121047.log,15.40 KB, text/plain)
2025-02-10 17:26 UTC, Toralf Förster
Details
qlist-info.txt.xz (qlist-info.txt.xz,56.62 KB, application/x-xz)
2025-02-10 17:26 UTC, Toralf Förster
Details
temp.tar.xz (temp.tar.xz,17.55 KB, application/x-xz)
2025-02-10 17:26 UTC, Toralf Förster
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Toralf Förster gentoo-dev 2025-02-10 17:26:34 UTC
lex.yy.c:1911:17: warning: yyunput defined but not used [-Wunused-function]
 1911 | 
      |                 ^      
make[1]: Leaving directory '/var/tmp/portage/net-analyzer/ippl-1.4.14-r7/work/ippl-1.4.14/Source'
make[1]: Entering directory '/var/tmp/portage/net-analyzer/ippl-1.4.14-r7/work/ippl-1.4.14/Source'
x86_64-pc-linux-gnu-gcc -Wl,-O1 -Wl,--as-needed -Wl,-z,pack-relative-relocs -Wl,--defsym=__gentoo_check_ldflags__=0 -Werror=lto-type-mismatch -Werror=strict-aliasing -Werror=odr -flto -o ippl main.o configuration.o icmp.o tcp.o udp.o log.o netutils.o filter.o y.tab.o lex.yy.o pidfile.o ident.o -lpthread
configuration.c:70:16: error: type of last_message does not match original declaration [-Werror=lto-type-mismatch]
   70 |   extern char *last_message;
      |                ^

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

  This is an unstable amd64 chroot image at a tinderbox (==build bot)
  name: 23.0_desktop_systemd-20250205-213502

  UNMASKED:

    Requested by sam
  =media-video/ffmpeg-7*

    
  <sys-devel/gcc-15.0.9999:15

    Please re-assign to ztrawhcse@ if you cannot reproduced it with regular meson.
  <dev-build/meson-9999

  The attached etc.portage.tar.xz has all details.
  -------------------------------------------------------------------

gcc-config -l:
 [1] x86_64-pc-linux-gnu-15 *
clang version 19.1.7
llvm-config: 19.1.7
Python 3.12.9
go version go1.23.6 linux/amd64
  [1]   php8.2 *
  [2]   php8.3
Available Ruby profiles:
  (none found)
Available Rust versions:
  [1]   rust-bin-1.84.1
  [2]   rust-1.84.1 *
The following VMs are available for generation-2:
1)	Eclipse Temurin JDK 11.0.26_p4 [openjdk-bin-11]
2)	Eclipse Temurin JDK 17.0.14_p7 [openjdk-bin-17]
*)	Eclipse Temurin JDK 21.0.6_p7 [openjdk-bin-21]
4)	Eclipse Temurin JDK 8.442_p06 [openjdk-bin-8]
Available Java Virtual Machines:
  [1]   openjdk-bin-8 
  [2]   openjdk-bin-11 
  [3]   openjdk-bin-17 
  [4]   openjdk-bin-21  system-vm


  HEAD of ::gentoo
commit 98096175d748563f29c88b30e7fa1a026717c7c3
Author: Repository mirror & CI <repomirrorci@gentoo.org>
Date:   Mon Feb 10 10:18:44 2025 +0000

    2025-02-10 10:18:44 UTC

emerge -qpvO =net-analyzer/ippl-1.4.14-r7
[ebuild  N    ] net-analyzer/ippl-1.4.14-r7
Comment 1 Toralf Förster gentoo-dev 2025-02-10 17:26:35 UTC
Created attachment 918550 [details]
emerge-info.txt
Comment 2 Toralf Förster gentoo-dev 2025-02-10 17:26:36 UTC
Created attachment 918551 [details]
emerge-history.txt
Comment 3 Toralf Förster gentoo-dev 2025-02-10 17:26:38 UTC
Created attachment 918552 [details]
environment
Comment 4 Toralf Förster gentoo-dev 2025-02-10 17:26:38 UTC
Created attachment 918553 [details]
etc.clang.tar.xz
Comment 5 Toralf Förster gentoo-dev 2025-02-10 17:26:39 UTC
Created attachment 918554 [details]
etc.portage.tar.xz
Comment 6 Toralf Förster gentoo-dev 2025-02-10 17:26:40 UTC
Created attachment 918555 [details]
logs.tar.xz
Comment 7 Toralf Förster gentoo-dev 2025-02-10 17:26:41 UTC
Created attachment 918556 [details]
net-analyzer:ippl-1.4.14-r7:20250210-121047.log
Comment 8 Toralf Förster gentoo-dev 2025-02-10 17:26:42 UTC
Created attachment 918557 [details]
qlist-info.txt.xz
Comment 9 Toralf Förster gentoo-dev 2025-02-10 17:26:43 UTC
Created attachment 918558 [details]
temp.tar.xz
Comment 10 Holger Hoffstätte 2025-02-12 14:33:04 UTC
As mentioned on IRC:

The only uses of last_message in configuration.c are to initialize the buffer with a terminating null. It seems much easier to move the initialization to log.c and just remove the declaration/initialization from configuration.c.
As there is already an initialisation of the buffer in log.c all that's needed is to zap the two unnecessary lines:

---snip---
$diff -up Source/configuration.c~ Source/configuration.c
--- Source/configuration.c~	2025-02-12 15:27:14.000000000 +0100
+++ Source/configuration.c	2025-02-12 15:27:43.977766801 +0100
@@ -67,7 +67,6 @@ void set_default_values() {
   extern unsigned short log_closing;
   extern unsigned short use_ident;
   extern unsigned int repeats;
-  extern char *last_message;
 
   dns_expire = DNS_EXPIRE;
   log_protocols = NONE;
@@ -79,7 +78,6 @@ void set_default_values() {
   log_closing = FALSE;
   use_ident = FALSE;
   repeats = 0;
-  last_message = '\0';
 }
 
 void parse_config_file(char *filename) {
---snip---

Now builds with LTO and works fine.