Dec 31, 2008 at 8:06am UTC
Hi All,
I am creating c++ client to access j2ee web service. I am using g++ compiler. I have used following command.
C:\cygnus\cygwin-b20\H-i586-cygwin32\bin>g++ *.cpp -ID:\axisserver\axis-c-win\ax
is-c-1-5-win32\include\ -L D:\axisserver\axis-c-win\axis-c-1-5-win32\lib\axis -
l AxisClient -ocalculator
g++: AxisClient: No such file or directory
I got the above mentioned error. But AxisClient.lib is available at D:\axisserver\axis-c-win\axis-c-1-5-win32\lib\axis.
I couldn't find what i missed . Anybody please help me....
Thanks in advance....
Jan 2, 2009 at 1:59pm UTC
Hi,
Any suggestion for this issue........?
Thanks in advance
Jan 2, 2009 at 7:58pm UTC
First glance says that there shouldn't be a space between -L and the directory name D:\axisserver\axis-c-win\axis-c-1-5-win32\lib\axis .
But that might just be a typing error when you posted the text?
Jan 3, 2009 at 5:45am UTC
Hi guestgulkan,
Thanks for your response. I have removed the space between -L and the directory name D:\axisserver\axis-c-win\axis-c-1-5-win32\lib\axis , but i am getting the same error.
Error:
C:\cygnus\cygwin-b20\H-i586-cygwin32\bin>gcc calculat.cpp -ID:\axisserver\axis-c-win\axis-c-1-5-win32\include\ -LD:\axisserver\axis-c-win\axis-c-1-5-win32\lib\axis calculator.o -lAxisClient -o calculatorc++
../lib/gcc-lib/i586-cygwin32/egcs-2.91.57/../../../../i586-cygwin32/bin//ld: can
not open -lAxisClient: No such file or directory
collect2: ld returned 1 exit status
Can you suggest me what i missed?
Thanks.....
Jan 3, 2009 at 10:12am UTC
I'm thinking about it:
When it comes to these sort of problems, I start thinking things like:
1. if using g++ are the library style correct. gcc uses .a libraries. Microsoft uses .lib libraries.
(I think mingw recognises both)
2. What is the full name of the AxisClient library? Is it AxisClient.a or AxisClient.lib
3. Could we be using .lib distribution made for the microsoft compilers - and gcc is choking?.
Jan 4, 2009 at 6:40pm UTC
IIRC, mingw32-g++ will add the usual prefix and extension if only the library name is provided (e.g. it will interpret "bz2lib" as "libbz2lib.a"). Try using the full name.
Jan 5, 2009 at 4:59am UTC
Hi,
Thanks for your information.I am working with windows platform.
The full name of AxisClient library is AxisClient.lib. . In have used the full name also.
I have used the following command to create exe.
C:\cygnus\cygwin-b20\H-i586-cygwin32\bin>g++ -v -E *.cpp -ID:\axisserver\axis-c-win\axis-c-1-5-win32\include\ -L D:\axisserver\axis-c-win\axis-c-1-5-win32\lib\axis -l AxisClient -o calculatorc++
It has created calculatorc++.exe. But when i try to run calculatorc++, it is giving error like
C:\cygnus\CYGWIN~1\H-I586~1\bin>calculatorc++
Program too big to fit in memory
What could be the problem ? Please suggest me..
Thanks in advance....