Date: Sat, 1 Nov 1997 10:35:24 +1030 From: Greg Lehey <grog@lemis.com> To: Paul Dekkers <paul@delay.gromit.eu.org> Cc: "Stephen D. Spencer" <lists3@artorius.sunflower.com>, freebsd-questions@FreeBSD.ORG Subject: Re: Install X after installation and: redirecting screens?! Message-ID: <19971101103524.62578@lemis.com> In-Reply-To: <199710311619.RAA05252@chillin.ele.tue.nl>; from Paul Dekkers on Fri, Oct 31, 1997 at 05:19:31PM %2B0100 References: <Pine.BSF.3.96.971031081641.17540A-100000@artorius.sunflower.com> <199710311619.RAA05252@chillin.ele.tue.nl>
next in thread | previous in thread | raw e-mail | index | archive | help
On Fri, Oct 31, 1997 at 05:19:31PM +0100, Paul Dekkers wrote: > Hi Stephen D. Spencer, you wrote: >> >> On Thu, 30 Oct 1997, Paul Dekkers wrote: >> >>> Hi >>> >>> How can I install X after my current FreeBSD installation? >>> (searched for something like 'setup' under Slackware, but couldn't find >>> it) And is it as easy to remove it again?! >> >> cd /usr/ports/x11/XFree86 >> make install > > But I just want to install the binaries from the cd... (2.2.1) > > I saw that directory on my 2nd cd... but I don't want that because it will > fetch the files from the internet... This is from the first edition of "The Complete FreeBSD", and is now slightly out of date, but you should be able to update the pathnames. Let me know if you have any trouble with it. Greg If you don't use sysinstall to install X, you must unpack the archives as root, since a number of the executables are set-user-id. If you unpack the server as an ordinary user, it may abort. You must also use a umask value of 022 (permissions rwxr-xr-x), because the X server requires special permissions. The umask system call sets the permissions with which files will be created. The umask command is built in to your shell--see the shell documentation for further details. umask 022 sets the default permis- sions to rwxr-xr-x. In case you're interested, the value 022 is an octal representation of the permission bits which are not set. This is one of the oldest parts of UNIX. $ su Password: # umask 022 If you don't have enough space in the /usr file system, create a directory on another partition and symlink it to /usr. For example, if you have a file system /home with adequate space, you could do: # cd /home # mkdir X11R6 # ln -s /home/X11R6 /usr/X11R6 Next, decide which archives you want to install. If you had already configured /usr/X11R6/lib/X11/xinit/xinitrc or /usr/X11R6/lib/X11/xdm, omit the archive /cdrom/dists/XF86312/X312xicf.tgz or /cdrom/dists/XF86312/X312xdcf.tgz respec- tively, or unpack it separately and merge in your customizations. For a full install, choose /cdrom/dists/XF86312/X312*.tgz. If you are using sh, enter: # cd /usr # for i in /cdrom/dists/XF86312/X312*.tgz; do # tar xzf $i # done If you are using csh, enter: % cd /usr % foreach i (/cdrom/dists/XF86312/X312*.tgz) % tar xzf $i % end For a minimal installation, first choose a server archive corresponding to your VGA board. If table 8-2 on page 106 doesn't give you enough information, check the server man pages, starting on page 1515, which list the VGA chip sets supported by each server. For example, if you have an ET4000 based board you will use the XF86_SVGA server. In this case you would enter: # cd /usr # tar xzf /cdrom/dists/XF86312/X312SVGA.tgz substitute your server name here # for i in bin fnts lib xicf; do # tar xzf /cdrom/dists/XF86312/X312$i.tgz # done If you are using csh, enter: % cd /usr % tar xzf /cdrom/dists/XF86312/X312SVGA.tgz substitute your server name here % foreach i (bin fnts lib xicf) % tar xzf /cdrom/dists/XF86312/$i % end Next, create a symbolic link /usr/X11/bin/X that points to the server that matches your video board. In this example, it's the XF86_SVGA server: # cd /usr/X11R6/bin change to bin directory # rm X remove the current server # ln -s XF86_SVGA X and create a link to the new server Then check that the directory /usr/X11R6/bin is in the default path for sh in /etc/profile and for csh in /etc/csh.login, and add it if it is not. It's best to do this with an editor, but if you want to take a short cut, you can enter: # echo 'set path = ($path /usr/X11R6/bin)' >>/etc/csh.login # echo 'PATH=$PATH:/usr/X11R6/bin' >>/etc/profile Alternatively, make sure everybody who uses X puts /usr/X11R6/bin in their shell's PATH variable. Next, invoke ldconfig to put the shared libraries in ld.so's cache: # ldconfig /usr/lib /usr/local/lib /usr/X11R6/lib You can omit invoking ldconfig if you plan to reboot before using X. You don't need to uncompress the font files, but if you do, you must run mkfontdir in the corresponding font directory; otherwise your server will abort with the message ``could not open default font `fixed'''. Assigning a virtual terminal to X Next, make sure you have a spare virtual console which is running a getty. First check how many virtual consoles you have: # dmesg | grep virtual sc0: VGA color <16 virtual consoles, flags=0x0> Then check /etc/ttys to make sure there is at least one virtual terminal (ttyvxx device) which doesn't have a getty enabled. Look for the keyword off: # grep ttyv /etc/ttys ttyv0 "/usr/libexec/getty Pc" cons25 on secure ttyv1 "/usr/libexec/getty Pc" cons25 on secure ttyv2 "/usr/libexec/getty Pc" cons25 on secure ttyv3 "/usr/libexec/getty Pc" cons25 off secure In this case, /dev/ttyv3 is available, if your kernel has least 4 VTs. If not, either disable a getty in /etc/ttys by changing on to off, or build another kernel with more virtual terminals--see Chapter 15, Rebuilding the kernel, page 246, for details of how to set the kernel parameter MAXCONS. Configuring X for Your Hardware After installing the X software, you will need to customize the file /usr/X11R6/lib/X11/XF86Config, which tells the X server about your hardware and how you want to run it. The format of XF86Config has changed since version 2 of XFree86. If you are upgrading from version 2, use the reconfig utility to perform a partial translation of the old XConfig file to the new format. You'll still need to make some changes manually. # reconfig < Xconfig > XF86Config The man page XF86Config (on page 1502) and the file /usr/X11R6/lib/X11/XF86Config.eg will help you complete the changes. In order to set up XF86Config, you'll need the following hardware information: o Your mouse type, the bit rate if it's a serial mouse, and the name of the device to which it is connected. This will typically be /dev/ttyd0 or /dev/ttyd1 for a serial mouse, or /dev/mse0 for a bus mouse. o The type of the video board and the amount of display memory. If it's a no- name board, establish what VGA chip set it uses. o The parameters of your monitor: vertical and horizontal frequency. The easy way to create your configuration file is with the utility xf86config (note the lower case name), which leads you through the configuration step by step. You can also use sysinstall, but this doesn't help much, since sysinstall just starts xf86config for you, and it's easier to start it directly. In this section, we'll use an example to illustrate xf86config configuration: we're installing X for a Diamond SpeedStar with 1 MB of display memory, a Logitech MouseMan mouse, and an ADI MicroScan 5AP monitor. The mouse is connected to the system via the first serial port, /dev/ttyd0. To run xf86config, just type in the name: # xf86config
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?19971101103524.62578>