UP | HOME
Sachin Patil

Sachin Patil

Free Software Developer | GNU Emacs Hacker

Very happy with Emacs pretest
Published on Apr 17, 2016 by Sachin.

Table of Contents

Testing the pretest version

I decided to use the pretest version of Emacs instead of a stable release and so far it turned out to be a pleasant experience.

Emacs pretest

Figure 1: Emacs pretest

For those who don’t have any idea, you can visit http://alpha.gnu.org/gnu/emacs/pretest/] and download the latest version. Compiling and using should not be a problem. But still for newcomers, following are the steps:

  • Download and extract the latest pretest version.

    1: wget -Nc --show-progress http://alpha.gnu.org/gnu/emacs/pretest/emacs-25.0.92.tar.xz
    2: tar xvJf emacs-25.0.92.tar.xz
    
  • Configure and compile.

    cd emacs-25-0.92
    

    Make sure you have `/opt/emacs-pretest` directory present.

    sudo mkdir -p /opt/emacs-pretest
    

    Configure the build environment

    ./configure --prefix=/opt/emacs-pretest --host=x86_64-fedora23-linux-gnu
    

    Build from source

    make
    

    make will take time depending on your system specs

    If you are unaware of the flags:

    • --prefix makes sure that the final binary(with directory structure) will be copied inside /opt/emacs-pretest/ when you run make install
    • --host ensures that when you do M-x version, it should return x86_64-fedora23-linux-gnu instead of x86_64-unknown-linux-gnu. Feel free to experiment but make sure the string ends with ’linux’ or ’gnu’.

      If the make is successful, you can go head and try the build using.

      src/emacs
      

      Now try querying the version within Emacs.

      M-x version
      
  • Install

    Try out Emacs with your custom configuration. When you are happy, you can proceed toward installation.

    sudo make install
    

    Emacs binary will reside in /opt/emacs-pretest/bin/emacs. This is symbolic link to the file /opt/emacs-pretest/bin/emacs-25.0.92

If everything goes well, you can add this binary to your launch application or just create a desktop shortcut.

You should keep the stable version of Emacs as a backup. Till now, I never faced any problem and will continue using Emacs-pretest as my default.

If you encounter any issues during make, make sure you have all dependencies installed. If you think, there is an issue in the pretest release and needs to be fixed, make sure that it is reproducible before notifying emacs-devel@gnu.org. You can also ask for help on IRC at freenode, channel #emacs.

Updates (June 26, 2019)

I use most recent version of GNU/Emacs available from the master branch. Below are the steps:

1: git clone https://git.savannah.gnu.org/git/emacs.git  # use `--depth 1` if you don't want to pull entire history
2: make clean all
3: ./configure --host=x86_64-fedora-gnu --with-mailutils --prefix=$HOME/source/emacs/build --bindir=$HOME/bin
4: make -j 4
5: make install

Below is the Desktop entry:

 1: [Desktop Entry]
 2: Name=Emacs-BleedingEdge
 3: GenericName=Text Editor
 4: Comment=Text editing
 5: MimeType=text/english;text/plain;text/x-makefile;text/x-c++hdr;text/x-c++src;text/x-chdr;text/x-csrc;text/x-java;text/x-moc;text/x-pascal;text/x-tcl;text/x-tex;application/x-shellscript;text/x-c;text/x-c++;
 6: Exec=/home/psachin/bin/emacs %f
 7: Icon=emacs
 8: Type=Application
 9: Terminal=false
10: Categories=Utility;TextEditor;X-Red-Hat-Base;
11: StartupWMClass=Emacs
12: X-Desktop-File-Install-Version=0.22

Fedora 31 notes(Sep 07, 2020)

  • Install required packages

    1: dnf install autoconf
    2: dnf install texinfo
    3: dnf install libXpm-devel libjpeg-turbo-devel
    4: dnf install libxml2-devel
    5: dnf install giflib-devel gnutls-devel
    6: dnf install ncurses-devel
    7: dnf install gtk3-devel
    
  • Clone repos

    1: cd $HOME/source
    2: git clone https://github.com/emacs-mirror/emacs.git --depth 2
    3: cd emacs
    4: 
    5: # To display ERC channel name in the desktop notification(Optional)
    6: git remote add psachin https://github.com/psachin/emacs.git
    7: git fetch psachin --depth 2
    8: git checkout -b erc-show-channel-in-notification psachin/erc-show-channel-in-notification
    9: git rebase master
    
  • Compile

    1: mkdir build
    2: mkdir $HOME/bin
    3: 
    4: ./autogen.sh
    5: ./configure --host=x86_64-fedora31-gnu --with-mailutils --prefix=$HOME/source/emacs/build --bindir=$HOME/bin --with-x-toolkit=yes
    6: make -j 10
    7: make install