Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
[optimisation ebuild] Filtre des ldflags
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index French
View previous topic :: View next topic  
Author Message
Prodigy44
Apprentice
Apprentice


Joined: 19 Sep 2003
Posts: 231
Location: Nantes, France

PostPosted: Thu Aug 11, 2005 10:24 am    Post subject: [optimisation ebuild] Filtre des ldflags Reply with quote

Bon alors voila, je trouve que les LDFLAGS accelerent largement gnome, j'utilise les LDFLAGS suivant :
Code:

LDFLAGS="-Wl,-O1 -Wl,--as-needed"

Mais voila quand on fait un bootstrap et emerge system et un emerge gnome tout ce passe bien sauf pour quelques paquets dont voici une liste non exaustive :
Code:

dev-libs/libcroco-0.6.0
sys-apps/dbus-0.23.4-r1
app-text/openjade-1.3.2-r1
evolution
media-video/totem-1.0.4
net-misc/vino-2.10.0
gnome-base/gnome-applets-2.10.1
gnome-extra/gnome-media-2.10.2
media-sound/sound-juicer-2.10.1
app-admin/gnome-system-tools-1.2.0-r1
gnome-base/gdm-2.6.0.9-r3
app-text/evince-0.3.2


Voila je me disais, que ce serait sympa de filtrer les LDFLAGS pour ces paquets en particulier a la maniere d'openoffice. Il existe donc pour cela la classe flag-o-matic (/usr/portage/eclass) et en plus les fonctions filter-flags et également filter-ldflags. J'ai donc modifié le paquet et le voici : (vous trouverez en gras ce qui a été modifié)
Quote:

# Copyright 1999-2005 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
# $Header: /var/cvsroot/gentoo-x86/media-video/totem/totem-1.0.4.ebuild,v 1.1 2005/07/14 09:46:16$
inherit gnome2 eutils flag-o-matic

DESCRIPTION="Media player for GNOME"
HOMEPAGE="http://gnome.org/projects/totem/"

LICENSE="GPL-2"
SLOT="0"
KEYWORDS="~alpha ~amd64 ~hppa ~ia64 ~ppc ~ppc64 ~sparc ~x86"
IUSE="gnome xine lirc mad mpeg ogg vorbis a52 flac theora dvd debug win32codecs xv"

RDEPEND=">=dev-libs/glib-2.6.3
>=x11-libs/gtk+-2.6
>=gnome-base/gnome-vfs-2.2
>=gnome-base/libglade-2
>=gnome-extra/nautilus-cd-burner-2.9
>=gnome-base/gnome-desktop-2.2
>=gnome-base/libgnomeui-2.4
gnome? ( >=gnome-base/nautilus-2.10 )
lirc? ( app-misc/lirc )
!sparc? ( xine? ( >=media-libs/xine-lib-1
>=gnome-base/gconf-2 ) )
!xine? ( >=media-libs/gstreamer-0.8.9-r3
>=media-libs/gst-plugins-0.8.8
>=media-plugins/gst-plugins-gnomevfs-0.8.8
xv? ( >=media-plugins/gst-plugins-xvideo-0.8.8 )
>=media-plugins/gst-plugins-pango-0.8.8
>=media-plugins/gst-plugins-ffmpeg-0.8.3
mad? ( >=media-plugins/gst-plugins-mad-0.8.8 )
mpeg? ( >=media-plugins/gst-plugins-mpeg2dec-0.8.8 )
ogg? ( >=media-plugins/gst-plugins-ogg-0.8.8 )
vorbis? ( >=media-plugins/gst-plugins-ogg-0.8.8
>=media-plugins/gst-plugins-vorbis-0.8.8 )
a52? ( >=media-plugins/gst-plugins-a52dec-0.8.8 )
flac? ( >=media-plugins/gst-plugins-flac-0.8.8 )
theora? ( >=media-plugins/gst-plugins-ogg-0.8.8
>=media-plugins/gst-plugins-theora-0.8.8 )
mad? ( >=media-plugins/gst-plugins-mad-0.8.8 )
dvd? ( >=media-plugins/gst-plugins-a52dec-0.8.8
>=media-plugins/gst-plugins-dvdread-0.8.8
>=media-plugins/gst-plugins-mpeg2dec-0.8.8 )
win32codecs? ( >=media-plugins/gst-plugins-pitfdll-0.8.1 )
)
!gnome-extra/nautilus-media"

DEPEND="${RDEPEND}
app-text/scrollkeeper
>=dev-util/intltool-0.29
>=dev-util/pkgconfig-0.12.0"

DOCS="AUTHORS ChangeLog COPYING README INSTALL NEWS TODO"
# gstreamer is default backend
use xine || G2CONF="${G2CONF} --enable-gstreamer"
use sparc && G2CONF="${G2CONF} --enable-gstreamer"

# gtk only support broken
#use gnome \
# && G2CONF="${G2CONF} --disable-gtk" \
# || G2CONF="${G2CONF} --enable-gtk"

G2CONF="${G2CONF} \
$(use_enable lirc) \
$(use_enable debug) \
$(use_enable gnome nautilus) \
--disable-gtk \
--disable-mozilla"

src_compile() {
elibtoolize ${ELTCONF}
use debug && G2CONF="${G2CONF} --enable-debug=yes"

# doc keyword for gtk-doc
G2CONF="${G2CONF} $(use_enable doc gtk-doc)"

econf "$@" ${G2CONF} || die "./configure failure"

filter-ldflags "-Wl,-O1 -Wl,--as-needed"
emake || die "compile failure"
}


src_unpack() {

unpack ${A}

cd ${S}
# use the omf_fix for scrollkeeper sandbox
gnome2_omf_fix
}

pkg_postinst() {

gnome2_pkg_postinst

einfo "Note that the default totem backend has switched to gstreamer."
einfo "DVD menus will only work with the xine backend."

}

USE_DESTDIR="1"


Mais apparement les LDFLAGS ne sont pas filtrés, j'ai essayé aussi avec filter-flags "-Wl,-O1 -Wl,--as-needed" et toujours pas ...
_________________
Apporter votre contribution au libre : http://fr.wikipedia.org
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index French 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