Originally posted by: ravikumarv
Hi Friends,
I'm new to AIX.
I wanted build a project on AIX which is in c/c++ using gcc/g++.
I installed all the necessary application tools specified in
ftp://ftp.software.ibm.com/aix/freeSoftware/aixtoolbox/README.txt
I did the installation properly and I'm able compile the source files.But I wanted to link a shared library of mine.
My steps
gcc -c myfile.c
gcc myfile.o -lmylib -L<PathOfThemylib> -o myfile
Here I'm getting link errors as linker is trying search mylib in the default path but which is not there.
I tried to link with -bctl option , but gcc did not know about this.
Could somebody help me to get out of this problem
Also i read the url:http://www.ibm.com/developerworks/aix/library/au-gnu.html
Here under possible issues with gcc/g++ on AIX section
First problem mentioned is:
"You cannot use the GNU linker on AIX as this will cause incorrectly linked binaries. By default, the AIX linker is used when using GCC on AIX. You should only use the default AIX linker."
What is default linker editor on AIX.How this can invoked after compilation.
Thanks & Regards,
Ravikumar
#AIX-Forum