# --- T2-COPYRIGHT-BEGIN --- # t2/package/*/motif/hotfix-wmluiltok.patch # Copyright (C) 2026 The T2 SDE Project # SPDX-License-Identifier: GPL-2.0 or patched project license # --- T2-COPYRIGHT-END --- Provide a main() for the wmluiltok token scanner. wmluiltok.l relies on the main() from libfl. With a shared libfl.so.2 that main() references yylex, which the executable does not export, so the generated tool aborts at startup: ./wmluiltok: symbol lookup error: /usr/lib64/libfl.so.2: undefined symbol: yylex Define main() locally so libfl's main is no longer pulled in. Signed-off-by: René Rebe --- a/tools/wml/wmluiltok.l 2026-08-15 16:16:28.616563575 +0200 +++ b/tools/wml/wmluiltok.l 2026-08-15 16:16:28.617253510 +0200 @@ -209,3 +210,13 @@ int yywrap () } return (1); } + + +/* provide our own main, the one in shared libfl.so can not resolve yylex */ +int main (int argc, char **argv) +{ + while (yylex () != 0) + ; + + return (0); +}