om4: fix build on GCC 14
This commit is contained in:
@@ -0,0 +1,14 @@
|
||||
Index: a/parser.y
|
||||
===================================================================
|
||||
--- a/parser.y
|
||||
+++ a/parser.y
|
||||
@@ -16,8 +16,9 @@
|
||||
* OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
||||
*/
|
||||
#include <math.h>
|
||||
#include <stdint.h>
|
||||
+#include <stdlib.h>
|
||||
#define YYSTYPE int32_t
|
||||
extern int32_t end_result;
|
||||
extern int yylex(void);
|
||||
extern int yyerror(const char *);
|
||||
@@ -13,10 +13,15 @@ stdenv.mkDerivation rec {
|
||||
src = fetchFromGitHub {
|
||||
owner = "ibara";
|
||||
repo = "m4";
|
||||
rev = "${pname}-${version}";
|
||||
sha256 = "04h76hxwb5rs3ylkw1dv8k0kmkzl84ccqlwdwxb6i0x57rrqbgzx";
|
||||
tag = "om4-${version}";
|
||||
hash = "sha256-/b+Fcz6lg2hW541TzBhB9M86wUS7BT6pHzqXxTs0BxI=";
|
||||
};
|
||||
|
||||
patches = [
|
||||
# parser.y:51:25: error: implicit declaration of function 'exit' []
|
||||
./include-exit.patch
|
||||
];
|
||||
|
||||
strictDeps = true;
|
||||
nativeBuildInputs = [
|
||||
bison
|
||||
@@ -25,17 +30,17 @@ stdenv.mkDerivation rec {
|
||||
|
||||
configureFlags = [ "--enable-m4" ];
|
||||
|
||||
meta = with lib; {
|
||||
meta = {
|
||||
description = "Portable OpenBSD m4 macro processor";
|
||||
homepage = "https://github.com/ibara/m4";
|
||||
license = with licenses; [
|
||||
license = with lib.licenses; [
|
||||
bsd2
|
||||
bsd3
|
||||
isc
|
||||
publicDomain
|
||||
];
|
||||
mainProgram = "m4";
|
||||
platforms = platforms.unix;
|
||||
platforms = lib.platforms.unix;
|
||||
maintainers = [ ];
|
||||
};
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user