October 31, 2025, 05:23:02 AM

News:

IWBasic runs in Windows 11!


Link error

Started by tbohon, February 17, 2010, 08:34:32 AM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

tbohon

February 17, 2010, 08:34:32 AM Last Edit: February 17, 2010, 09:00:54 AM by tbohon
Have been working with some example programs found on this forum and, when compiling/linking keep getting the following error:

Error: unresolved extern _ib_main

These are (mostly) simple console programs and appear syntactically correct so I'm not sure even how to proceed.

Thoughts?

Tnx.


UPDATE:  This is now happening with all of my CB and EB programs ... ???!!!???!!!???
"If you lead your life the right way, the karma will take care of itself ... the dreams will come to you."  -- Randy Pausch, PhD (1961-2008)

sapero

February 17, 2010, 09:41:20 AM #1 Last Edit: February 17, 2010, 09:44:47 AM by sapero
_ib_main is an entry-point symbol, automatically added at the beginning of your source code when there is no project opened.
If you have opened a project, you need to put $main at the top of your main souce module:

main.eba:
$include "..."
$main /* this will generate _ib_main symbol, and here your program starts*/

...
openwindow ...

Any code before $main will be not executed, unless it is a subroutine called from code after $main.

ZeroDog

perhaps you accidently opened a new project withuot knowing... Ive done that a few times before I realized I had to close the current project before compiling a single file project.

tbohon

<sigh>

Can I just plead AARP short term memory issues and let it go?   ;D

I can be such a maroon ...

Thanks guys - I'll go take my Geritol and dust off the rocking chair, that's obviously the limit of my 'high tech' capabilities today.

"If you lead your life the right way, the karma will take care of itself ... the dreams will come to you."  -- Randy Pausch, PhD (1961-2008)

AdrianFox

I wonder how many EB users have NEVER done this?  Where do you get Geritol?
:D
Adrian Fox