Forráskód Böngészése

gendynapi.py: Discard SDLMAIN_DECLSPEC functions.

Otherwise SDL_main and SDL_App* functions look like exported symbols instead
of functions the app is meant to implement.

Reference PR #8247.
Ryan C. Gordon 1 éve
szülő
commit
ac6b32bb02
1 módosított fájl, 7 hozzáadás és 1 törlés
  1. 7 1
      src/dynapi/gendynapi.py

+ 7 - 1
src/dynapi/gendynapi.py

@@ -134,7 +134,13 @@ def main():
             # Discard if it doesn't contain 'SDLCALL'
             if "SDLCALL" not in func:
                 if args.debug:
-                    print("  Discard: " + func)
+                    print("  Discard, doesn't have SDLCALL: " + func)
+                continue
+
+            # Discard if it contains 'SDLMAIN_DECLSPEC' (these are not SDL symbols).
+            if "SDLMAIN_DECLSPEC" in func:
+                if args.debug:
+                    print("  Discard, has SDLMAIN_DECLSPEC: " + func)
                 continue
 
             if args.debug: