Forum Discussion
Altera_Forum
Honored Contributor
19 years ago --- Quote Start --- originally posted by abg@Nov 8 2006, 11:36 PM i have read the man pages of "ld". i am running multiple pass ld, but the problem was to find waht libraries were needed, without having to link against all the libraries i have (i have many libraries and programs, some programs link with some libraries, and some with others).
the man pages of ld refer to standard ld, and it seems that nios2-linux-ld doesn't have all the options (doesn't recognize the option -m for mapping the output)
anyway, i'll try to link against all the libraries, even if the compile time gets increased a lot.
the "-msys-crt0, -nostdinc and -nostdlib ,etc.", ... i used the makefile that the altera ide generated at the beginning, before compiling in linux.
thank you...
alex
<div align='right'><{post_snapback}> (index.php?act=findpost&pid=19302)
--- quote end ---
--- Quote End --- You still should not use those "-msys-crt0, -nostdinc and -nostdlib " flags. You need them with altera's nios2-elf compiler. But DON'T use them with nios2-linux-uclibc compiler for uClinux. To pass flag to ld from gcc, you need -Wl, nios2-linux-uclibc-gcc -Wl,"-Map hello.map" -elf2flt hello.c -o hello You can have different target rule for each program and libs options in your Makefile. eg, make model1, or make model2 etc.