From 032cd275265e6d0d6bfd72fbe83b3c893c2ab332 Mon Sep 17 00:00:00 2001 From: slade_rich Date: Mon, 2 Aug 2004 23:52:26 +0000 Subject: [PATCH] Disabled "WARNING: function 'main' undefined" when -S option is used. git-svn-id: https://sdcc.svn.sourceforge.net/svnroot/sdcc/trunk/sdcc@3416 4a8a32a2-be11-0410-ad9d-d568d2c75423 --- src/pic/glue.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/pic/glue.c b/src/pic/glue.c index 777e966b..e6f61ca5 100644 --- a/src/pic/glue.c +++ b/src/pic/glue.c @@ -560,7 +560,8 @@ pic14createInterruptVect (FILE * vFile) /* only if the main function exists */ if (!(mainf = findSymWithLevel (SymbolTab, mainf))) { - if (!options.cc_only) + struct options *op = &options; + if (!(op->cc_only || noAssemble)) // werror (E_NO_MAIN); fprintf(stderr,"WARNING: function 'main' undefined\n"); return; @@ -570,7 +571,7 @@ pic14createInterruptVect (FILE * vFile) if (!IFFUNC_HASBODY(mainf->type)) { /* if ! compile only then main function should be present */ - if (!options.cc_only) + if (!(options.cc_only || noAssemble)) // werror (E_NO_MAIN); fprintf(stderr,"WARNING: function 'main' undefined\n"); return; -- 2.30.2