From bd56ca48be81763872d1562822b94843eed12fdc Mon Sep 17 00:00:00 2001 From: Valerii Koval Date: Tue, 23 Jan 2024 14:45:52 +0200 Subject: [PATCH] fix(ldgen): handle object files with .*.o patterns Currently, only `.o`, `.*.obj` and `.obj` patterns are taken into account. It would be great to have object files with the `.*.o` extension pattern (e.g. `file.cpp.o`) also processed as they're quite widespread in third-party integrations. --- tools/ldgen/ldgen/entity.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/tools/ldgen/ldgen/entity.py b/tools/ldgen/ldgen/entity.py index aecdcab91b..659898f370 100644 --- a/tools/ldgen/ldgen/entity.py +++ b/tools/ldgen/ldgen/entity.py @@ -181,7 +181,8 @@ class EntityDB: def _match_obj(self, archive, obj): objs = self.get_objects(archive) - match_objs = (fnmatch.filter(objs, obj + '.o') + match_objs = (fnmatch.filter(objs, obj + '.*.o') + + fnmatch.filter(objs, obj + '.o') + fnmatch.filter(objs, obj + '.*.obj') + fnmatch.filter(objs, obj + '.obj'))