[mythtv] GCC problem?
Chris Pinkham
cpinkham at bc2va.org
Fri Feb 29 19:23:03 UTC 2008
* On Fri Feb 29, 2008 at 06:03:44PM +0000, Stuart Morgan wrote:
> On Friday 29 February 2008 17:45:54 Christian Fredriksson wrote:
> > Dunno if this is a gcc problem, I've also the same problem trying compile
> > 0.21-fixes. 0.20-fixes does not have this. Running old G++ g++ (GCC) 3.3.5
> > (Debian 1:3.3.5-12)
>
> 3.3 or even 3.4 are pretty old versions. (4.x has been around since 2005)
>
> I'm not saying that we don't support them, there is no official line on that
> AFAIK. However you might consider upgrading your distro. Anything running 3.3
> probably has unsupported versions of other requirements, e.g. Mysql
> --
> Stuart Morgan
I'm actually still running GCC v3.2.2. I have 2 patches in my tree to get
around issues with this. They're hacks so they won't go into SVN, but
they allow me to limp along until I decide to upgrade my dev system. I'm
wondering if I can hold out until the QT v4 requirement kicks in. :)
Patch to SVN trunk head is attached if anyone needs it.
--
Chris
-------------- next part --------------
Index: libs/libmythtv/videoouttypes.h
===================================================================
--- libs/libmythtv/videoouttypes.h (revision 16285)
+++ libs/libmythtv/videoouttypes.h (working copy)
@@ -300,9 +300,30 @@
return (ret.isEmpty()) ? "" : ret.left(ret.length() - 2);
}
+/*
+ * GCC v3.2.2 and binutils v2.18 give errors like the following during linking
+ * if this function uses the case statement. As a hack, only define this if
+ * IGNORE_TV_PLAY_REC is defined which is only defined in videoout_xv.cpp
+ *
+ * `.L4614' referenced in section `.rodata' of videoout_xv.o: defined in discarded section `.gnu.linkonce.t._Z6toMask16PictureAttribute' of videoout_xv.o
+ * `.L4616' referenced in section `.rodata' of videoout_xv.o: defined in discarded section `.gnu.linkonce.t._Z6toMask16PictureAttribute' of videoout_xv.o
+ */
inline PictureAttributeSupported toMask(PictureAttribute pictureattribute)
{
PictureAttributeSupported ret = kPictureAttributeSupported_None;
+
+ if (pictureattribute == kPictureAttribute_Brightness)
+ return kPictureAttributeSupported_Brightness;
+ else if (pictureattribute == kPictureAttribute_Contrast)
+ return kPictureAttributeSupported_Contrast;
+ else if (pictureattribute == kPictureAttribute_Colour)
+ return kPictureAttributeSupported_Colour;
+ else if (pictureattribute == kPictureAttribute_Hue)
+ return kPictureAttributeSupported_Hue;
+ else if (pictureattribute == kPictureAttribute_Volume)
+ return kPictureAttributeSupported_Volume;
+
+/*
switch (pictureattribute)
{
case kPictureAttribute_None: break;
@@ -318,6 +339,7 @@
ret = kPictureAttributeSupported_Volume; break;
case kPictureAttribute_MAX: break;
}
+*/
return ret;
}
Index: libs/libavcodec/ac3dec.c
===================================================================
--- libs/libavcodec/ac3dec.c (revision 16285)
+++ libs/libavcodec/ac3dec.c (working copy)
@@ -177,6 +177,7 @@
int16_t mask[AC3_MAX_CHANNELS][50]; ///< masking curve values
DECLARE_ALIGNED_16(float, transform_coeffs[AC3_MAX_CHANNELS][256]); ///< transform coefficients
+ DECLARE_ALIGNED_16(float, tccopy[128]);
/* For IMDCT. */
MDCTContext imdct_512; ///< for 512 sample IMDCT
@@ -678,7 +679,9 @@
static void do_imdct_256(AC3DecodeContext *ctx, int chindex)
{
int i, k;
- DECLARE_ALIGNED_16(float, x[128]);
+ //DECLARE_ALIGNED_16(float, x[128]);
+ // FIXME inserted by cpinkham for fixing stack alignment issues w/ gcc 3.2.2
+ float *x = ctx->tccopy;
FFTComplex z[2][64];
float *o_ptr = ctx->tmp_output;
More information about the mythtv-dev
mailing list