Mail Archives: djgpp/1998/04/26/23:30:35
At 11:36 4/26/1998 -0400, Peter Palotas wrote:
>I just tried to compile a program for profiling. (Probably the first time
>since I installed gcc280b.zip)... And I ran into a little problem;
>
>This is the commandline and the compiler output:
>
>bash$ gcc -pg -otest.exe test.c
>D:\CODING\DJGPP\BIN/ld.exe: cannot open -lc_p: No such file or directory
>(ENOENT)
>
>
>Very greatful for help with this problem.
Okay. This means GCC is trying to link against a profiling library. Most
likely, this is due to it not using your specs file, but rather its builtin
one. Compile with `-v' and see if you see the line "Using builtin specs",
and if so, make sure that %DJDIR%/lib is along the LIBRARY_PATH specified
for GCC in DJGPP.ENV. (The README erroneously instructs you to remove it.)
As a quick-and-dirty fix, you can copy %DJDIR%/lib/libc.a to
%DJDIR%/lib/libc_p.a, or get a profiling library from Tom Demmer's patch
site and install it as libc_p.a. (This would have the addition of letting
you get profiling info on library functions.)
Nate Eldredge
nate AT cartsys DOT com
- Raw text -