strace doesn't build with older glibc versions (loop.c breaks)

Rolf Eike Beer eb at emlix.com
Mon Dec 16 12:29:45 UTC 2013


Hi,

I try to build strace 4.8 against an old glibc (2.3.4). This breaks multiple 
times in loop.c. The failures I found so far are:

-the glibc <linux/loop.h> forbids the header to be used from glibc using 
programs, because glibc uses a 32 bit dev_t, which would cause wrong struct 
layout in loop_info. I fixed this by this before including <linux/loop.h>:

#undef dev_t
#define dev_t unsigned short

-LO_CRYPT_CRYPTOAPI is not defined in that version of the header (should be 
18)

-struct loop_info64 isn't defined in that version of the header

-LOOP_SET_STATUS64, LOOP_GET_STATUS64, and LOOP_CHANGE_FD are not defined in 
that version of the header

I just copied the neccessary definitions into loop.c to be able to build 
locally, but I guess this should be done by some proper configure checks.

For easier testing I have attached the version of the file that I have with 
that old glibc.

Greetings,

Eike
-- 
Rolf Eike Beer, emlix GmbH, http://www.emlix.com
Fon +49 551 30664-0, Fax +49 551 30664-11
Bertha-von-Suttner-Str. 9, 37085 Göttingen, Germany
Sitz der Gesellschaft: Göttingen, Amtsgericht Göttingen HR B 3160
Geschäftsführung: Dr. Uwe Kracke, Ust-IdNr.: DE 205 198 055

emlix - your embedded linux partner
-------------- next part --------------
A non-text attachment was scrubbed...
Name: loop.h
Type: text/x-chdr
Size: 3796 bytes
Desc: not available
URL: <http://lists.strace.io/pipermail/strace-devel/attachments/20131216/0195ed8c/attachment.bin>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 316 bytes
Desc: This is a digitally signed message part.
URL: <http://lists.strace.io/pipermail/strace-devel/attachments/20131216/0195ed8c/attachment-0001.bin>


More information about the Strace-devel mailing list