Disabling debug symbol generation at compile time

classic Classic list List threaded Threaded
3 messages Options
Reply | Threaded
Open this post in threaded view
|

Disabling debug symbol generation at compile time

rm-22
Hi,
I know one can strip the debug symbols, but I would like to
disable debug symbol generation completely at compile time
to speed up the compilation and link process and to conserve disk space.
Where should this be best done?

Asked differently: is there a "build for release" switch
or setting in/for ./autogen.sh, ./configure, Makefile etc.,
or an environment variable for this?

Platform: svn snapshot on Linux, g++; ie. using the generated Makefile's
w/o using any graphical IDE like eclipse etc.)


------------------------------------------------------------------------------
Let Crystal Reports handle the reporting - Free Crystal Reports 2008 30-Day
trial. Simplify your report design, integration and deployment - and focus on
what you do best, core application coding. Discover what's new with
Crystal Reports now.  http://p.sf.net/sfu/bobj-july
_______________________________________________
QuantLib-dev mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/quantlib-dev
Reply | Threaded
Open this post in threaded view
|

Re: Disabling debug symbol generation at compile time

Guowen Han

configure CXXFLAGS = '-O2 -Wall'
or what ever you like.

BTW, I learnt this from Luigi years ago.

Thanks,




"Ralf M." <[hidden email]>

09/04/2009 01:38 PM

To
[hidden email]
cc
Subject
[Quantlib-dev] Disabling debug symbol generation at compile time





Hi,
I know one can strip the debug symbols, but I would like to
disable debug symbol generation completely at compile time
to speed up the compilation and link process and to conserve disk space.
Where should this be best done?

Asked differently: is there a "build for release" switch
or setting in/for ./autogen.sh, ./configure, Makefile etc.,
or an environment variable for this?

Platform: svn snapshot on Linux, g++; ie. using the generated Makefile's
w/o using any graphical IDE like eclipse etc.)


------------------------------------------------------------------------------
Let Crystal Reports handle the reporting - Free Crystal Reports 2008 30-Day
trial. Simplify your report design, integration and deployment - and focus on
what you do best, core application coding. Discover what's new with
Crystal Reports now.  http://p.sf.net/sfu/bobj-july
_______________________________________________
QuantLib-dev mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/quantlib-dev


_____________________________________________________________
DTCC DISCLAIMER: This email and any files transmitted with it are confidential and intended solely for the use of the individual or entity to whom they are addressed. If you have received this email in error, please notify us immediately and delete the email and any attachments from your system. The recipient should check this email and any attachments for the presence of viruses. The company accepts no liability for any damage caused by any virus transmitted by this email.

------------------------------------------------------------------------------
Let Crystal Reports handle the reporting - Free Crystal Reports 2008 30-Day
trial. Simplify your report design, integration and deployment - and focus on
what you do best, core application coding. Discover what's new with
Crystal Reports now.  http://p.sf.net/sfu/bobj-july
_______________________________________________
QuantLib-dev mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/quantlib-dev
Reply | Threaded
Open this post in threaded view
|

Re: Disabling debug symbol generation at compile time

rm-22
Guowen Han wrote:
> configure CXXFLAGS = '-O2 -Wall'
> or what ever you like.
>
> BTW, I learnt this from Luigi years ago.
>
> Thanks,

Yes, this worked like a charm, thx.
Here's my results:

Re: Creating QuantLib libraries without debug symbols:


1.) default make (ie. with debug symbols as this is default)
 libQuantLib-0.9.9.a    about 255 MB
 libQuantLib-0.9.9.so   about 116 MB

 stripped:
-rw-r--r-- 1 root staff 29059270 2009-09-04 05:14 libQuantLib-0.9.9.a
-rwxr-xr-x 1 root staff 13404972 2009-09-04 05:14 libQuantLib-0.9.9.so


2.) make without debug symbols (export CXXFLAGS="-O2 -Wall" before ./configure):
-rw-r--r-- 1 root staff 52913424 2009-09-05 02:07 libQuantLib-0.9.9.a
-rwxr-xr-x 1 root staff 16454629 2009-09-05 02:07 libQuantLib-0.9.9.so

 stripped:
-rw-r--r-- 1 root staff 29059270 2009-09-05 02:11 libQuantLib-0.9.9.a
-rwxr-xr-x 1 root staff 13404972 2009-09-05 02:11 libQuantLib-0.9.9.so


Conclusion:
  Even if one disables debug symbol generation, there are still debug
  symbols in the libraries present (cf. above), probably caused by
  linked in code from other libraries, boost?)
  So stripping is neccessary to eliminate them completely (strip libname).


 

> "Ralf M." <[hidden email]>
> 09/04/2009 01:38 PM
>
> To
> [hidden email]
> cc
>
> Subject
> [Quantlib-dev] Disabling debug symbol generation at compile time
>
> Hi,
> I know one can strip the debug symbols, but I would like to
> disable debug symbol generation completely at compile time
> to speed up the compilation and link process and to conserve disk space.
> Where should this be best done?
>
> Asked differently: is there a "build for release" switch
> or setting in/for ./autogen.sh, ./configure, Makefile etc.,
> or an environment variable for this?
>
> Platform: svn snapshot on Linux, g++; ie. using the generated Makefile's
> w/o using any graphical IDE like eclipse etc.)



------------------------------------------------------------------------------
Let Crystal Reports handle the reporting - Free Crystal Reports 2008 30-Day
trial. Simplify your report design, integration and deployment - and focus on
what you do best, core application coding. Discover what's new with
Crystal Reports now.  http://p.sf.net/sfu/bobj-july
_______________________________________________
QuantLib-dev mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/quantlib-dev