Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
Applying custom patches to packages
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Portage & Programming
View previous topic :: View next topic  
Author Message
sawanv
Apprentice
Apprentice


Joined: 05 Dec 2002
Posts: 238

PostPosted: Sat Oct 25, 2003 4:20 pm    Post subject: Applying custom patches to packages Reply with quote

Hello All.

I want to apply a patch to a package before its installed by portage (these patches http://www.cs.mcgill.ca/~dchest/xfthack/ , to freetype).

By the way, the patch gives unbeliveable fonts on KDE. Its simply brilliant.

How do I go about this?

Thanks
_________________
Eir kahen "chalo ghar jayen",
Bir kahen "chalo ghar jayen",
Phatte kahen "chalo ghar jayen",
Cartman kahen....."Screw you guys, I am going home !!! "
Back to top
View user's profile Send private message
tomchuk
Guru
Guru


Joined: 23 Mar 2003
Posts: 317
Location: Brooklyn, NY

PostPosted: Sat Oct 25, 2003 6:57 pm    Post subject: Reply with quote

sawanv,

Those patches are against freetype 2.1.5, the current freetype in portage is 2.1.4. So you'd have to download freetype 2.1.5, unpack it, apply the patch, and configure, make, and make install.

But being interesting in having a bit softer fonts in kde as well, I did all the work for you. Here is a tarball with a modified freetype-2.1.4-r1 ebuild, the modified patches and the portage directory structure (media-libs/freetype).

Make sure that PORTDIR_OVERLAY is set in /etc/make.conf and cd into PORTDIR_OVERLAY (I use /usr/local/portage) untar the archive (tar -xjvf /path/to/freetype-2.1.4-r1.tar.bz2) and then cd media-libs/freetype. Just type emerge freetype-2.1.4-r1.ebuild and the new freetype will be installed.

You'll have to stop X, restart /etc/init.d/xfs (I think) and restart X. And you'll have nice soft fonts.

And thanks for pointing me to this patch, I've been dieing for nice smooth fonts in KDE (more like the smoothing available in gnome).
Back to top
View user's profile Send private message
sawanv
Apprentice
Apprentice


Joined: 05 Dec 2002
Posts: 238

PostPosted: Sun Oct 26, 2003 8:39 am    Post subject: Reply with quote

Hello tomchuk.

Thanks for all your work. Will try out your stuff and let you know how it turns out, and if the result is as better as the previous patch.

Will post later...

Sawan
_________________
Eir kahen "chalo ghar jayen",
Bir kahen "chalo ghar jayen",
Phatte kahen "chalo ghar jayen",
Cartman kahen....."Screw you guys, I am going home !!! "
Back to top
View user's profile Send private message
TheCoop
Veteran
Veteran


Joined: 15 Jun 2002
Posts: 1814
Location: Where you least expect it

PostPosted: Sun Oct 26, 2003 9:19 pm    Post subject: Reply with quote

well you can manually patch programs by typing
Code:
ebuild <ebuildfile> unpack
cd /var/tmp/portage/<package>/work/<package>
patch -p1 < <patch>
ebuild <ebuildfile> compile
ebuild <ebuildfile> merge
ebuild <ebuildfile> qmerge

or something like that...
_________________
95% of all computer errors occur between chair and keyboard (TM)

"One World, One web, One program" - Microsoft Promo ad.
"Ein Volk, Ein Reich, Ein Führer" - Adolf Hitler

Change the world - move a rock
Back to top
View user's profile Send private message
BitJam
Advocate
Advocate


Joined: 12 Aug 2003
Posts: 2508
Location: Silver City, NM

PostPosted: Sun Oct 26, 2003 11:56 pm    Post subject: Reply with quote

I tried the new ebuild and it worked as advertised. I particularly liked the effect on my semi-transparent pulldown menus.

But pehaps due to the LCD display on my laptop, the softer edges caused some minor but annoying color fringing which induced me to revert back to the lastest stable version of freetype. YMMVG.
Back to top
View user's profile Send private message
tomchuk
Guru
Guru


Joined: 23 Mar 2003
Posts: 317
Location: Brooklyn, NY

PostPosted: Mon Oct 27, 2003 12:03 am    Post subject: Reply with quote

Very true, I've got one LCD and 2 CRTs (one of which is very fuzzy). I can't decide if I like being able to easily read an 8 point font on a 17" CRT @ 1280x1024, or having crisp, readable fonts on my LCD. Oh well, I'll stick with it for now.

Definately give this a shot with a CRT though.
Back to top
View user's profile Send private message
sawanv
Apprentice
Apprentice


Joined: 05 Dec 2002
Posts: 238

PostPosted: Wed Oct 29, 2003 11:53 am    Post subject: Brilliant Reply with quote

Hello Guys.

I tried the patch and it works brilliantly!! :lol:

Very nice fonts....I think these are the best fonts I have seen anywhere (maybe beats even OSX Jaguar, dont know about Panther) 8) .

What is the mechanism by which we can make this the standard part of the freetype distribution on Gentoo? I thought we could propose an enhancement on Bugzilla or somewhere, or is it possible to contact the developer directly?

Any ideas?

Sawan
_________________
Eir kahen "chalo ghar jayen",
Bir kahen "chalo ghar jayen",
Phatte kahen "chalo ghar jayen",
Cartman kahen....."Screw you guys, I am going home !!! "
Back to top
View user's profile Send private message
BitJam
Advocate
Advocate


Joined: 12 Aug 2003
Posts: 2508
Location: Silver City, NM

PostPosted: Wed Oct 29, 2003 3:10 pm    Post subject: Re: Brilliant Reply with quote

sawanv wrote:
What is the mechanism by which we can make this the standard part of the freetype distribution on Gentoo?


We need to make sure that this font option remains optional so that people like myself, who use lcd screens can choose to keep fonts with a crisp outline.
Back to top
View user's profile Send private message
tomchuk
Guru
Guru


Joined: 23 Mar 2003
Posts: 317
Location: Brooklyn, NY

PostPosted: Wed Oct 29, 2003 4:42 pm    Post subject: Reply with quote

I've gone back to the unpatched freetype, as I couldn't justify dealing with crappy fonts on my $1000 LCD, but having nice fonts on each of my $300 CRTs. When freetype 2.1.5 becomes available (which will contain most of these patches), I'll post back here with an updated ebuild.
Back to top
View user's profile Send private message
sawanv
Apprentice
Apprentice


Joined: 05 Dec 2002
Posts: 238

PostPosted: Thu Oct 30, 2003 6:51 am    Post subject: Reply with quote

Quote:
We need to make sure that this font option remains optional so that people like myself, who use lcd screens can choose to keep fonts with a crisp outline.

Hmmm.....I agree with that, specially as LCDs are become more pervasive.

Tom, are the fonts really that bad on LCDs? Can you post a shot or something?

Thanks

Sawan
_________________
Eir kahen "chalo ghar jayen",
Bir kahen "chalo ghar jayen",
Phatte kahen "chalo ghar jayen",
Cartman kahen....."Screw you guys, I am going home !!! "
Back to top
View user's profile Send private message
tomchuk
Guru
Guru


Joined: 23 Mar 2003
Posts: 317
Location: Brooklyn, NY

PostPosted: Thu Oct 30, 2003 7:45 am    Post subject: Reply with quote

Well a screenshot won't do anything :) When I get a chance I'll reinstall the patched version and take a couple macro shots with my digicam comparing some text on both my CRT and LCD with the patch and without.
Back to top
View user's profile Send private message
nordic bro
Guru
Guru


Joined: 25 Oct 2003
Posts: 585

PostPosted: Mon Nov 03, 2003 12:05 am    Post subject: Reply with quote

TheCoop wrote:
well you can manually patch programs by typing
Code:
ebuild <ebuildfile> unpack
cd /var/tmp/portage/<package>/work/<package>
patch -p1 < <patch>
ebuild <ebuildfile> compile
ebuild <ebuildfile> merge
ebuild <ebuildfile> qmerge

or something like that...


For the "ebuild <ebuildfile> unpack" part, where do I get the ebuildfile name from? I checked in distfiles and my portage tmp dir and there's no "ebuild" to be found. I also looked in /var/log/portage at the completed compile log and there's no ebuild reference there either.

I want to patch x11-misc/goats (r2.2) and I can't get started. These fail:

ebuild goats-2.2 unpack
ebuild goats-2.2.ebuild unpack
ebuild goats unpack
ebuild goats.ebuild unpack

They all say the same thing:

!!! doebuild: goats.ebuild not found for unpack


Mike
Back to top
View user's profile Send private message
Genone
Retired Dev
Retired Dev


Joined: 14 Mar 2003
Posts: 9530
Location: beyond the rim

PostPosted: Mon Nov 03, 2003 12:20 am    Post subject: Reply with quote

the ebuilds are in subdirectories in /usr/portage. The latest gentoolkit has a new tool ewhich that can be used to get the ebuild filename for a given package name.
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Portage & Programming 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