linux build fails on git since may 01
#16
the av_set_string can be easily fixed:
http://fneu.fr/freebsd/xbmc/0001-remove-...ing3.patch

we also need to define MAX_STREAMS in xbmc/cores/dvdplayer/DVDDemuxers/DVDDemuxFFmpeg.h

LIBAVCORE_VERSION_INT is not defined anymore and in lib/DllAvCodec.h we use it:
Code:
#if LIBAVCORE_VERSION_INT < AV_VERSION_INT(52,64,0)
// API added on: 2010-03-31
#define AVMediaType     CodecType
...
so we must adapt the #if

CODEC_ID_XVID and AVCodecContext->hurry_up are removed (used in xbmc/cores/dvdplayer/DVDCodecs/Video/DVDVideoCodecFFmpeg.cpp)
HTPC: Asus AT5IONT-I | 4GB DDR3 RAM | XBMC git on FreeBSD 11-STABLE amd64
Home AV: Mitsubishi HC5000 | Denon 4810 | Monitor Audio GS20 GS10 GSLCR GSFX
Reply
#17
What a pain to get xbmc to compile with the latest ffmpeg libraries.

Fneufneu, were you able to get it work?

I ran into the problems you mentioned and passed them with your fix, but kept getting more and more.
Reply
#18
Following Fneufneu suggestions and a bit of extra tweaks and change to the calls, I was able to build xbmc with the latest ffmpeg libraries

The latest ffmpeg brings some goodness mainly to the flv pseudo streaming feature, you can now skip/seek without having to wait for the buffer to fill up, awesomeness....

I wonder who can officially tell us if the latest ffmpeg will be release in next major xbmc version, ver 11?

If you want to read more about the above finding, check this thread

http://forum.xbmc.org/showthread.php?tid=97560
Reply
#19
Fneufneu Wrote:the av_set_string can be easily fixed:
http://fneu.fr/freebsd/xbmc/0001-remove-...ing3.patch

we also need to define MAX_STREAMS in xbmc/cores/dvdplayer/DVDDemuxers/DVDDemuxFFmpeg.h

LIBAVCORE_VERSION_INT is not defined anymore and in lib/DllAvCodec.h we use it:
Code:
#if LIBAVCORE_VERSION_INT < AV_VERSION_INT(52,64,0)
// API added on: 2010-03-31
#define AVMediaType     CodecType
...
so we must adapt the #if

CODEC_ID_XVID and AVCodecContext->hurry_up are removed (used in xbmc/cores/dvdplayer/DVDCodecs/Video/DVDVideoCodecFFmpeg.cpp)

Thanks, I created a patch complementary to yours and according to your suggestions : http://share.athost.fr/upload/xbmc-with-...mpeg.patch

Compilation of xbmc works now with both patches Big Grin

But I think it should not be used without ffmpeg latests git revisions.
Reply
#20
My solution was "almost" identical to your patch except for

- if (len != iSize && !m_pCodecContext->hurry_up)
+ if (len != iSize && m_pCodecContext->skip_frame != AVDISCARD_NONREF)

I used, the below, as skip_frame is also 0 or 1
if (len != iSize && !m_pCodecContext->skip_frame)
Reply
#21
Are those that created the ffmpeg patches above planning to commit them? If not I could put together a pull request, crediting the original authors of course, and with appropriate version guards if necessary.
Reply
#22
Pull request at 199 (PR), description:

---
This patch fixes XBMC to build and work with latest ffmpeg; the patch also works fine with the internal ffmpeg. Patch coded by Fneufneu and alexb38; see: http://forum.xbmc.org/showthread.php?tid=100601. I just packaged it for submission and verified that it builds and runs with both ffmpegs.
---

I'm not trying to take credit for it; it's just an annoyance to have to manage this patch separately (removing it when submitting other pull requests) and think it will be generally useful.
Reply
#23
Sorry to dig this back up after the pull request has been processed BUT:

I am using the opdenkamp pvr-ppa branch but need the latest ffmpeg for aac-latm to work correctly. I am wondering how I can grab just this commit and apply it to my local xbmc directory as no googling shows me how to do it!

Alternatively, can I get a diff from github or some way else?

Thanks for your help

Chris
Reply
#24
You can apply this patch I made for xbmc-pvr :
https://github.com/skylex/skylex-overlay...9999.patch

Wink
Reply
#25
dbrobins Wrote:Pull request at 199 (PR), description:

---
This patch fixes XBMC to build and work with latest ffmpeg; the patch also works fine with the internal ffmpeg. Patch coded by Fneufneu and alexb38; see: http://forum.xbmc.org/showthread.php?tid=100601. I just packaged it for submission and verified that it builds and runs with both ffmpegs.
---

I'm not trying to take credit for it; it's just an annoyance to have to manage this patch separately (removing it when submitting other pull requests) and think it will be generally useful.

It's cool for me, thanks.

But I'm not sure that xbmc will compile with an old ffmpeg with this commit, did you try it ?

Shouldn't we make some checks for the av_set_string lines instead of deleting them ? Or were they already useless a long time ago ?
Reply
#26
Awesome thanks for the patch.

It failed for me but I have done it all manually and compiling now so I'll let you know how it goes
Reply
#27
Update: This is the error I get on trying to compile:

Code:
In file included from DVDDemuxPVRClient.cpp:23:0:
DVDDemuxPVRClient.h:99:2: error: ‘define’ does not name a type
DVDDemuxPVRClient.cpp: In constructor ‘CDVDDemuxPVRClient::CDVDDemuxPVRClient()’:
DVDDemuxPVRClient.cpp:77:23: error: ‘MAX_STREAMS’ was not declared in this scope
DVDDemuxPVRClient.cpp:77:41: error: ‘m_streams’ was not declared in this scope
DVDDemuxPVRClient.cpp: In member function ‘void CDVDDemuxPVRClient::Dispose()’:
DVDDemuxPVRClient.cpp:95:23: error: ‘MAX_STREAMS’ was not declared in this scope
DVDDemuxPVRClient.cpp:97:9: error: ‘m_streams’ was not declared in this scope
DVDDemuxPVRClient.cpp:103:5: error: ‘m_streams’ was not declared in this scope
DVDDemuxPVRClient.cpp: In member function ‘virtual CDemuxStream* CDVDDemuxPVRClient::GetStream(int)’:
DVDDemuxPVRClient.cpp:154:37: error: ‘MAX_STREAMS’ was not declared in this scope
DVDDemuxPVRClient.cpp:155:12: error: ‘m_streams’ was not declared in this scope
DVDDemuxPVRClient.cpp: In member function ‘void CDVDDemuxPVRClient::RequestStreams()’:
DVDDemuxPVRClient.cpp:173:7: error: ‘m_streams’ was not declared in this scope
DVDDemuxPVRClient.cpp:184:7: error: ‘m_streams’ was not declared in this scope
DVDDemuxPVRClient.cpp:188:7: error: ‘m_streams’ was not declared in this scope
DVDDemuxPVRClient.cpp:195:7: error: ‘m_streams’ was not declared in this scope
DVDDemuxPVRClient.cpp:198:7: error: ‘m_streams’ was not declared in this scope
DVDDemuxPVRClient.cpp:200:5: error: ‘m_streams’ was not declared in this scope
DVDDemuxPVRClient.cpp: In member function ‘void CDVDDemuxPVRClient::UpdateStreams(PVR_STREAM_PROPERTIES*)’:
DVDDemuxPVRClient.cpp:221:9: error: ‘m_streams’ was not declared in this scope
DVDDemuxPVRClient.cpp:228:9: error: ‘m_streams’ was not declared in this scope
DVDDemuxPVRClient.cpp:265:5: error: ‘m_streams’ was not declared in this scope
DVDDemuxPVRClient.cpp: In member function ‘virtual int CDVDDemuxPVRClient::GetNrOfStreams()’:
DVDDemuxPVRClient.cpp:280:14: error: ‘MAX_STREAMS’ was not declared in this scope
DVDDemuxPVRClient.cpp:280:29: error: ‘m_streams’ was not declared in this scope
DVDDemuxPVRClient.cpp: In member function ‘virtual CDemuxStream* CDVDDemuxPVRClient::GetStream(int)’:
DVDDemuxPVRClient.cpp:156:1: warning: control reaches end of non-void function
/home/tv/working/xbmc/xbmc/guilib/GraphicContext.h: At global scope:
/home/tv/working/xbmc/xbmc/guilib/GraphicContext.h:226:150: warning: ‘g_graphicsContext’ defined but not used
make[1]: *** [DVDDemuxPVRClient.o] Error 1
make[1]: *** Waiting for unfinished jobs....
make[1]: Leaving directory `/home/tv/working/xbmc/xbmc/cores/dvdplayer/DVDDemuxers'
make: *** [xbmc/cores/dvdplayer/DVDDemuxers/DVDDemuxers.a] Error 2
Reply
#28
I think you forgot this part of the patch :

Code:
--- a/xbmc/cores/dvdplayer/DVDDemuxers/DVDDemuxPVRClient.h
+++ b/xbmc/cores/dvdplayer/DVDDemuxers/DVDDemuxPVRClient.h
@@ -96,7 +96,7 @@ public:

protected:
   CDVDInputStream* m_pInput;
-
+ #define MAX_STREAMS 100
   CDemuxStream* m_streams[MAX_STREAMS]; // maximum number of streams that ffmpeg can handle

Wink

The patch for xbmc mainline is being merged to the xbmc trunk and a few things will perhaps need to be corrected.

I also sent a pull request for xbmc-pvr specific changes, which might be accepted.
I think everything will be ok for the next merge of xbmc-pvr with upstream xbmc (it might be this week-end or after said dushmaniac).
Reply
#29
alexb38 Wrote:It's cool for me, thanks.

But I'm not sure that xbmc will compile with an old ffmpeg with this commit, did you try it ?

Shouldn't we make some checks for the av_set_string lines instead of deleting them ? Or were they already useless a long time ago ?

I tried internal and recent external ffmpegs, but not an old external one. However, based on a comment by eleplus I modified the original change to bring back the part that was removed that defined CodecType etc., adding a proper #ifdef gate, so it should still be backwards compatible.
Reply
#30
alexb38 Wrote:Shouldn't we make some checks for the av_set_string lines instead of deleting them ? Or were they already useless a long time ago ?

Missed this before. The API has been deprecated for a while, and av_set_string3, the replacement, seems to have been added in 2009.
Reply

Logout Mark Read Team Forum Stats Members Help
linux build fails on git since may 010