Format partitions:
Set the date ( date MMDDhhmm) and get a stage 1 archive and a portage snapshot from a mirror:
Set up the /etc/make.conf file and adapt the USE flags to your requirements. Do not set the hardened, pic and pie USE flags unless you know what you are doing as these will break a number of multimedia applications. Select download mirrors manually ( mirrorselect -i -r -o >> /mnt/gentoo/etc/make.conf, fast) or automatically (mirrorselect -a -s3 -b10 -o >> /mnt/gentoo/etc/make.conf, very slow). Prepare to switch to your new gentoo system extracted from the stage 1 archive using chroot:
Update portage and bootstrap the system (compile packages that are necessary for the system to run, most notably, the C library and the gcc compiler). This takes a few hours.
Set up the time zone; adapt XXX according to your needs ( ls /usr/share/zoneinfo):
Edit /etc/fstab. The usbfs line is required to support USB flash drives.Set up a couple of network-related parameters:
where HOSTNAME and DOMAINNAME are names you can usually choose yourself. Edit the /etc/conf.d/net file as needed.Install important system packages (logging facility, cron):
Install and configure the kernel. First, prepare the system:
Now configure the kernel. Here is a working .config file for kernel >= 2.6.15-suspend2-r8 . (This kernel configuration supports hibernation via suspend2; you need to emerge suspend2-sources instead of gentoo-sources to be able to hibernate.) Run make menuconfig to tune the parameters to your taste. Compile the kernel:
Edit the file /boot/grub/grub.conf first and install the kernel with grub as the bootloader:
If you have compiled the kernel with modules you want to load at boot time (my .config compiles all necessary drivers within the kernel), edit the /etc/modules.autoload.d and run modules_update. You can reboot the system.
X configurationThe X server (emerge xorg-x11) needs some configuration to run properly. Simply use this /etc/X11/xorg.conf file.
The Synaptics touchpad is configured in the same file. More details are available here. Note that for the Compaq Presario 22xx laptop, the device file for the touchpad is /dev/input/event1.
Audio configurationThe audio adapter is supported natively by ALSA. Install the ALSA tools:
and reboot. Make sure the sound is turned on using the mixer ( alsamixer).
Popular media players sould be invoked as follows; for mplayer:
and, for xmms:
Skype 1.3 should also be invoked with aoss. Xine supports alsa natively with no additional tweaking. The simple sound player aplay should be preferred to play.
Wireless adapterThe wireless adapter runs fine using the Windows drivers and ndiswrapper. Get the drivers from the Compaq website. Extract the archive; you need the filesbcmwl5.inf and bcmwl5.sys. Install ndiswrapper:
If you want to enable wireless network at boot time, set the essid_AP line to the desired SSID for your access point in the /etc/conf.d/net file and put this net.wlan0 file in /etc/init.d. Add it to your default runlevel (rc-update add net.wlan0 default).
Refer to the 802.11X howto if you need more security. USB sticksThe USB flash drives work fine with this laptop; just plug the stick into a USB port and mount it (mount -t vfat /dev/sda1/ /mnt/memstick - you need to create the /mnt/memstick directory first). Note that the device file may change if you unplug and replug the stick, from /dev/sda1 to /dev/sda2 for instance. Adapt the file /etc/fstab accordingly. Reference: Flash memory HOWTO.
Keyboard and extra keysThe keyboard comes with 9 extra keys including 3 to manage the sound volume, 1 to turn on/off the wireless adapter, and 5 keys above the keyboard. I will ignore text console problems and focus on X. First, here is how to get accents with the US keyboard. The standard method is to set a "deadkey" that will be used to produce the accents in combination with another key. For instance,deadkey+' followed by e will produce é. To set the deadkey to the "windows key" that is between the Fn and the left alt keys, add the line:
to your ~/.Xmodmap file. Add xmodmap ~/.Xmodmap & to your .xinitrc file. The Euro symbol (€) is obtained with deadkey+= followed by e. To display it, you may need to modify /usr/X11R6/lib/X11/fonts/misc/fonts.alias such the the fixed and variable fonts lines read, at the beginning:
Notice the change of the -1 to -15 at the end of these two lines. Also, run
More information is available here. Here is how to bind the 8 extra keys to useful commands. First, bind the 5 buttons above the function keys tp keycodes and the wireless adapter button. Insert the following commands in /etc/conf.d/local.start or any file that is run at startup:
The keycodes were found with xev and dmesg (press the key and observe the output in xev, dmesg or the system log). Install lineak:
Append this customized keyboard definition file to /etc/lineakkb.def and configure lineak to use the new layout:
and edit the file ~/.lineak/lineakd.conf to make it look like:
Finally, add lineakd & to your .xinitrc and (re)launch your X server.
|
|
|||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
|
Maintained by Yvan Pointurier.
Last modified: December 16 2012 11:16:53. |