Message ID | 1155892549.2784.9.camel@localhost.localdomain |
---|---|
State | New |
Headers |
Received: from smtp4.pp.htv.fi ([213.243.153.38]) by www.linuxtv.org with esmtp (Exim 4.50) id 1GE0SF-0005xs-Cj for vdr@linuxtv.org; Fri, 18 Aug 2006 11:15:51 +0200 Received: from [192.168.2.5] (cs181056070.pp.htv.fi [82.181.56.70]) by smtp4.pp.htv.fi (Postfix) with ESMTP id 02AC65BC095 for <vdr@linuxtv.org>; Fri, 18 Aug 2006 12:15:49 +0300 (EEST) Subject: Re: [vdr] Build failures on Ubuntu - gettid related From: Ville =?ISO-8859-1?Q?Skytt=E4?= <ville.skytta@iki.fi> To: VDR Mailing List <vdr@linuxtv.org> In-Reply-To: <1155646340.7895.21.camel@localhost.localdomain> References: <20060815021857.GA8201@spork.qfe3.net> <1155637903.7895.16.camel@localhost.localdomain> <20060815123119.GA26885@spork.qfe3.net> <1155646340.7895.21.camel@localhost.localdomain> Content-Type: multipart/mixed; boundary="=-TfkDQSZOGU/muPAYTDaq" Date: Fri, 18 Aug 2006 12:15:49 +0300 Message-Id: <1155892549.2784.9.camel@localhost.localdomain> Mime-Version: 1.0 X-Mailer: Evolution 2.6.3 (2.6.3-1.fc5.5) X-BeenThere: vdr@linuxtv.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: VDR Mailing List <vdr@linuxtv.org> List-Id: VDR Mailing List <vdr.linuxtv.org> List-Unsubscribe: <http://www.linuxtv.org/cgi-bin/mailman/listinfo/vdr>, <mailto:vdr-request@linuxtv.org?subject=unsubscribe> List-Archive: <http://www.linuxtv.org/pipermail/vdr> List-Post: <mailto:vdr@linuxtv.org> List-Help: <mailto:vdr-request@linuxtv.org?subject=help> List-Subscribe: <http://www.linuxtv.org/cgi-bin/mailman/listinfo/vdr>, <mailto:vdr-request@linuxtv.org?subject=subscribe> X-List-Received-Date: Fri, 18 Aug 2006 09:15:51 -0000 Status: O X-Status: X-Keywords: X-UID: 10453 |
Commit Message
Ville Skyttä
Aug. 18, 2006, 9:15 a.m. UTC
On Tue, 2006-08-15 at 14:52 +0200, Jens Auer wrote: > The gettid function is not defined in any header, if it interpret the > source correctly. The _syscall0-macro expands to a function definition > pid_t gettid(void). _syscallX are not available for userspace in recent kernel headers (since April), this causes VDR compilation failures also with the current Fedora Core 6 test versions. More info: http://tinyurl.com/qaydh , http://lkml.org/lkml/2006/6/4/128 The attached patch appears to work for me, and from a bit of Googling I get the impression that it should probably work with all kernel header sets since 2.4.20.
Comments
On Fri, Aug 18, 2006 at 12:15:49PM +0300, Ville Skytt? wrote: > On Tue, 2006-08-15 at 14:52 +0200, Jens Auer wrote: > > _syscallX are not available for userspace in recent kernel headers > (since April), this causes VDR compilation failures also with the > current Fedora Core 6 test versions. More info: > http://tinyurl.com/qaydh , http://lkml.org/lkml/2006/6/4/128 > > The attached patch appears to work for me, and from a bit of Googling I > get the impression that it should probably work with all kernel header > sets since 2.4.20. > --- thread.c~ 2006-06-02 16:51:39.000000000 +0300 > +++ thread.c 2006-08-18 01:26:24.000000000 +0300 > @@ -318,7 +318,5 @@ > > -_syscall0(pid_t, gettid) > - > tThreadId cThread::ThreadId(void) > { > - return gettid(); > + return syscall(__NR_gettid); > } This works for me on Ubuntu, and is pretty much what I'd tried except I used 224 instead of __NR_gettid. Can this be merged into vdr, Klaus?
Chris Elsworth wrote: > On Fri, Aug 18, 2006 at 12:15:49PM +0300, Ville Skytt? wrote: >> On Tue, 2006-08-15 at 14:52 +0200, Jens Auer wrote: >> >> _syscallX are not available for userspace in recent kernel headers >> (since April), this causes VDR compilation failures also with the >> current Fedora Core 6 test versions. More info: >> http://tinyurl.com/qaydh , http://lkml.org/lkml/2006/6/4/128 >> >> The attached patch appears to work for me, and from a bit of Googling I >> get the impression that it should probably work with all kernel header >> sets since 2.4.20. > >> --- thread.c~ 2006-06-02 16:51:39.000000000 +0300 >> +++ thread.c 2006-08-18 01:26:24.000000000 +0300 >> @@ -318,7 +318,5 @@ >> >> -_syscall0(pid_t, gettid) >> - >> tThreadId cThread::ThreadId(void) >> { >> - return gettid(); >> + return syscall(__NR_gettid); >> } > > This works for me on Ubuntu, and is pretty much what I'd tried except > I used 224 instead of __NR_gettid. Can this be merged into vdr, Klaus? It already is in maintenance patch 1.4.1-5. Klaus
--- thread.c~ 2006-06-02 16:51:39.000000000 +0300 +++ thread.c 2006-08-18 01:26:24.000000000 +0300 @@ -318,7 +318,5 @@ -_syscall0(pid_t, gettid) - tThreadId cThread::ThreadId(void) { - return gettid(); + return syscall(__NR_gettid); }