Hi,
I'm adding new functions to some files and I have a problem when I compiling it, may I have to change something in makefile or other.
Here is my error

   /bin/bash ../libtool --tag=CC   --mode=link gcc -std=gnu99  -g -O2
   -Wall -Wstrict-prototypes -Wformat-security -Wshadow -Wextra
   -Wno-unused-parameter -Wbad-function-cast -Wcast-align
   -Wredundant-decls   -o openocd main.o libopenocd.la
   ../jimtcl/libjim.a   -ldl
   libtool: link: gcc -std=gnu99 -g -O2 -Wall -Wstrict-prototypes
   -Wformat-security -Wshadow -Wextra -Wno-unused-parameter
   -Wbad-function-cast -Wcast-align -Wredundant-decls -o openocd
   main.o  ./.libs/libopenocd.a -lpthread -lrt ../jimtcl/libjim.a -ldl
   ./.libs/libopenocd.a(libhelper_la-options.o): In function `port_flag':
   /home/vivien/Desktop/openocdcopie/src/helper/options.c:130:
   undefined reference to `usbinit'
   /home/vivien/Desktop/openocdcopie/src/helper/options.c:131:
   undefined reference to `search'
   /home/vivien/Desktop/openocdcopie/src/helper/options.c:137:
   undefined reference to `detectIDCODE'
   /home/vivien/Desktop/openocdcopie/src/helper/options.c:138:
   undefined reference to `neoconf'
   /home/vivien/Desktop/openocdcopie/src/helper/options.c:102:
   undefined reference to `usbinit'
   /home/vivien/Desktop/openocdcopie/src/helper/options.c:103:
   undefined reference to `search'
   /home/vivien/Desktop/openocdcopie/src/helper/options.c:107:
   undefined reference to `detectIDCODE'
   /home/vivien/Desktop/openocdcopie/src/helper/options.c:108:
   undefined reference to `neoconf'
   ./.libs/libopenocd.a(libhelper_la-options.o): In function
   `parse_cmdline_args':
   /home/vivien/Desktop/openocdcopie/src/helper/options.c:256:
   undefined reference to `usbinit'
   /home/vivien/Desktop/openocdcopie/src/helper/options.c:257:
   undefined reference to `search'
   collect2: error: ld returned 1 exit status
   make[4]: *** [openocd] Erreur 1

The function usbinit search detectIDCODE ... are on other file called detection.c (with detection.h)
Of course I include detection.h in options.h

Anyone have an idea on how to do it ?

Cheers
Vivien
------------------------------------------------------------------------------
Live Security Virtual Conference
Exclusive live event will cover all the ways today's security and 
threat landscape has changed and how IT managers can respond. Discussions 
will include endpoint security, mobile security and the latest in malware 
threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/
_______________________________________________
OpenOCD-devel mailing list
OpenOCD-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/openocd-devel

Reply via email to