Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 12285 - cdrecord (in cdrtools) needs patch to build with 2.5 kernels
Summary: cdrecord (in cdrtools) needs patch to build with 2.5 kernels
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: x86 Linux
: High normal
Assignee: x86-kernel@gentoo.org (DEPRECATED)
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2002-12-17 00:25 UTC by Jim Bray
Modified: 2003-04-27 01:21 UTC (History)
1 user (show)

See Also:
Package list:
Runtime testing required: ---


Attachments
patch to cdrtools-2.0/libscg/scsi-linux-sg.c (libscg-patch,631 bytes, patch)
2002-12-17 00:39 UTC, Jim Bray
Details | Diff
cdrtools-2.0.ebuild (cdrtools-2.0.ebuild,1.43 KB, text/plain)
2003-01-04 16:19 UTC, Doug Goldstein (RETIRED)
Details
scsi-linux-sg.patch (scsi-linux-sg.patch,671 bytes, patch)
2003-01-04 16:20 UTC, Doug Goldstein (RETIRED)
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Jim Bray 2002-12-17 00:25:49 UTC
File cdrtools-2.0/libscg/scsi-linux-sg.c needs the following patch, which
I will attach separately:

#if LINUX_VERSION_CODE >= 0x020500 /* need <asm/types.h> */
/* kernel 2.5.* requires types.h for the 'u8' definition. */
#define __KERNEL__
#include <asm/types.h>
#undef __KERNEL__
#endif
Comment 1 Jim Bray 2002-12-17 00:39:27 UTC
Created attachment 6555 [details, diff]
patch to cdrtools-2.0/libscg/scsi-linux-sg.c

 The libscg code includes a scsi header file from the kernel tree. In my 2.5.50

(SGI CVS) kernel, this uses a typedef, 'u8' which is defined in asm/types.h.
The added patch tests for kernel version >= 2.5.0 (tho' I don't know exactly
where this comes in), and does the necessary #define and #include. Works for
me, and should be sent upstream with my compliments if it works for you.
Comment 2 Doug Goldstein (RETIRED) gentoo-dev 2003-01-04 16:19:06 UTC
Created attachment 6957 [details]
cdrtools-2.0.ebuild

Updated ebuild to use this patch.
Comment 3 Doug Goldstein (RETIRED) gentoo-dev 2003-01-04 16:20:14 UTC
Created attachment 6958 [details, diff]
scsi-linux-sg.patch

Updated the patch so you don't have to crawl in the directory structure of
cdrtools from within the ebuild... Just a little neatier IMHO.
Comment 4 Doug Goldstein (RETIRED) gentoo-dev 2003-01-04 16:20:48 UTC
I used the patch that Jim provided and it finally let cdrtools compile on my
system. I'm running a 2.5.x kernel as well.
Comment 5 Jim Bray 2003-01-06 10:32:11 UTC
 Thanks for picking up the patch. Glad I could contribute something.
If you are in touch with the upstream guy, please forward to him. I gather
from the website that he is prickly about Linux. I remember seeing
a comment about Linux not being consistent from version to version... but
then if you're using kernel headers, you have to expect things to change
from time to time.
Comment 6 Jay Pfeifer (RETIRED) gentoo-dev 2003-04-27 01:21:41 UTC
this patch is in cdrtools-2.01_alpha03 and higher. 
 
Jay