title: /usr/bin/ld: cannot find -lgd
body: <p>So I am trying to compile a program using <strong>make -f Makefile</strong> but I am getting this error <strong>/usr/bin/ld: cannot find -lgd</strong> </p>
  
  <pre><code>root@kevin-VirtualBox://home/kevin/Desktop/makef# make -f Makefile
  gcc -o main obj/main.o obj/serial.o obj/fb.o obj/menu_main.o obj/timer.o obj/cmdin.o obj/buzzer.o obj/statemachine.o obj/inout.o obj/network.o obj/text_file_input.o obj/text_file_input_oven.o -I./ -lgd -lrt
  /usr/bin/ld: cannot find -lgd
  collect2: ld returned 1 exit status
  make: *** [main] Error 1
  root@kevin-VirtualBox://home/kevin/Desktop/makef# 
  </code></pre>
  
  <p>Makefile:</p>
  
  <pre><code>IDIR =./
  CC=gcc
  CFLAGS=-I$(IDIR)
  
  ODIR=obj
  LDIR =./
  
  LIBS=-lgd -lrt
  
  _DEPS = main.h Makefile
  DEPS = $(patsubst %,$(IDIR)/%,$(_DEPS))
  
  _OBJ = main.o serial.o fb.o menu_main.o timer.o cmdin.o buzzer.o statemachine.o inout.o network.o text_file_input.o text_file_input_oven.o
  OBJ = $(patsubst %,$(ODIR)/%,$(_OBJ))
  
  
  $(ODIR)/%.o: %.c $(DEPS)
      $(CC) -c -o $@ $&lt; $(CFLAGS)
  
  main: $(OBJ)
      gcc -o $@ $^ $(CFLAGS) $(LIBS)
  
  .PHONY: clean
  
  clean:
      rm -f $(ODIR)/*.o *~ core $(INCDIR)/*~ 
  </code></pre>
  
  <p>after replacing (libgd.a libgd.la libgd.so libgd.so.2 libgd.so.2.0.0) I am getting this error:</p>
  
  <pre><code>root@kevin-VirtualBox://home/kevin/Desktop/makef# make -f Makefilegcc -o main obj/main.o obj/serial.o obj/fb.o obj/menu_main.o obj/timer.o obj/cmdin.o obj/buzzer.o obj/statemachine.o obj/inout.o obj/network.o obj/text_file_input.o obj/text_file_input_oven.o -I./ -lgd -lrt
  /usr/bin/ld: skipping incompatible /usr/lib/gcc/x86_64-linux-gnu/4.6/../../../../lib/libgd.so when searching for -lgd
  /usr/bin/ld: skipping incompatible /usr/lib/gcc/x86_64-linux-gnu/4.6/../../../../lib/libgd.a when searching for -lgd
  /usr/bin/ld: skipping incompatible /usr/lib/../lib/libgd.so when searching for -lgd
  /usr/bin/ld: skipping incompatible /usr/lib/../lib/libgd.a when searching for -lgd
  /usr/bin/ld: skipping incompatible /usr/lib/gcc/x86_64-linux-gnu/4.6/../../../libgd.so when searching for -lgd
  /usr/bin/ld: skipping incompatible /usr/lib/gcc/x86_64-linux-gnu/4.6/../../../libgd.a when searching for -lgd
  /usr/bin/ld: skipping incompatible /usr/lib/libgd.so when searching for -lgd
  /usr/bin/ld: skipping incompatible /usr/lib/libgd.a when searching for -lgd
  /usr/bin/ld: cannot find -lgd
  collect2: ld returned 1 exit status
  make: *** [main] Error 1
  </code></pre>