From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from pigeon.gentoo.org ([208.92.234.80] helo=lists.gentoo.org) by finch.gentoo.org with esmtp (Exim 4.60) (envelope-from ) id 1QvkoQ-0005hF-9V for garchives@archives.gentoo.org; Tue, 23 Aug 2011 06:50:15 +0000 Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id 52D3921C126; Tue, 23 Aug 2011 06:50:05 +0000 (UTC) Received: from smtp.gentoo.org (smtp.gentoo.org [140.211.166.183]) by pigeon.gentoo.org (Postfix) with ESMTP id 3206B21C103 for ; Tue, 23 Aug 2011 06:49:10 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by smtp.gentoo.org (Postfix) with ESMTP id B01D21B4002 for ; Tue, 23 Aug 2011 06:49:09 +0000 (UTC) X-Virus-Scanned: by amavisd-new using ClamAV at gentoo.org X-Spam-Score: -4.956 X-Spam-Level: X-Spam-Status: No, score=-4.956 required=5.5 tests=[AWL=1.643, BAYES_00=-2.599, RCVD_IN_DNSWL_MED=-4] Received: from smtp.gentoo.org ([127.0.0.1]) by localhost (smtp.gentoo.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id sp+MdKKrZFoH for ; Tue, 23 Aug 2011 06:49:02 +0000 (UTC) Received: from lo.gmane.org (lo.gmane.org [80.91.229.12]) by smtp.gentoo.org (Postfix) with ESMTP id BCC6D1B4003 for ; Tue, 23 Aug 2011 06:49:01 +0000 (UTC) Received: from list by lo.gmane.org with local (Exim 4.69) (envelope-from ) id 1QvknA-0005Ny-JL for gentoo-user@gentoo.org; Tue, 23 Aug 2011 08:48:56 +0200 Received: from athedsl-372294.home.otenet.gr ([79.131.6.68]) by main.gmane.org with esmtp (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Tue, 23 Aug 2011 08:48:56 +0200 Received: from realnc by athedsl-372294.home.otenet.gr with local (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Tue, 23 Aug 2011 08:48:56 +0200 X-Injected-Via-Gmane: http://gmane.org/ To: gentoo-user@lists.gentoo.org From: Nikos Chantziaras Subject: [gentoo-user] Re: Per-package splitdebug FEATURE Date: Tue, 23 Aug 2011 09:49:05 +0300 Organization: Lucas Barks Message-ID: References: Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-Id: Gentoo Linux mail X-BeenThere: gentoo-user@lists.gentoo.org Reply-to: gentoo-user@lists.gentoo.org Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Complaints-To: usenet@dough.gmane.org X-Gmane-NNTP-Posting-Host: athedsl-372294.home.otenet.gr User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:6.0) Gecko/20110822 Thunderbird/6.0 In-Reply-To: X-Archives-Salt: X-Archives-Hash: f456c607cb337b10fd0a8afec7bc4712 On 08/23/2011 09:17 AM, Leonardo Guilherme wrote: > Hi. > > I've turned on splitdebug feature (and -ggdb in CFLAGS) so debug > information are saved and I can debug anything that crashes. I went to > /usr/lib/debug, just out of curiosity, to see how much space was taken > and I found that it was almost 2GB, which chromium + firefox adds up > 1.5GB and python gets another 0.3. I would like to disable splitdebug > for these specific packages now and in the future, so removing > splitdebug from features, re-emerging them and then activating > splitdebug again won't quite cut. > > I wonder if there's a way to active features to some specific > packages, just like USE flags. There is. And it's a very powerful one even. First, remove -ggdb (I use just -g though; if you don't need the extra info -ggdb gives, plain -g will save you some space and time) from your CFLAGS and splitdebug from your FEATURES in make.conf. Then, create a file: /etc/portage/env/splitdebug.conf with the following contents: CFLAGS="${CFLAGS} -ggdb" CXXFLAGS="${CXXFLAGS} -ggdb" FEATURES="${FEATURES} splitdebug" Now, in /etc/portage/package.env, you can "execute" splitdebug.conf for the packages you want. My package.env for example looks like: sys-libs/glibc splitdebug.conf media-libs/mesa splitdebug.conf kde-base/kdelibs splitdebug.conf kde-base/kwin splitdebug.conf The result is that, for example, when glibc is emerged, splitdebug.conf is executed which adds -ggdb to CFLAGS and CXXFLAGS (do not forget CXXFLAGS!) and splitdebug to FEATURES. As you can guess, you can create arbitrary .conf files like this; it isn't in any way specific to splitdebug.