From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 29111 invoked from network); 19 Sep 2004 19:32:34 +0000 Received: from smtp.gentoo.org (156.56.111.197) by lists.gentoo.org with AES256-SHA encrypted SMTP; 19 Sep 2004 19:32:34 +0000 Received: from lists.gentoo.org ([156.56.111.196] helo=parrot.gentoo.org) by smtp.gentoo.org with esmtp (Exim 4.41) id 1C97QQ-00074H-Aj for arch-gentoo-dev@lists.gentoo.org; Sun, 19 Sep 2004 19:32:42 +0000 Received: (qmail 14380 invoked by uid 89); 19 Sep 2004 19:32:33 +0000 Mailing-List: contact gentoo-dev-help@gentoo.org; run by ezmlm Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-Id: Gentoo Linux mail X-BeenThere: gentoo-dev@gentoo.org Received: (qmail 16359 invoked from network); 19 Sep 2004 19:32:33 +0000 From: Dan Armak Reply-To: danarmak@gentoo.org Organization: Gentoo Technologies, Inc. To: gentoo-dev@lists.gentoo.org Date: Sun, 19 Sep 2004 22:33:34 +0300 User-Agent: KMail/1.7 References: <200409180057.34014.anthony@ectrolinux.com> <200409191748.28063.danarmak@gentoo.org> <200409192008.23813.simone.gotti@email.it> In-Reply-To: <200409192008.23813.simone.gotti@email.it> MIME-Version: 1.0 Content-Type: multipart/signed; boundary="nextPart3087422.jN0Gl1IE8J"; protocol="application/pgp-signature"; micalg=pgp-sha1 Content-Transfer-Encoding: 7bit Message-Id: <200409192233.39105.danarmak@gentoo.org> Subject: Re: [gentoo-dev] Segregating KDE? X-Archives-Salt: b0d5a03a-7e4c-44fc-8ae0-ac9e01bb3f4b X-Archives-Hash: a66c700a98dd60b87eebd0c0f7e21bec --nextPart3087422.jN0Gl1IE8J Content-Type: multipart/mixed; boundary="Boundary-01=_O8dTBhTuOqEONwy" Content-Transfer-Encoding: 7bit Content-Disposition: inline --Boundary-01=_O8dTBhTuOqEONwy Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable Content-Disposition: inline On Sunday 19 September 2004 21:08, Simone Gotti wrote: > By the way, I think that it's possible to split EVERY kde program/libs in= a > single package, this can be possibile by heavily patching the Makefiles > like you've said so they can link to an installed lib instead of the local > one, this libs will be a dep of the program and it should be of course a > different ebuild. It's certainly possible. I even think (well, intuition...) the patching won= 't=20 have to be very heavy. > > I'm already giving a little help to caleb and carlo on the kde ebuilds and > if ypu and they think that a lot of people thinks that having single kde > programs instead of the standard modules will be a better idea I'll be VE= RY > happy to start hacking on this. My great fear is that it will slow down t= he > development of the ebuilds because this bring to a lot of additional work! > Think that probably the Makefile's patches must be changed on every kde > major release. > > All I need is to know if you (gentoo kde developers) are really interested > on this work. Let me know! As I said, I'm definitely going to try making this work, but won't have rea= l=20 time until the weekend after next (and most days after that, hopefully), so= =20 you can beat me to it. I've just tried the confcache patch. It's integrated into portage .51 cvs=20 snapshots here http://dev.gentoo.org/~ferringb/ebuild-daemon/51-pre20-cvs/ = =2D=20 they apparently include other highly experimental stuff and the last one ha= s=20 some bugs already fixed in cvs, so be in touch with #gentoo-portage if usin= g=20 these. To enable confcache, add 'confcache' to FEATURES and change the kde= =20 ebuilds to use econf rather than call configure directly. This results in t= he=20 kde.eclass attached - the change is trivial, but as I'm on rsync not cvs at= m,=20 I can't make a diff immediately, sorry. The change for split packages shoul= d=20 also be on the order of a five-liner in kde.eclass, apart from the makefile= =20 changes. On my athlon xp 2600, this makes the kdelibs configure run go down from 66= =20 seconds to 28 seconds. At least 10-12 seconds of each of these two numbers = is=20 due to makefile generation, which will be very much reduced in split-up=20 ebuilds, so we get 54 sec -> 16 sec, or a 5x improvement. Also, on slower machines a far larger percent of time spent in (non-cached)= =20 configure is due to slow compilations rather than (as here) IO, so the=20 benefit will be even greater there. This indicates we should at least=20 reevluate the emerge performance factor of splitting up the kde ebuilds. Using my old rough formula, we get: 17 configure scripts (before splitting ebuilds) --> 20-60 minutes total=20 running time splitting up --> >=3D220 packages (? but at least that many, I believe) splitting up without confcache --> 220-660 minutes, i.e. 3.6-11 hours, tota= l=20 running time (clearly unacceptable) splitting up with confcache --> about 15-20% of above, i.e. 1-2.2 hours tot= al=20 running time According to these numbers, if we both add confcache and split the ebuilds,= =20 the total time for emerging all or nearly all of kde will increase by 0.6-1= =2E2=20 hours, plus the overhead from running the emerge cycle 200 more times, whic= h=20 I hope is relatively negligible (a few minutes?).=20 Compared with the benefits (to those who don't want all of kde, and=20 considering that >95% of people typing 'emerge kde' to save package selecti= on=20 time don't really want kdetoys and kdeedu and such, this seems on first sig= ht=20 to be a reasonable tradeoff for the added functionality. What do you think,= =20 everyone? Also note that my benchmarking is hardly scientific, so I'd be gl= ad=20 if someone bothered to repeat it and compare his results to mine. =2D-=20 Dan Armak Gentoo Linux developer (KDE) Matan, Israel Public GPG key: http://dev.gentoo.org/~danarmak/danarmak-gpg-public.key =46ingerprint: DD70 DBF9 E3D4 6CB9 2FDD 0069 508D 9143 8D5F 8951 --Boundary-01=_O8dTBhTuOqEONwy Content-Type: text/plain; charset="iso-8859-1"; name="kde.eclass" Content-Transfer-Encoding: quoted-printable Content-Disposition: attachment; filename="kde.eclass" # Copyright 1999-2004 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 # $Header: /var/cvsroot/gentoo-x86/eclass/kde.eclass,v 1.106 2004/09/15 23:= 10:21 kugelfang Exp $ # # Author Dan Armak # # Revisions Caleb Tennis # The kde eclass is inherited by all kde-* eclasses. Few ebuilds inherit st= raight from here. inherit base eutils kde-functions ECLASS=3Dkde INHERITED=3D"$INHERITED $ECLASS" DESCRIPTION=3D"Based on the $ECLASS eclass" HOMEPAGE=3D"http://www.kde.org/" IUSE=3D"${IUSE} debug arts" DEPEND=3D">=3Dsys-devel/automake-1.7.0 sys-devel/autoconf sys-devel/make dev-util/pkgconfig dev-lang/perl ~kde-base/kde-env-3" RDEPEND=3D"~kde-base/kde-env-3" # overridden in other places like kde-dist, kde-source and some individual = ebuilds SLOT=3D"0" kde_src_unpack() { debug-print-function $FUNCNAME $* =09 # call base_src_unpack, which implements most of the functionality and has= sections, # unlike this function. The change from base_src_unpack to kde_src_unpack = is thus # wholly transparent for ebuilds. base_src_unpack $* =09 # kde-specific stuff stars here =09 # fix the 'languageChange undeclared' bug group: touch all .ui files, so t= hat the # makefile regenerate any .cpp and .h files depending on them. cd $S debug-print "$FUNCNAME: Searching for .ui files in $PWD" UIFILES=3D"`find . -name '*.ui' -print`" debug-print "$FUNCNAME: .ui files found:" debug-print "$UIFILES" # done in two stages, because touch doens't have a silent/force mode if [ -n "$UIFILES" ]; then debug-print "$FUNCNAME: touching .ui files..." touch $UIFILES fi # shorthand for removing specified subdirectories fom the build process [ -n "$KDE_REMOVE_DIR" ] && kde_remove_dir $KDE_REMOVE_DIR } kde_src_compile() { debug-print-function $FUNCNAME $* [ -z "$1" ] && kde_src_compile all cd ${S} export kde_widgetdir=3D"$KDEDIR/$(get_libdir)/kde3/plugins/designer" # fix the sandbox errors "can't writ to .kde or .qt" problems. # this is a fake homedir that is writeable under the sandbox, so that the = build process # can do anything it wants with it. REALHOME=3D"$HOME" mkdir -p $T/fakehome/.kde mkdir -p $T/fakehome/.qt export HOME=3D"$T/fakehome" addwrite "${QTDIR}/etc/settings" # things that should access the real homedir [ -d "$REALHOME/.ccache" ] && ln -sf "$REALHOME/.ccache" "$HOME/"=09 [ -n "$UNSERMAKE" ] && addwrite "/usr/kde/unsermake" =09 while [ "$1" ]; do case $1 in myconf) debug-print-section myconf myconf=3D"$myconf --host=3D${CHOST} --prefix=3D${PREFIX} --with-x --ena= ble-mitshm --with-xinerama --with-qt-dir=3D${QTDIR} --enable-mt" # calculate dependencies separately from compiling, enables ccache to w= ork on kde compiles [ -z "$UNSERMAKE" ] && myconf=3D"$myconf --disable-dependency-tracking" if use debug ; then myconf=3D"$myconf --enable-debug=3Dfull --with-debug" else myconf=3D"$myconf --disable-debug --without-debug" fi [ -z "$KDEBASE" ] && myconf=3D"$myconf $(use_with arts)" [ -n "$KDEBASE" -a "$KDEMINORVER" -ge 3 ] && myconf=3D"$myconf $(use_wi= th arts)" debug-print "$FUNCNAME: myconf: set to ${myconf}" ;; configure) debug-print-section configure debug-print "$FUNCNAME::configure: myconf=3D$myconf" # rebuild configure script, etc # This can happen with e.g. a cvs snapshot =09 if [ ! -f "./configure" ] || [ -n "$UNSERMAKE" ]; then for x in Makefile.cvs admin/Makefile.common; do if [ -f "$x" ] && [ -z "$makefile" ]; then makefile=3D"$x"; fi done if [ -f "$makefile" ]; then debug-print "$FUNCNAME: configure: generating configure script, runni= ng make -f $makefile" make -f $makefile fi [ -f "./configure" ] || die "no configure script found, generation uns= uccessful" fi export PATH=3D"${KDEDIR}/bin:${PATH}" =09 # configure doesn't need to know about the other KDEs installed. # in fact, if it does, it sometimes tries to use the wrong dcopidl, etc. # due to the messed up way configure searches for things export KDEDIRS=3D"${PREFIX}:${KDEDIR}" cd $S econf \ --mandir=3D${PREFIX}/share/man --infodir=3D${PREFIX}/share/info \ --datadir=3D${PREFIX}/share --sysconfdir=3D${PREFIX}/etc \ --localstatedir=3D${PREFIX}/var/lib \ ${myconf} \ --libdir=3D"\${exec_prefix}/$(get_libdir)" \ || die "died running ./configure, $FUNCNAME:configure" =09 # Seems ./configure add -O2 by default but hppa don't want that but we = need -ffunction-sections if [ "${ARCH}" =3D "hppa" ] then einfo Fixating Makefiles find ${S} -name Makefile | while read a; do sed -e s/-O2/-ffunction-se= ctions/ -i "${a}" ; done fi ;; make) export PATH=3D"${KDEDIR}/bin:${PATH}" debug-print-section make emake || die "died running emake, $FUNCNAME:make" ;; all) debug-print-section all kde_src_compile myconf configure make ;; esac shift done } kde_src_install() { debug-print-function $FUNCNAME $* [ -z "$1" ] && kde_src_install all cd ${S} while [ "$1" ]; do case $1 in make) debug-print-section make make install DESTDIR=3D${D} destdir=3D${D} || die "died running make in= stall, $FUNCNAME:make" ;; dodoc) debug-print-section dodoc for doc in AUTHORS ChangeLog* README* COPYING NEWS TODO; do [ -s "$doc" ] && dodoc $doc done ;; all) debug-print-section all kde_src_install make dodoc ;; esac shift done } EXPORT_FUNCTIONS src_unpack src_compile src_install --Boundary-01=_O8dTBhTuOqEONwy-- --nextPart3087422.jN0Gl1IE8J Content-Type: application/pgp-signature -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.2.6 (GNU/Linux) iD8DBQBBTd8TUI2RQ41fiVERAn+WAJsFgGGxEyueHsVqFJrnS6JkySjFuQCfT+zE bgKIk9zo2v0aQDmRTRtP4XI= =bFFw -----END PGP SIGNATURE----- --nextPart3087422.jN0Gl1IE8J--