Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
flag to make emerge strip installed ebuilds
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Gentoo Chat
View previous topic :: View next topic  
Author Message
Pitr
Tux's lil' helper
Tux's lil' helper


Joined: 23 Jun 2002
Posts: 90

PostPosted: Tue Jun 25, 2002 11:49 am    Post subject: flag to make emerge strip installed ebuilds Reply with quote

I don't know if we are doing this already, but I see many of the users already user -fomit-frame-pointer and that indicates to me that many don't need tp debug, so why not set a USE varible maybe to automatically strip the installed ebuild after ended compilation for it's debug flags:

The command would be:
strip --strip-debug filename

the LFS project stats this numbers:
A dynamic Bash binary with debugging symbols: 1.2 MB
A dynamic Bash binary without debugging symbols: 478 KB
/lib and /usr/lib (glibc and gcc files) with debugging symbols: 87 MB
/lib and /usr/lib (glibc and gcc files) without debugging symbols: 16 MB

That means a smaller install, and if I remember correctly a faster system, as the binary we have to load is smaller.
Back to top
View user's profile Send private message
ves
n00b
n00b


Joined: 17 Apr 2002
Posts: 30

PostPosted: Tue Jun 25, 2002 3:33 pm    Post subject: Reply with quote

that would definitely be hella cool..
Back to top
View user's profile Send private message
klieber
Administrator
Administrator


Joined: 17 Apr 2002
Posts: 3657
Location: San Francisco, CA

PostPosted: Tue Jun 25, 2002 4:31 pm    Post subject: Reply with quote

Sign me up. File a feature request on bugs.gentoo.org!
:)
--kurt
_________________
The problem with political jokes is that they get elected
Back to top
View user's profile Send private message
Pitr
Tux's lil' helper
Tux's lil' helper


Joined: 23 Jun 2002
Posts: 90

PostPosted: Tue Jun 25, 2002 4:37 pm    Post subject: Reply with quote

Filed - I hope I did it right, I have an unnatural hatred of Bugzilla like applications. To many choices to make.
Back to top
View user's profile Send private message
proxy
Apprentice
Apprentice


Joined: 20 Apr 2002
Posts: 253
Location: Chantilly, VA

PostPosted: Tue Jun 25, 2002 5:42 pm    Post subject: Reply with quote

i hope this gets implemented ASAP, it is no joke that debug information can take up huge amounts of space. in my opinion, for a speedy and slim oriented distro this is a MUST :)

great idea!
Back to top
View user's profile Send private message
proxy
Apprentice
Apprentice


Joined: 20 Apr 2002
Posts: 253
Location: Chantilly, VA

PostPosted: Tue Jun 25, 2002 5:45 pm    Post subject: Reply with quote

this just made me think..are the binaries on the install image stripped? i mean if we could get that CD even smaller, that means that we add a few more useful utilities (finally end the VI vs NANO war? ;)) without bloat

proxy
Back to top
View user's profile Send private message
Pitr
Tux's lil' helper
Tux's lil' helper


Joined: 23 Jun 2002
Posts: 90

PostPosted: Tue Jun 25, 2002 6:05 pm    Post subject: Reply with quote

emacs without bloat.... how :)

/me puts on flamewar battlearmor
Back to top
View user's profile Send private message
fghellar
Bodhisattva
Bodhisattva


Joined: 10 Apr 2002
Posts: 856
Location: Porto Alegre, BR

PostPosted: Tue Jun 25, 2002 7:11 pm    Post subject: Reply with quote

From the LFS book: (I won't post a link because you can emerge linuxfromscratch-html) :)

Quote:
About debugging symbols

Most programs and libraries by default are compiled with debugging symbols (gcc option -g).

A program compiled with debugging symbols means a user can run a program or library through a debugger and the debugger's output will be user friendly. These debugging symbols also enlarge the program or library significantly.

Before you start wondering whether these debugging symbols really make a big difference, here are some statistics. Use them to draw your own conclusion.
    A dynamic Bash binary with debugging symbols: 1.2MB
    A dynamic Bash binary without debugging symbols: 478KB
    /lib and /usr/lib (glibc and gcc files) with debugging symbols: 87MB
    /lib and /usr/lib (glibc and gcc files) without debugging symbols: 16MB
Sizes vary depending on which compiler was used and which C library version was used to link dynamic programs against, but results will be similar if you compare programs with and without debugging symbols.

To remove debugging symbols from a binary (must be an a.out or ELF binary) run strip --strip-debug filename. Wildcards can be used to strip debugging symbols from multiple files (use something like strip --strip-debug $LFS/usr/bin/*). Most people will probably never use a debugger on software, so by removing those symbols a lot of disk space can be regained.

For your convenience, chapter 9 includes one simple command to strip all debugging symbols from all programs and libraries on your system.


But, are the Gentoo packages actually compiled with the -g option?
_________________
| www.gentoo.org | www.tldp.org | www.google.com |
Back to top
View user's profile Send private message
pjp
Administrator
Administrator


Joined: 16 Apr 2002
Posts: 16090
Location: Colorado

PostPosted: Tue Jun 25, 2002 8:03 pm    Post subject: Reply with quote

I won't pretend to understand the original post. From the followups, it sounds like
making things take up less space. I'm all for that.
_________________
lolgov. 'cause where we're going, you don't have civil liberties.

In Loving Memory
1787 - 2008
Back to top
View user's profile Send private message
slik
n00b
n00b


Joined: 18 Apr 2002
Posts: 48
Location: Alberta, Canada

PostPosted: Tue Jun 25, 2002 8:22 pm    Post subject: Reply with quote

fghellar wrote:
But, are the Gentoo packages actually compiled with the -g option?


I seriously doubt it.. and.. did you all build your systems with CFLAGS="-g ${otherstuff}" and CXXFLAGS="-g ${otherstuff}" in your /etc/make.conf? If not, don't worry about it.
Back to top
View user's profile Send private message
Pitr
Tux's lil' helper
Tux's lil' helper


Joined: 23 Jun 2002
Posts: 90

PostPosted: Tue Jun 25, 2002 8:46 pm    Post subject: Reply with quote

kanuslupus wrote:
I won't pretend to understand the original post. From the followups, it sounds like
making things take up less space. I'm all for that.


Not all of us have english as our native language - would you be happier if I explained the idea to you in danish ? :P
Back to top
View user's profile Send private message
fghellar
Bodhisattva
Bodhisattva


Joined: 10 Apr 2002
Posts: 856
Location: Porto Alegre, BR

PostPosted: Tue Jun 25, 2002 8:49 pm    Post subject: Reply with quote

slik wrote:
fghellar wrote:
But, are the Gentoo packages actually compiled with the -g option?


I seriously doubt it.. and.. did you all build your systems with CFLAGS="-g ${otherstuff}" and CXXFLAGS="-g ${otherstuff}" in your /etc/make.conf? If not, don't worry about it.

That's what I had in mind... But some packages do include their own compile flags, don't they? Does any of them include -g?
_________________
| www.gentoo.org | www.tldp.org | www.google.com |
Back to top
View user's profile Send private message
slik
n00b
n00b


Joined: 18 Apr 2002
Posts: 48
Location: Alberta, Canada

PostPosted: Tue Jun 25, 2002 9:11 pm    Post subject: Reply with quote

fghellar wrote:
slik wrote:
fghellar wrote:
But, are the Gentoo packages actually compiled with the -g option?


I seriously doubt it.. and.. did you all build your systems with CFLAGS="-g ${otherstuff}" and CXXFLAGS="-g ${otherstuff}" in your /etc/make.conf? If not, don't worry about it.

That's what I had in mind... But some packages do include their own compile flags, don't they? Does any of them include -g?

Most packages that define their own flags do it for more optimization, not debugging. some configure scripts have --enable-debug, which when enabled will define macros and include debugging code that otherwise wouldn't get compiled in. and I think emerge strips everything it installs anyway, otherwise why would there be a need for /usr/portage/eclass/debug.eclass?

a debug USE var would be nice too, see my post here for my idea for a debugging environment.
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Gentoo Chat All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum