- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I am trying to build and run the simple socket server template and I am getting the following error from the linker.
could someone please explain to me the following error: ======================================================== [BSP build complete] Info: Linking NiosSystem.elf nios2-elf-g++ -T'../NiosSystem_bsp//linker.x' -msys-crt0='../NiosSystem_bsp//obj/HAL/src/crt0.o' -msys-lib=ucosii_bsp -L../NiosSystem_bsp/ -Wl,-Map=NiosSystem.map -O0 -g -Wall -EL -mhw-div -mhw-mul -mno-hw-mulx -o NiosSystem.elf -lm ../NiosSystem_bsp/\libucosii_bsp.a(alt_main.o): In function `alt_main': c:/altera/Projects/GaitID/NiosIIfDesign/software/NiosSystem_bsp/HAL/src/alt_main.c:154: undefined reference to `main' ../NiosSystem_bsp/\libucosii_bsp.a(dm9000a.o): In function `prep_dm9000a': c:/altera/Projects/GaitID/NiosIIfDesign/software/NiosSystem_bsp/drivers/src/dm9000a.c:204: undefined reference to `get_mac_addr' ../NiosSystem_bsp/\libucosii_bsp.a(alt_iniche_dev.o): In function `iniche_devices_init': c:/altera/Projects/GaitID/NiosIIfDesign/software/NiosSystem_bsp/iniche/src/alt_iniche_dev.c:118: undefined reference to `get_ip_addr' collect2: ld returned 1 exit status make: *** [NiosSystem.elf] Error 1 ======================================================== what should I do? how can I fix that?Link Copied
6 Replies
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
BTW I am using Eclipse.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Do you have main(), get_mac_addr(), and get_ip_addr() functions in your application code? If memory serves, I believe you _ have_ to provide these for Interniche to function.
Look at the examples to get an idea of what you need to do.- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
yes. I have these functions in the application code.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi!
even if this is a very old thread I would like to post an answer for this problem because I was not able to find anything helpful in the web. This is problem occurred when I tried to recreate and rebuilt my project when I didn't completely remove all files from the /sftware/project_sources directory. Here what you simply need to do: copy your sources in software directory for example delete the two folders /sftware/project_sources and /sftware/project_bsp_sources then recreate properly your bsp from eclipse (if you're under windows run it in administrator mode) add your sources in /sftware/project_sources built all everything should be working fine. hope this will help someone.- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
--- Quote Start --- I am also encountering the same thing! --- Quote End --- Hi KennyJRice, you still have the same error even after trying what I described in my precedent answer ? !
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I can contribute to the thread, that way of solving the problem have been useful for me too.i've just deleted all the sources of previously genereted bsp and generate them one more time. Afer that the build had been comleted successfully. Thanks for advice.
Reply
Topic Options
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page