init.c:(.text+0x34): undefined reference to `main'

The MagickWand interface is a new high-level C API interface to ImageMagick core methods. We discourage the use of the core methods and encourage the use of this API instead. Post MagickWand questions, bug reports, and suggestions to this forum.
Locked
SamBlackmore
Posts: 1
Joined: 2013-04-11T10:20:33-07:00
Authentication code: 6789

init.c:(.text+0x34): undefined reference to `main'

Post by SamBlackmore »

Hi,

I'm trying to compile the C example equivalent to convert.

When I type:

Code: Select all

cc -o logo_test `pkg-config --cflags --libs MagickWand` logo_test.c
I get the following message:

Code: Select all

/usr/lib/gcc/arm-angstrom-linux-gnueabi/4.5.4/../../../crt1.o: In function `_start':
init.c:(.text+0x34): undefined reference to `main'
collect2: ld returned 1 exit status
I have searched the error and found several responses that talk about makefiles.
I'm still fairly new to Linux and don't know anything about makefiles.
Any help would be greatly appreciated!!!

I also tried:

Code: Select all

cc -o logo_test `pkg-config --cflags --libs MagickWand` logo_test.c -nostdlib
Which gave me:

Code: Select all

/usr/lib/gcc/arm-angstrom-linux-gnueabi/4.5.4/../../../../arm-angstrom-linux-gnueabi/bin/ld: warning: cannot find entry symbol _start; d
efaulting to 000083e4

Locked