Altera_Forum
Honored Contributor
14 years agoTCP/IP Stack error: undefined reference to 'alt_iniche_init()'
I am using Nios II IDE 9.0SPE build 235 to implement web server on nios processor with ucOS.
I added the software component 'NicheStack TCP/IP Stack' through Properties. I get the below error: undefined reference to `alt_iniche_init()' undefined reference to `dhc_set_callback(int, int (*)(int, int))' undefined reference to `dhc_set_state(int, int)' undefined reference to `netmain()' In the syslib folder > Debug > obj > iniche and rest of the TCP/IP folders are present How do I debug this issue? What else should be done so that the system know about `alt_iniche_init()' ,etc? Code (partial): # include <stdio.h> # include <math.h> # include <unistd.h> // <bae> Allows usleep() to be called # include <alt_iniche_dev.h> /* Nichestack definitions */ # include "includes.h" # include "ipport.h" # include "libport.h" # include "osport.h" # include "tcpport.h" # include "net.h" # include "dhcpclnt.h" # include "icmp.h" /* Low-level network */ # include "triple_speed_ethernet_regs.h" # include "iniche/triple_speed_ethernet_iniche.h" # include "iniche/ins_tse_mac.h" /* Nichestack definitions */ # include "includes.h" # include "ipport.h" # include "libport.h" # include "osport.h" # include "tcpport.h" # include "net.h" # include "dhcpclnt.h" # include "icmp.h" . . . . . ... ..... void SSSInitialTask(void *task_data) { wait_on_phy(); dhc_set_callback( 0, ws_ipset ); alt_iniche_init(); netmain(); while (!iniche_net_ready) { TK_SLEEP(1); OSTimeDlyHMSM(0, 0, 3, 0); } printf("\nNios II Simple Socket Server starting up.\n"); while (1); /* Correct Program Flow should never get here */ }