Erro ao instalar o imtools Ubuntu 14.04 x64

1

Ao tentar instalar uma ferramenta para converter imagens em formato de texto bruto chamado imtools Eu recebo este erro:

/usr/bin/ld: trans.o: undefined reference to symbol 'cos@@GLIBC_2.2.5'
//lib/x86_64-linux-gnu/libm.so.6: error adding symbols: DSO missing from command line
collect2: error: ld returned 1 exit status
make: *** [imtool] Error 1

Instalei outras bibliotecas obrigatórias, como libjpeg , mas não consigo resolver esse erro.

código Makefile:

object = image.o jpeg.o main.o bmp.o edge.o png.o stats.o trans.o raw.o

imtool:$(object)
    cc -o imtool $(object) -ljpeg -lpng -lglut
jpeg.o: jpeg.h
raw.o: raw.h
image.o: image.h
main.o: defs.h glx.h
edge.o: edge.h
trans.o: trans.h
png.o: png.h png.c
    cc -c png.c -o png.o -g
stats.o : stats.h
bmp.o: 
.PHONY : clean
clean:
    rm *.o
    
por Mahboob Karimian 24.12.2014 / 17:09

1 resposta

1

Eu editei o makefile da seguinte forma:

object = image.o jpeg.o main.o -lGL -lGLU bmp.o edge.o png.o stats.o trans.o -lm raw.o

imtool:$(object)
    cc -o imtool $(object) -ljpeg -lpng -lglut
jpeg.o: jpeg.h
raw.o: raw.h
image.o: image.h
main.o: defs.h glx.h
edge.o: edge.h
trans.o: trans.h
png.o: png.h png.c
    cc -c png.c -o png.o -g
stats.o : stats.h
bmp.o: 
.PHONY : clean
clean:
    rm *.o

adicionou -lm -lGL -lGLU e está funcionando bem agora:)

    
por Mahboob Karimian 24.12.2014 / 18:31