Arch Installation

Nadrin edited this page Oct 31, 2011 · 6 revisions

Installing from AUR

Install xlsh-git package from AUR (http://aur.archlinux.org/packages.php?ID=53520). If you do so please remember to replace every instance of /usr/local with /usr when following configuration instructions.

Building and installing manually

You will need gcc, make, pam and readline packages installed (all are in core). For xlshd install additional dependencies:

$ pacman -S xterm xdotool xorg-xsetroot xorg-xwininfo xorg-xmessage xorg-xrdb

Now clone the git repository:

$ git clone https://github.com/Nadrin/xlsh.git
$ cd xlsh

Before you proceed you may want to tweak include/config.h or Makefile to suit your needs. Please note that in this guide I assume default values. Now it's time to compile and install:

$ make
$ make install #(as root)

If everything during compilation went fine you should now have XLSH installed.

Configuring XLSH as /bin/login replacement

Edit /etc/inittab file and replace default agetty invocations on all virtual consoles with:

c1:2345:respawn:/sbin/agetty -8 -s 38400 -n -l /usr/local/sbin/xlsh tty1 linux
c2:2345:respawn:/sbin/agetty -8 -s 38400 -n -l /usr/local/sbin/xlsh tty2 linux
c3:2345:respawn:/sbin/agetty -8 -s 38400 -n -l /usr/local/sbin/xlsh tty3 linux
c4:2345:respawn:/sbin/agetty -8 -s 38400 -n -l /usr/local/sbin/xlsh tty4 linux
c5:2345:respawn:/sbin/agetty -8 -s 38400 -n -l /usr/local/sbin/xlsh tty5 linux
c6:2345:respawn:/sbin/agetty -8 -s 38400 -n -l /usr/local/sbin/xlsh tty6 linux

Configuring XLSH as display manager replacement

Edit /etc/inittab file and specify xlshd as default login manager for runlevel 5 (remember to keep the -f flag so it won't fork into background):

# Example lines for starting a login manager
x:5:respawn:/usr/local/sbin/xlshd -f

You may also want to set runlevel 5 as default. More information on configuring init can be found at: https://wiki.archlinux.org/index.php/Init_and_inittab

Default X session

xlsh will, by default, execute /bin/sh .xsession if no other window manager is specified via an argument to login command. Arch Linux's default .xsession file for each user executes .xinitrc with a login shell. Edit .xinitrc to set your default window manager.

Example .xinitrc file (featuring Awesome WM):

#!/bin/sh
setxkbmap pl
nvidia-settings -l
gnome-settings-daemon
exec awesome