[uClinux-dev] Linker error and arm-elf-gcc

garumuga at sahasrasolutions.com garumuga at sahasrasolutions.com
Wed Aug 3 17:43:56 EDT 2005

Hi all,

I have snapgear-3.2.0 linux on my system.

when I was try compile it gives an error

digest is my own dierctory

I Installed the toolchain is arm-elf-tools-20030314.sh

the output is

arm-elf-gcc  -Os                     -g   -Dlinux -D__linux__ -Dunix
-D__uClinux__ -DEMBED -nostdinc -I/home/uclinux/snapgear/include
-I/home/uclinux/snapgear/include/include -fno-builtin -nostartfiles
-D__PIC__ -fpic -msingle-pic-base -Wl,-elf2flt
/home/uclinux/snapgear/lib/crt0.o /home/uclinux/snapgear/lib/crti.o
/home/uclinux/snapgear/lib/crtn.o -L/home/uclinux/snapgear/lib  -o
dodigest dodigest.o digest.o scbl.o -lc -lz
/usr/local/arm-elf/bin/ld: line 139: 20130 Segmentation fault      $LINKER
-r -d -o $OFILE.elf2flt $ARG1
collect2: ld returned 139 exit status
make[2]: *** [dodigest] Error 1
make[2]: Leaving directory `/home/uclinux/snapgear/user/digest'
make[1]: *** [all] Error 2
make[1]: Leaving directory `/home/uclinux/snapgear/user'
make: *** [subdirs] Error 1

digest is My own directory and only 3 c file .

I copied the Makefile from the user/tip/Makefile and some modification in
the Makefile

This is My Makefile


EXEC = dodigest
OBJS = dodigest.o digest.o scbl.o

all: $(EXEC)

$(EXEC): $(OBJS)
        $(CC) $(LDFLAGS)  -o $@ $(OBJS) $(LDLIBS$(LDLIBS_$@)) -lz

        $(ROMFSINST) /bin/$(EXEC)

        -rm -f $(EXEC) *.elf *.gdb *.o

Can any one help me out

Thanks in advance,

More information about the uClinux-dev mailing list