Typo
[linux_from_scratch_hints.git] / OLD / cdwriter.txt
blob4ce5566412bf84a0d26e1e2c73082f830ad805f1
1 TITLE:          CD-writer configuration
2 LFS VERSION:    Any
3 AUTHOR:         Adam Ottley <aottley@home.com>
5 SYNOPSIS:
6         This hints covers the task of configuring the Linux kernel for a CD-writer 
7 plus the installation of the cdrtools and cdrdao software packages.
9 HINT:
11 Software you'll need:
13   cdrtools-1.10.tar.gz  (ftp://ftp.fokus.gmd.de/pub/unix/cdrecord/)
14   cdrdao-1.1.5.tar.gz  (http://sourceforge.net/projects/cdrdao/)
15   pccts133mr.tar.gz  (http://www.polhode.com/pccts.html)
18 -------------------------------------
20 CONFIGURING THE KERNEL
22 CD-writing software communicates on a SCSI interface, even if it's to an IDE 
23 CD-writer.  Here's what options you'll need enabled/disabled in your kernel:
25 SCSI CD-writer:
27 <SCSI support menu>
28   SCSI support:  Y or M
29   SCSI CD-ROM support:  Y or M
30   SCSI generic support:  Y or M
31   Vendor-specific extensions:  Y
32 Also include the low-level driver for your SCSI card if applicable.
35 IDE CD-writer:
37 <ATA/IDE/MFM/RLL support menu>
38   IDE/ATAPI CDROM support:  N
39   SCSI emulation support:  Y or M
40 <SCSI support menu>
41   SCSI support:  Y or M
42   SCSI CD-ROM support:  Y or M
43   SCSI generic support:  Y or M
44   Vendor-specific extensions:  Y
46 Having the loopback device can also be useful for mounting ISO files from the 
47 hard drive.  To do that, use this command:
49   mount -t iso9660 -o loop <iso file> <mount point>
51 Build the new kernel and install it.  You may have to alter a few 
52 symlinks or your fstab to reflect the new location of your CD/DVD drives - 
53 they'll be located at /dev/scd# now.  Once you're convinced that your new 
54 kernel works, move on to the next section.
57 -------------------------------------
60 cdrtools 1.10
62 cdrtools includes many programs including cdrecord, mkisofs and cdda2wav.  It 
63 is the premier suite of burning tools for Unix, especially for data CDs.
65 First you'll need to edit the DEFAULTS/Defaults.linux file to change the 
66 installation path and the user/group to which the binaries will be assigned.  
67 Change each occurrance of /opt/schily to your preferred path, i.e. /usr/local. 
68 By default, the binaries are assigned to the user and group "bin".  For 
69 convention's sake, we'll just change both to root by editing the DEFINSUSR and 
70 DEFINSGRP entries.  Once that's finished, go back to the top-level cdrtools 
71 directory and run:
73   make COPTS=$CFLAGS &&
74   make install
76 to build and install cdrtools.  The COPTS=$CFLAGS is optional, only used if 
77 you want optimization (which probably only makes a difference with mkisofs).
79 With cdrtools now installed, you can check the SCSI interface for your 
80 CD-writer.  To do that, issue this command as root:
82   cdrecord -scanbus
84 Here's a sample output from this command:
86 Linux sg driver version: 3.1.17
87 Using libscg version 'schily-0.5'
88 scsibus0:
89         0,0,0     0) 'CREATIVE' 'DVD5240E-1      ' '1.30' Removable CD-ROM
90         0,1,0     1) 'HP      ' 'CD-Writer+ 9100b' '1.07' Removable CD-ROM
91         0,2,0     2) *
92         0,3,0     3) *
93         0,4,0     4) *
94         0,5,0     5) *
95         0,6,0     6) *
96         0,7,0     7) *
98 You'll need the three-number ID of each of your drives if you want to read 
99 and burn from the command line using cdrtools and cdrdao.
102 -------------------------------------
105 pccts 1.33
107 pccts is a parser generator that is required by cdrdao.  Both the binaries and 
108 the headers must be installed manually.
110 To build and install pccts, run these commands:
112   make &&
113   cp bin/antlr bin/dlg bin/genmk bin/sor /usr/local/bin &&
114   cp -a h/ /usr/local/include/pccts
117 -------------------------------------
120 cdrdao 1.1.5
122 cdrdao is a tool that specializes in disc-at-once audio CD burning.  It also 
123 supports bin/cue burning, custom tables of contents, and CDDB lookup for 
124 automatic CD-TEXT insertion.
126 Build and install cdrdao with the following commands:
128   ./configure --prefix=/usr/local &&
129   make &&
130   make install
133 -------------------------------------
136 PERMISSIONS
138 Anyone who needs to rip or burn CDs needs to be configured for the proper 
139 permissions.  Specifically, read and write permissions are needed on the SCSI 
140 generic device (/dev/sg*) for each drive, and read permission is needed for 
141 the /dev/scd device for each drive.
143 The optimal way to do this is create a group called cdwriter, add the 
144 necessary people to that group, assign the devices to group cdwriter, and 
145 change the permissions to 660 on the /dev/sg devices and 640 on the /dev/scd 
146 devices.  Note that you need to do this for CD readers as well in order to rip 
147 CDs.
150 -------------------------------------
153 Now that the kernel is configured, the software is installed and the 
154 permissions are set, you're done!  Try burning an ISO or two or grab a GUI 
155 frontend for the burning programs.  Happy burning!