Created
December 23, 2015 18:52
-
-
Save calio/8f7278394d0125814580 to your computer and use it in GitHub Desktop.
Stock cflow doesn't allow static symbol to be main function using '-m' argument, this fixed that.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
diff --git a/src/symbol.c b/src/symbol.c | |
index 567e458..2810540 100644 | |
--- a/src/symbol.c | |
+++ b/src/symbol.c | |
@@ -131,6 +131,8 @@ install(char *name, int flags) | |
void | |
ident_change_storage(Symbol *sp, enum storage storage) | |
{ | |
+ if (!strcmp(sp->name, start_name)) | |
+ storage = ExternStorage; | |
if (sp->storage == storage) | |
return; | |
if (sp->storage == StaticStorage) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Really helpful, thank you very much!