Emacs nighly cvs snapshot with xft on Ubuntu Edgy

I wanted to try the latest cvs snapshot with XFT support, since i did not want to screw up more my workstation i have used packages instead of make install blindy.

Basically i have a script called ./build.sh

#!/bin/bash
set -e
 
d=$(date '+%Y%m%d')
debpatch=20061218-1
 
mkdir -p cvs
 
pushd cvs >/dev/null && {
cvs -Q -z3 -d:pserver:anonymous@cvs.savannah.gnu.org:/sources/emacs co -r emacs-unicode-2 emacs
} && popd >/dev/null
 
mkdir -p build
[[ -d build/emacs-${d} ]] && rm -rf build/emacs-${d}
cp -al cvs/emacs build/emacs-${d}
 
zcat patches/emacs-snapshot_${debpatch}.diff.gz|patch -p1 -d build/emacs-${d}
cat patches/with-font.patch|patch --silent -p1 -d build/emacs-${d}
 
pushd build/emacs-${d} >/dev/null && {
    chmod +x debian/rules
    dch -v "1:${d}-1" "New snapshot."
    dch "Build with xft."
    fakeroot dpkg-buildpackage -b
} && popd >/dev/null

in patches/with-font.patch i have :

--- c/debian/rules.chmou        2007-01-21 23:21:09.486353750 +1100
+++ c/debian/rules      2007-01-21 23:21:13.914630500 +1100
@@ -393,7 +393,7 @@
 # Emacs-gtk confflags
 emacs_gtk_confflags := ${confflags}
 emacs_gtk_confflags += --with-x=yes
-emacs_gtk_confflags += --with-x-toolkit=gtk
+emacs_gtk_confflags += --with-x-toolkit=gtk  --enable-font-backend --with-xft
 
 # Emacs-nox confflags
 emacs_nox_confflags := ${confflags}
--- c/src/emacs.c.chmou 2007-01-21 23:21:09.486353750 +1100
+++ c/src/emacs.c       2007-01-21 23:22:18.430662500 +1100
@@ -1408,10 +1408,10 @@
     = argmatch (argv, argc, "-nl", "--no-loadup", 6, NULL, &skip_args);
 
 #ifdef USE_FONT_BACKEND
-  enable_font_backend = 0;
-  if (argmatch (argv, argc, "-enable-font-backend", "--enable-font-backend",
-               4, NULL, &skip_args))
     enable_font_backend = 1;
+  if (argmatch (argv, argc, "-disable-font-backend", "--disable-font-backend",
+               4, NULL, &skip_args))
+    enable_font_backend = 0;
 #endif /* USE_FONT_BACKEND */
 
 #ifdef HAVE_X_WINDOWS
@@ -1816,7 +1816,7 @@
   { "-unibyte", "--unibyte", 81, 0 },
   { "-no-multibyte", "--no-multibyte", 80, 0 },
   { "-nl", "--no-loadup", 70, 0 },
-  { "-enable-font-backend", "--enable-font-backend", 65, 0 },
+  { "-disable-font-backend", "--disable-font-backend", 65, 0 },
   /* -d must come last before the options handled in startup.el.  */
   { "-d", "--display", 60, 1 },
   { "-display", 0, 60, 1 },

i have as well in patches/ the ubuntu (or could be debian) patch downloaded from the ubuntu (or debian archive) archive which is for ubuntu on

http://archive.ubuntu.com/ubuntu/pool/universe/e/emacs-wiki

If there is a new version you will need to increase the version in build.sh to match the patch downloaded.

When running build.sh it should produce binary in build/* with xft enabled by default. Make sure to have all the dependencies (dpkg-buildpackages should tell you if there is unresovled one).

One screenshot :

Screenshot of Emacs snapshot with XFT

  • http://www.mememachinego.com/ Zed

    Where you refer to emacs-wiki at the end… did you mean one of the emacs-snapshot packages (and which one)?

  • http://www.chmouel.com/blog/ chmouel

    Hi Zed, i do not understand your questions, but if you are asking where can you find the emacs-snapshot packages, i am explaining how to compile them nightly on ubuntu. Let me know if you have problems with it.

    Cheers, Chmouel.

  • http://www.mememachinego.com/ Zed

    You refer to including a patch from, specifically, the emacs-wiki package. I was guessing you might have cut and pasted the wrong URL and you meant a patch from an emacs-snapshot package.

  • gallows
  • gallows

    Anyway (IMHO) isn’t a good idea to use that patch (ubuntu diff) against the *last* emacs’ snapshot from cvs.
    That patch was wrote for the 20061218 snapshot and should be used _only_ against that source (emacs-snapshot_20061218.orig.tar.gz ), because the last snapshot might be very different and incompatible.

    However thanks for posting that :)

  • http://peadrop.com Alexandre Vassalotti

    Your method will eventually screw up. As gallows said, the patch will need to be updated at some point. I maintain a Ubuntu Edgy package of the Unicode branch; and about once per month I need to merge the changes from Debian, because the patches breaks. So, your mileage may vary.

    I suggest you to use my packages, which you probably already know of (I recognize my little –disable-font-backend hack :P ). I update it about once per week. The instructions, how to use it, are at: http://peadrop.com/blog/category/computers/emacs/

  • http://www.chmouel.com/blog/ chmouel

    Hi Alexandre,

    Yeah my method would probably screwd up but it is just a matter to resynchronize the debian/ directory from testing (or drop/merge patches not a big deal)…

    No i did not look at all at the patches of your package i just did a blind grep -r and did a 2s hack (which actually does not compile theses days and i have dropped it since i do not really care about disabling the font backend).

    Cheers, Chmouel.

  • http://www.drinkingwaterfiltershop.com Samantha Mathews

    The method by Alexandre will be easy to newbie like me.
    Thanks to you Chomuel, anyway.

  • GYRAM’s ORGICO!

    Look what happens in four years…..you are going to be in a MOVIE!
    It’s for all the FOCK WORMS you FOCKED !
    And DOT in HERSEDOT and RICK in HERSEPRIC are giving the books and the NUMBERS!
    That means EL SALVADOR – RIO- YEMEN- ” assholes”!!!!
    And that means POKETOT!
    JEB BUSH and KARL ROVE with RON HEVENER and MARTIN ROPER have got a very Harry with Larry!
    ” MOTHER JONES” is what they say.
    And CARTER just had an ODESSE – CODESSE- SESSPE!
    Like GUY HURE!

  • BUNNYTALES

    CHOMUEL?
    This the CHO that’s into AK’s ?
    And Massachusetts U?
    That is El Salvador is what we hear.
    You also do chocolate with IRENE?
    LA?
    I LOVE CRAFTS?

  • Roperdoper

    Gayle MANCHIN culls with WASHINGTON Senators…CHILDREN?
    There are physicians into organ harvesting and they got some names like BUNN- BALL- ROSS?
    GREDARK is with the QUEEN?
    REDPATH?
    IRA?
    RICK?
    KANSAS?
    This is why there is that movie being made?
    ” KANSAS KINGS”?
    I thought it was supposed to be about GREYHOUNDS?
    And now it’s about the DUKE?
    COLLARS?
    RACES?
    OMG!

  • DEFASTOSHOLACO

    Zetas are now BOOZIN.
    Newfoundland found her Queen.