Jump to content

tcc: undefined symbol 'Clearscreen' (etc)

- - - - -

This topic has been archived. This means that you cannot reply to this topic.
1 reply to this topic

#1
badkarma

badkarma

    Newbie

  • Members
  • Pip
  • 7 posts
Hello,

I am trying to compile into an EXE a .C file (which has an associated 'h' file).

I am using "Tiny C Compiler" but comes up with

tcc: undefined symbol '........'

(where ..... is a few functions that exist in the C file which are referenced in the h file)

The h file is in the same folder as the c file and I execute the compiler as ...

tcc -I c:\tcc\include -L c:\tcc\lib myfile.c

I am a newbie at C but need to tweak the C source and add debug info in so I can see what its doing with variables so I can make a port into VB.

Any ideas on what I am doing wrong are greatly received.

(Am I using the correct compiler?)

P.S. I have now tried Digital Mars compiler and its saying the same thing, so there seems to be something obvious that I am doing wrong (or have not got an additional something)?

Thanks!

PPS. I forgot, there are two .c files ... it seems the undefined symbols are all related to the second .c file even though the first C file (myfile.c) references the second ...

I have copied the second C file code into myfile.c and also copied the second .h file code into myfile.h and it now seems to work ... anybody any ideas why it would not use the second c file as referenced?

#2
v0id

v0id

    Retired

  • Members
  • PipPipPipPipPipPipPipPipPip
  • 2,936 posts
You're giving us nothing to go for. We haven't seen your code, and we haven't seen your errormessages. It would help us a lot if you posted both the code and the errormessages.

Personally, I prefer the compiler called GCC. If you're on Windows, you should check MingW, which has a port of GCC.