Hi,
In Build.xml there is three main steps:
1. Compiling *.cpp into objects 2. Linking *.o into static libinkscape.a 3. Compiling and Linking "Main" with libinkscape.a
Actually I'm using the IDE Code::Blocks (with the same mingw compiler) to debug inkscape and I'm able to do the same things that the Build.xml does.
My problem are these three steps, I would like to create Inkscape.exe without having to create a static library because with the -g parameter linking in (2) and (3) took so long !!!
So I tried to bypass the "libinkscape.a" creation but it's not working. Someone already did this before ?
Yann.
On 8/11/2009 3:45 AM, Yann Papouin wrote:
Hi,
In Build.xml there is three main steps:
- Compiling *.cpp into objects
- Linking *.o into static libinkscape.a
- Compiling and Linking "Main" with libinkscape.a
Actually I'm using the IDE Code::Blocks (with the same mingw compiler) to debug inkscape and I'm able to do the same things that the Build.xml does.
My problem are these three steps, I would like to create Inkscape.exe without having to create a static library because with the -g parameter linking in (2) and (3) took so long !!!
So I tried to bypass the "libinkscape.a" creation but it's not working. Someone already did this before ? Yann.
If you compile all of the .o's with -g, then the link will be very slow whether you use 'ar' or not. It it not ar's fault. Inkscape c++ binaries compiled with -g are HUGE. The link is very time and memory intensive. If your computer is low on memory, then VM swapping will slow it much more.
My trick is this: don't build the entire thing with -g. If you know which .cpp file(s) have the problems, delete their corresponding .o's in /build/obj, turn on -g, and rebuild them.
Then you have -g trace info only for the objects that need it. You can then hack and compile as much as you want.
bob
Thank you for your tip, I didn't know that you could do a debug session with only one file's symbols.
To coming back to my question (by-passing libinkscape.a creation) there is a log file here (1.4 Mo) of the building: http://ftpmerou.free.fr/inkscape/Inkscape_build_log.html
I think that it's more a MinGW or Code::Blocks limitation because the returned error is a non sense: mingw32-g++.exe: C:\devlibs\li: No such file or directory
By surfing, I discovered that ar.exe is an archiver and ".a" just an archive file that can be extracted with a built-in index when ranlib is executed : http://en.wikipedia.org/wiki/Ar_(file_format)
But even when by using some arguments like:
q[f] - quick append file(s) to the archive r[ab][f][u] - replace existing or insert new file(s) into the archive
it just create an new file, copy all data from the original, do its stuff and then deleting the old archive, It takes about the same time... I though that it will just update the current archive.
participants (2)
-
Bob Jamison
-
Yann Papouin