Login | Register For Free | Help
Search for: (Advanced)

Mailing List Archive: MythTV: Dev

Re: [mythtv-commits] Ticket #7288: mythmainwindow needs include unistd.h after [22350] for win32

 

 

MythTV dev RSS feed   Index | Next | Previous | View Threaded


simon at koala

Nov 4, 2009, 4:57 PM

Post #1 of 7 (379 views)
Permalink
Re: [mythtv-commits] Ticket #7288: mythmainwindow needs include unistd.h after [22350] for win32

MythTV wrote:
> #7288: mythmainwindow needs include unistd.h after [22350] for win32
> -----------------------------+----------------------------------------------
> Reporter: anonymous | Owner: nigel
> Type: defect | Status: closed
> Priority: minor | Milestone: unknown
> Component: Ports - Windows | Version: head
> Severity: medium | Resolution: duplicate
> Mlocked: 0 |
> -----------------------------+----------------------------------------------
> Changes (by mdean):
>
> * status: new => closed
> * resolution: => duplicate
>
>
> Comment:
>
> Dup of #7478.
>
>
well to be picky - it is actually the other way around
7478 is a duplicate of this bug

i think there have been a total of 5 different bug reports for what is
after all a one line change in the code
does it break the build on any platform to add this include file?
--
simon
_______________________________________________
mythtv-dev mailing list
mythtv-dev[at]mythtv.org
http://mythtv.org/cgi-bin/mailman/listinfo/mythtv-dev


mtdean at thirdcontact

Nov 4, 2009, 5:16 PM

Post #2 of 7 (364 views)
Permalink
Re: [mythtv-commits] Ticket #7288: mythmainwindow needs include unistd.h after [22350] for win32 [In reply to]

On 11/04/2009 07:57 PM, Simon Kenyon wrote:
> MythTV wrote:
>> #7288: mythmainwindow needs include unistd.h after [22350] for win32
>> -----------------------------+----------------------------------------------
>>
>> Reporter: anonymous | Owner: nigel Type:
>> defect | Status: closed Priority:
>> minor | Milestone: unknown Component: Ports -
>> Windows | Version: head Severity: medium |
>> Resolution: duplicate
>> Mlocked: 0 |
>> -----------------------------+----------------------------------------------
>>
>> Changes (by mdean):
>>
>> * status: new => closed
>> * resolution: => duplicate
>>
>>
>> Comment:
>>
>> Dup of #7478.
>>
>>
> well to be picky - it is actually the other way around
> 7478 is a duplicate of this bug
>
> i think there have been a total of 5 different bug reports for what is
> after all a one line change in the code
> does it break the build on any platform to add this include file?

Right, but since #7478 had more information (even if the quoted
changeset isn't accurate, I figured it's probably close to the one the
poster meant to quote), I figured it better to close #7288. I figured
that anyone would know that #7288 was opened before #7478, so I didn't
mention it. :)

Mike
_______________________________________________
mythtv-dev mailing list
mythtv-dev[at]mythtv.org
http://mythtv.org/cgi-bin/mailman/listinfo/mythtv-dev


nigel at ind

Nov 4, 2009, 7:50 PM

Post #3 of 7 (360 views)
Permalink
Re: [mythtv-commits] Ticket #7288: mythmainwindow needs include unistd.h after [22350] for win32 [In reply to]

> i think there have been a total of 5 different bug reports for what
> is after all a one line change in the code
> does it break the build on any platform to add this include file?


It doesn't seem to in my testing (so far),
but the hope was to move this sort of stuff
in compat.h, not individual source files.


Adding unistd.h in compat.h breaks pthread.c
compile down in MinGW GCC headers. cf #5980.
I'm still exploring why.

--
Nigel Pearson, nigel[at]ind.tansu.com.au|
Telstra Net. Eng., Sydney, Australia |
Office: 9202 3900 Fax: 9212 6348 |
Mobile: 0408 664435 Home: 9792 6998 |

_______________________________________________
mythtv-dev mailing list
mythtv-dev[at]mythtv.org
http://mythtv.org/cgi-bin/mailman/listinfo/mythtv-dev


jll544 at yahoo

Nov 4, 2009, 9:34 PM

Post #4 of 7 (355 views)
Permalink
Re: [mythtv-commits] Ticket #7288: mythmainwindow needs include unistd.h after [22350] for win32 [In reply to]

>Adding unistd.h in compat.h breaks pthread.c

>compile down in MinGW GCC headers. cf #5980.

One way to resolve this is adding a line before the #endif's in the sched.h patch from #5980:
#define _pid_t pid_t

Normally, types.h (included from unistd.h) defines both pid_t and _pid_t, but in this case, sched.h (included from pthread.h) is processed first and leaves _pid_t undefined.




_______________________________________________
mythtv-dev mailing list
mythtv-dev[at]mythtv.org
http://mythtv.org/cgi-bin/mailman/listinfo/mythtv-dev


nigel at ind

Nov 5, 2009, 3:35 PM

Post #5 of 7 (327 views)
Permalink
Re: [mythtv-commits] Ticket #7288: mythmainwindow needs include unistd.h after [22350] for win32 [In reply to]

> One way to resolve this is adding a line before the #endif's in the
> sched.h patch from #5980:
> #define _pid_t pid_t
>
> Normally, types.h (included from unistd.h) defines both pid_t and
> _pid_t, but in this case, sched.h (included from pthread.h) is
> processed first and leaves _pid_t undefined.

Even better - put compat.h before pthread.h in libavformat/mpegts.c!

Thanks for the hunt, Jeff. I will commit something soon.

--
Nigel Pearson, nigel[at]ind.tansu.com.au| "Peacemaking is our profession"|
Telstra Net. Eng., Sydney, Australia |Motto of Burpelson Airforce Base|
Office: 9202 3900 Fax: 9212 6348 |Commanded by Gen. Jack D. Ripper|
Mobile: 0408 664435 Home: 9792 6998 | Dr Strangelove |

_______________________________________________
mythtv-dev mailing list
mythtv-dev[at]mythtv.org
http://mythtv.org/cgi-bin/mailman/listinfo/mythtv-dev


danielk at cuymedia

Nov 5, 2009, 6:22 PM

Post #6 of 7 (327 views)
Permalink
Re: [mythtv-commits] Ticket #7288: mythmainwindow needs include unistd.h after [22350] for win32 [In reply to]

On Fri, 2009-11-06 at 10:35 +1100, Nigel Pearson wrote:
> > One way to resolve this is adding a line before the #endif's in the
> > sched.h patch from #5980:
> > #define _pid_t pid_t
> >
> > Normally, types.h (included from unistd.h) defines both pid_t and
> > _pid_t, but in this case, sched.h (included from pthread.h) is
> > processed first and leaves _pid_t undefined.
>
> Even better - put compat.h before pthread.h in libavformat/mpegts.c!
>
> Thanks for the hunt, Jeff. I will commit something soon.

compat.h should not go in libavformat/mpegts.c. libavformat should
not depend on any MythTV specific headers. I believe ffmpeg compiles
under MINGW, so we should be able to use whatever is used upstream.

-- Daniel

_______________________________________________
mythtv-dev mailing list
mythtv-dev[at]mythtv.org
http://mythtv.org/cgi-bin/mailman/listinfo/mythtv-dev


nigel at ind

Nov 5, 2009, 6:29 PM

Post #7 of 7 (326 views)
Permalink
Re: [mythtv-commits] Ticket #7288: mythmainwindow needs include unistd.h after [22350] for win32 [In reply to]

> compat.h should not go in libavformat/mpegts.c. libavformat should
> not depend on any MythTV specific headers.

All true.

> I believe ffmpeg compiles under MINGW

That one I'm not so sure about. I'm not on their
mailing list any more, but I do seem to remember
frequent Windows problems, and rejection of the
ghastly build "fixes" that were proposed.

Just haven't had time to work that all out yet.
I thought I was doing well removing the pthread.c one!

--
Nigel Pearson, nigel[at]ind.tansu.com.au| "They did the |
Telstra Net. Eng., Sydney, Australia | white man power dance,|
Office: 9202 3900 Fax: 9212 6348 | and ... Shazam" |
Mobile: 0408 664435 Home: 9792 6998 | Lois Lane - Smallville|

_______________________________________________
mythtv-dev mailing list
mythtv-dev[at]mythtv.org
http://mythtv.org/cgi-bin/mailman/listinfo/mythtv-dev

MythTV dev RSS feed   Index | Next | Previous | View Threaded
 
 


Interested in having your list archived? Contact lists@gossamer-threads.com
 
  Web Applications & Managed Hosting Powered by Gossamer Threads Inc.