From 75913a512139c8276433a954cdbb2a9ffd2ed4ab Mon Sep 17 00:00:00 2001 From: Pierre Habouzit Date: Mon, 28 May 2007 11:44:49 +0200 Subject: [PATCH] Ignoble trick to allow us to override _init with a macro. Will be changed in a (I hope) near future. Used in madmutt.cpkg Signed-off-by: Pierre Habouzit --- tools/cpkg2c.mll | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tools/cpkg2c.mll b/tools/cpkg2c.mll index 0abfe8b..b04a849 100644 --- a/tools/cpkg2c.mll +++ b/tools/cpkg2c.mll @@ -496,7 +496,7 @@ and ext_member m f = parse fprintf ob "};\n"; (* dump struct init func *) - fprintf ob "\nstatic void %s_init(void)\n{\n" pkg.name; + fprintf ob "\nstatic void (%s_init)(void)\n{\n" pkg.name; List.iter (function (m, _, _) -> if not (fst m.typ) then let init, f, l = m.init in -- 2.20.1