DaemonForums  

Go Back   DaemonForums > Miscellaneous > Guides

Guides All Guides and HOWTO's.

 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
  #1   (View Single Post)  
Old 26th October 2009
vermaden's Avatar
vermaden vermaden is offline
Administrator
 
Join Date: Apr 2008
Location: pl_PL.lodz
Posts: 1,052
Thanked 118 Times in 93 Posts
Post HOWTO: xorg/x11 without hald/dbus and with CTRL-ALT-BACKSPACE working

There were many questions regarding the oldschool xorg/x11 setup without hald/dbus and with old usefull terminate method by ctrl-alt-backspace, here is a short howto how to achieve this.

1. Install FreeBSD along with x11/xorg or add it by package.
root # pkg_add -r xorg
1.1. Enable and start moused(8) daemon if you already do not have it running.
root # echo moused_enable=\"YES\" >> /etc/rc.conf
root # /etc/rc.d/moused start
2. Generate new config.
root # X -configure
3. Move config to its proper place.
root # mv /root/xorg.conf.new /usr/local/etc/X11/xorg.conf
4. Add needed options to config in sections ServerFlags and InputDevice.
root # vi /usr/local/etc/X11/xorg.conf

Code:
Section "ServerFlags"
  (...)
  Option "DontZap"         "off"
  Option "AllowEmptyInput" "off"
  Option "AutoAddDevices"  "off"
EndSection

Section "InputDevice"
  (...)
  Option "XkbOptions" "terminate:ctrl_alt_bksp"
EndSection


The following options are needed to have working x11 without hald/dbus:
Code:
Section "ServerFlags"
  (...)
  Option "AllowEmptyInput" "off"
  Option "AutoAddDevices"  "off"
EndSection


... and following for "three kings" or CTRL-ALT-BACKSPACE terminate keyboard shrtcut:
Code:
Section "ServerFlags"
  (...)
  Option "DontZap" "off"
EndSection

Section "InputDevice"
  (...)
  Option "XkbOptions" "terminate:ctrl_alt_bksp"
EndSection
5. Basic client configuration.
user % cat > ${HOME}/.xinitrc << EOF
xterm &
twm
EOF
6. Start x11/xorg.
user % xinit -- -dpi 75 -nolisten tcp
Example full xorg.conf config:
Code:
Section "ServerFlags"
  Option "DontZap"         "off"
  Option "AllowEmptyInput" "off"
  Option "AutoAddDevices"  "off"
EndSection

Section "InputDevice"
  Identifier "Keyboard0"
  Driver     "kbd"
  Option     "XkbOptions" "terminate:ctrl_alt_bksp"
EndSection

Section "ServerLayout"
  Identifier  "xorg0"
  Screen 0    "screen0"   0 0
  InputDevice "mouse0"    "CorePointer"
  InputDevice "keyboard0" "CoreKeyboard"
EndSection

Section "Module"
  Load "dbe"
  Load "dri"
  Load "extmod"
  Load "glx"
EndSection

Section "InputDevice"
  Identifier "mouse0"
  Driver     "mouse"
  Option     "Protocol"     "auto"
  Option     "Device"       "/dev/sysmouse"
  Option     "ZAxisMapping" "4 5 6 7"
EndSection

Section "Monitor"
  Identifier "monitor0"
  Option     "DPMS"
EndSection

Section "Device"
  Identifier "gfx0"
  Driver     "intel"
  Option     "DPMS"
EndSection

Section "Screen"
  Identifier "screen0"
  Device     "gfx0"
  Monitor    "monitor0"
  SubSection "Display"
    Modes "1440x900"
  EndSubSection
EndSection

Section "Files"
  ModulePath "/usr/local/lib/xorg/modules"
  FontPath   "/usr/local/lib/X11/fonts/misc/"
  FontPath   "/usr/local/lib/X11/fonts/TTF/"
  FontPath   "/usr/local/lib/X11/fonts/OTF"
  FontPath   "/usr/local/lib/X11/fonts/Type1/"
  FontPath   "/usr/local/lib/X11/fonts/100dpi/"
  FontPath   "/usr/local/lib/X11/fonts/75dpi/"
EndSection

For comparision, for OpenBSD its like that:

1. Install OpenBSD along with xenocara/x11.

2. Basic client configuration.
user % cat > ${HOME}/.xinitrc << EOF
xterm &
twm
EOF
3. Start x11/xorg.
user % xinit -- -dpi 75 -nolisten tcp


ADDED 2009/11/16
----------------

If you would like to disable CAPS LOCK key, then you should make the folllowing change in the xorg.conf file:

Code:
Section "InputDevice"
  Identifier "Keyboard0"
  Driver     "kbd"
- Option     "XkbOptions" "terminate:ctrl_alt_bksp"
+ Option     "XkbOptions" "terminate:ctrl_alt_bksp,ctrl:nocaps"                                                                    
EndSection
If you would like to also set other then default keyboard layout, then add this to xorg.conf file:

Code:
Section "InputDevice"
  Identifier "Keyboard0"
  Driver     "kbd"
  Option     "XkbOptions" "terminate:ctrl_alt_bksp"
+ Option     "XkbLayout" "pl"
EndSection
__________________
religions, worst damnation of mankind
"If 386BSD had been available when I started on Linux, Linux would probably never had happened." Linus Torvalds

Linux is not UNIX! Face it! It is not an insult. It is fact: GNU is a recursive acronym for “GNU's Not UNIX”.
vermaden's: links resources deviantart spreadbsd
Reply With Quote
 

Tags
backspace, dbus, hal, hald, x11, xorg, xorg.conf

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
hald(1) and nautilus(1) does not automount media vermaden FreeBSD Ports and Packages 3 2nd November 2009 06:17 PM
HOWTO: Working Intel Graphics Card Setup vermaden FreeBSD Installation and Upgrading 2 3rd July 2009 07:59 PM
dbus-daemon lumiwa FreeBSD General 2 2nd October 2008 12:05 AM
Ctrl-D and Ctrl-C sometimes dose not work mfaridi FreeBSD General 9 6th July 2008 07:04 AM
Backspace Annoyance schrodinger FreeBSD General 2 3rd June 2008 12:11 PM


All times are GMT. The time now is 09:27 AM.


Powered by vBulletin® Version 3.8.4
Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.
Content copyright © 2007-2010, the authors
Daemon image copyright ©1988, Marshall Kirk McKusick