B
bobrics
Hi,
I am trying to link use a library created by me, and getting the
following error during linking:
$: sudo gcc -c mycode.c
$: sudo ar rc libmylib.a myfuncs.o
$: sudo runlib libmylib.a
$: gcc myfuncs.o -o mycode -L. -lmylib -lm
/usr/lib/gcc/i486-linux-gnu/4.0.2/../../../../lib/crt1.o: In function
`_start':
.../sysdeps/i386/elf/start.S:115: undefined reference to `main'
collect2: ld returned 1 exit status
What is the problem?
Thank you in advance
SB
I am trying to link use a library created by me, and getting the
following error during linking:
$: sudo gcc -c mycode.c
$: sudo ar rc libmylib.a myfuncs.o
$: sudo runlib libmylib.a
$: gcc myfuncs.o -o mycode -L. -lmylib -lm
/usr/lib/gcc/i486-linux-gnu/4.0.2/../../../../lib/crt1.o: In function
`_start':
.../sysdeps/i386/elf/start.S:115: undefined reference to `main'
collect2: ld returned 1 exit status
What is the problem?
Thank you in advance
SB