This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

linker input file unused because linking not done

Other Parts Discussed in Thread: TMS320C6474

hi all,

I had compiling a httpserver for coldfire without error and I want to compile it  for TMS320C6474

There is no error in the programs but i had a following problem of linking:

gcc: ./file.o: linker input file unused because linking not done

file is a program file that's repeated for all files

to link these files.o we use -Wl,-ar. but i have therefore another error:

ERROR: argument to option -op ("0-3") is out of range (must be from 0 to 3)

I want to know what reasons for these problems are? and how to remedy  it?.

thanks for your help

 

  • Hi,

    Are you using a make file for compiling?

    If yes, post you make file here, else post your commands here.

    There seems to be error there, probably mixing source files and object files in 1 command

    Regards,

    Sid

  • yes, i use a makefile whitch call other makefiles in 5 directories but we can use the commandes lines ; for example in the directory factory there are many sources that compiles files simultaneously with the following command :

    /home/coralie/noyau_linux/build_dir/bin/c64xplus-linux-gcc -Wall -O2 -Wl,-ar  -DGSOAP=1 -DCOLDFIRE=0 -DLINUX=1 -D__USE_LOGFILE__=0 -DPRINTF_DEBUG=0 -DSSI_VERSION=101 -I../pgm/h -I../pgm/gen -I../pgm/import -g -w -c -fmessage-length=0 -MMD -MP -MF"pgm/ws/factory/admin_WS.d" -MT"pgm/ws/factory/admin_WS.d" -o"pgm/ws/factory/admin_WS.o" "../pgm/ws/factory/admin_WS.c"

    ERROR: argument to option -op ("0-3") is out of range (must be from 0 to 3)

     

    make: *** [pgm/ws/factory/admin_WS.o] Error 1

    -normally when we replace /home/coralie/noyau_linux/build_dir/bin/c64xplus-linux-gcc  by gcc, the compilation of these sources locally for the pc does not pose any problem

    -but as we see, the compilation stops at the first program with this error

    ERROR: argument to option -op ("0-3") is out of range (must be from 0 to 3)

    when using the-E option to gcc ie avoid linker (not link), all programes will compile without error. but not link it to make one executable.

    So the problem is not to use the-E option and at the same time exceed the initial error

    thanks for your help