Mail Archives: djgpp/1998/05/07/18:01:24
On Wed, 6 May 1998 17:01:19 -0700, Nate Eldredge <nate AT cartsys DOT com>
wrote:
>At 05:52 5/6/1998 GMT, Wiel Aerts wrote:
>>
>>I tried to profile a short program. I compiled/linked
>>with:
>>g++ -pg test.cc -o prog.exe
>>
>>The linker complained:
>>
>> ld c:/djgpp/lib/gcrt0.o -Lc:/djgpp/lib/gcc-lib/djgpp/2.80
>>-Lc:/djgpp/lib -lstdcxx -lm -lgcc -lc_p -lgcc
>>C:\DJGPP\BIN/ld.exe: cannot open -lc_p: No such file or directory
>>(ENOENT)
>>
>>I searched my system after the file: libc_p.a. This file doesn't exist
>>on my computer (so it's not a problem with djgpp.env, I think)
>>Where can i get this file?
>
>Please post the entire output of `gcc -v -pg test.cc'. I think this is due
>to a snafu in the DJGPP specs file. In particular, if you have removed any
>lines from DJGPP.ENV, as the README for GCC 2.8.0 erroneously says to do,
>put them back.
>
The instruction
C:\C++_pro\TAIL>gcc -v -pg tail.cc
produces the following output:
Using builtin specs.
gcc version 2.8.0
c:/djgpp/lib/gcc-lib/djgpp/2.80/cpp.exe -lang-c++ -v -undef
-D__GNUC__=2 -D__GN
UG__=2 -D__cplusplus -D__GNUC_MINOR__=8 -Dunix -Di386 -DGO32 -DMSDOS
-DDJGPP=2 -
D__unix__ -D__i386__ -D__GO32__ -D__MSDOS__ -D__DJGPP__=2 -D__unix
-D__i386 -D__
GO32 -D__MSDOS -D__DJGPP=2 -Asystem(unix) -Asystem(msdos) -Acpu(i386)
-Amachine(
i386) -D__EXCEPTIONS -Di386 -Asystem(unix) -Acpu(i386) -Amachine(i386)
-D__i386_
_ -Asystem(unix) -Acpu(i386) -Amachine(i386) tail.cc
C:\WINDOWS\TEMP/ccaaaaaa.ii
GNU CPP version 2.8.0 (80386, BSD syntax)
#include "..." search starts here:
#include <...> search starts here:
c:/djgpp/lang/cxx
c:/djgpp/lib/gcc-lib/djgpp/2.80/include
c:/djgpp/include
End of search list.
c:/djgpp/lib/gcc-lib/djgpp/2.80/cc1plus.exe
C:\WINDOWS\TEMP/ccaaaaaa.ii -quiet
-dumpbase tail.cc -version -p -o C:\WINDOWS\TEMP/ccaaaaaa.s
GNU C++ version 2.8.0 (djgpp) compiled by GNU C version 2.8.0.
as -o C:\WINDOWS\TEMP/ccaaaaaa1.o C:\WINDOWS\TEMP/ccaaaaaa.s
ld c:/djgpp/lib/gcrt0.o -Lc:/djgpp/lib/gcc-lib/djgpp/2.80
-Lc:/djgpp/lib C:\WIN
DOWS\TEMP/ccaaaaaa1.o -lgcc -lc_p -lgcc
C:\DJGPP\BIN/ld.exe: cannot open -lc_p: No such file or directory
(ENOENT)
I already put these lines back (before).
>You can also work around this problem by just copying c:\djgpp\lib\libc.a to
>c:\djgpp\lib\libc_p.a.
>
OK, I did this: now it works fine.
>Nate Eldredge
>nate AT cartsys DOT com
>
>
>
Thanks a lot for your fast response.
Wiel Aerts
wjae AT plex DOT nl
- Raw text -