Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 38540 - mtx 1.2.18 and 1.2.17 fails to build with kernel 2.6*
Summary: mtx 1.2.18 and 1.2.17 fails to build with kernel 2.6*
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: New packages (show other bugs)
Hardware: x86 Linux
: High normal (vote)
Assignee: Gentoo's Team for Core System packages
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2004-01-17 13:00 UTC by Jens Weibler
Modified: 2004-07-18 14:36 UTC (History)
1 user (show)

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


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Jens Weibler 2004-01-17 13:00:31 UTC
I want to emerge mtx, but get errors on kernel-includes (scsi.h)..

As a workaround, I renamed /usr/src/linux. Now it still finds scsi.h ("checking for scsi/scsi.h... yes"), but it takes the glibc-include..

I'm no linux-developer, but shouldn't mtx always choose the glibc?

Another guy could build mtx succesfully with the following modification:
typedef unsigned char u8; in mtx.h before the linux-include

What is the right way? Taking glibc- or kernel-includes?

Reproducible: Always
Steps to Reproduce:
1.use kernel 2.6, /usr/src/linux points to kernel2.6-dir
2.emerge mtx





Build-Error-Message (building mtx without any modification):

In file included from mtx.h:65,
                 from mtx.c:39:
/usr/src/linux/include/scsi/scsi.h:203: error: Syntaxfehler before "u8"
/usr/src/linux/include/scsi/scsi.h:203: Warnung: no semicolon at end of struct 
or union
Comment 1 Robin Johnson archtester Gentoo Infrastructure gentoo-dev Security 2004-07-11 14:30:53 UTC
i've stabilized 1.2.18 on x86 in the tree, it contains a fix for this.
Comment 2 DMcLF 2004-07-18 14:34:12 UTC
same problem..
2.6.7 kernel (vanilla)
In file included from mtx.h:65,
                 from mtx.c:39:
/usr/include/scsi/scsi.h:217: error: syntax error before "u8"
/usr/include/scsi/scsi.h:219: error: syntax error before "_r2"
/usr/include/scsi/scsi.h:220: error: syntax error before "block_desc_length"
/usr/include/scsi/scsi.h:221: error: syntax error before "density"
/usr/include/scsi/scsi.h:222: error: syntax error before "number_blocks_hi"
/usr/include/scsi/scsi.h:223: error: syntax error before "number_blocks_med"
/usr/include/scsi/scsi.h:224: error: syntax error before "number_blocks_lo"
/usr/include/scsi/scsi.h:225: error: syntax error before "_r3"
/usr/include/scsi/scsi.h:226: error: syntax error before "block_length_hi"
/usr/include/scsi/scsi.h:227: error: syntax error before "block_length_med"
/usr/include/scsi/scsi.h:228: error: syntax error before "block_length_lo"
/usr/include/scsi/scsi.h:235: error: syntax error before "u8"
In file included from mtx.h:67,
                 from mtx.c:39:
/usr/include/scsi/sg.h:94: error: variable or field `__user' declared void
/usr/include/scsi/sg.h:94: error: syntax error before '*' token
/usr/include/scsi/sg.h:96: error: syntax error before '}' token
/usr/include/scsi/sg.h:107: error: variable or field `__user' declared void
/usr/include/scsi/sg.h:109: error: syntax error before '*' token
/usr/include/scsi/sg.h:110: error: syntax error before '*' token
/usr/include/scsi/sg.h:114: error: syntax error before '*' token
/usr/include/scsi/sg.h:124: error: syntax error before '}' token
/usr/include/scsi/sg.h:174: error: variable or field `__user' declared void
/usr/include/scsi/sg.h:174: error: syntax error before '*' token
/usr/include/scsi/sg.h:178: error: syntax error before '}' token
make: *** [mtx.o] Error 1
make: *** Waiting for unfinished jobs....
In file included from mtx.h:65,
                 from mtxl.c:26:
/usr/include/scsi/scsi.h:217: error: syntax error before "u8"
/usr/include/scsi/scsi.h:219: error: syntax error before "_r2"
/usr/include/scsi/scsi.h:220: error: syntax error before "block_desc_length"
/usr/include/scsi/scsi.h:221: error: syntax error before "density"
/usr/include/scsi/scsi.h:222: error: syntax error before "number_blocks_hi"
/usr/include/scsi/scsi.h:223: error: syntax error before "number_blocks_med"
/usr/include/scsi/scsi.h:224: error: syntax error before "number_blocks_lo"
/usr/include/scsi/scsi.h:225: error: syntax error before "_r3"
/usr/include/scsi/scsi.h:226: error: syntax error before "block_length_hi"
/usr/include/scsi/scsi.h:227: error: syntax error before "block_length_med"
/usr/include/scsi/scsi.h:228: error: syntax error before "block_length_lo"
/usr/include/scsi/scsi.h:235: error: syntax error before "u8"
In file included from mtx.h:67,
                 from mtxl.c:26:
/usr/include/scsi/sg.h:94: error: variable or field `__user' declared void
/usr/include/scsi/sg.h:94: error: syntax error before '*' token
/usr/include/scsi/sg.h:96: error: syntax error before '}' token
/usr/include/scsi/sg.h:107: error: variable or field `__user' declared void
/usr/include/scsi/sg.h:107: error: syntax error before '*' token
/usr/include/scsi/sg.h:109: error: syntax error before '*' token
/usr/include/scsi/sg.h:110: error: syntax error before '*' token
/usr/include/scsi/sg.h:114: error: syntax error before '*' token
/usr/include/scsi/sg.h:124: error: syntax error before '}' token
/usr/include/scsi/sg.h:174: error: variable or field `__user' declared void
/usr/include/scsi/sg.h:174: error: syntax error before '*' token
/usr/include/scsi/sg.h:178: error: syntax error before '}' token
make: *** [mtxl.o] Error 1

!!! ERROR: sys-apps/mtx-1.2.18 failed.
!!! Function src_compile, Line 23, Exitcode 2
!!! Make failed   

/usr/include/scsi points to the include/scsi dir of the 2.6.7 source-dir
Comment 3 DMcLF 2004-07-18 14:36:45 UTC
and as a comment on 
'i've stabilized 1.2.18 on x86 in the tree, it contains a fix for this.'

i'm trying to merge 1.2.18 (synced today)
so.. the 'fix' doesn't work for me it seems.