outguess: fix build

outguess does not build with the current version of GCC.
Added a postPatch to remove K&R-style function declarations.
Package now compiles but has otherwise been minimally tested.
This commit is contained in:
Mathtician
2026-01-21 13:14:19 -06:00
parent accc3b4eff
commit 63259895e5
+11
View File
@@ -22,6 +22,17 @@ stdenv.mkDerivation (finalAttrs: {
configureFlags = [ "--with-generic-jconfig" ];
# Fix build with modern compilers (GCC 14+)
# The bundled jpeg-6b-steg library uses K&R-style function declarations
# that are incompatible with modern C standards
postPatch = ''
substituteInPlace src/jpeg-6b-steg/jmorecfg.h \
--replace-fail '#define JMETHOD(type,methodname,arglist) type (*methodname) ()' \
'#define JMETHOD(type,methodname,arglist) type (*methodname) arglist'
substituteInPlace src/jpeg-6b-steg/jpeglib.h \
--replace-fail '#ifdef HAVE_PROTOTYPES' '#if 1 /* Force ANSI prototypes */'
'';
meta = {
description = "Universal steganographic tool that allows the insertion of hidden information into the redundant bits of data sources";
homepage = "https://github.com/resurrecting-open-source-projects/outguess";