Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

Bug#288189: xine-lib: FTBFS (amd64/gcc-4.0): invalid lvalue in increment

4 views
Skip to first unread message

Andreas Jochens

unread,
Jan 2, 2005, 7:00:14 AM1/2/05
to
Package: xine-lib
Severity: normal
Tags: patch

When building 'xine-lib' on amd64 with gcc-4.0,
I get the following error:

gcc -DHAVE_CONFIG_H -I. -I. -I../.. -I../.. -I../../include -I../../include -I../../src -I../../src/xine-engine -I../../src/xine-engine -I../../src/xine-utils -I../../src/input -I../../src/input -I../../lib -O3 -fomit-frame-pointer -fexpensive-optimizations -fschedule-insns2 -fno-strict-aliasing -ffast-math -funroll-loops -finline-functions -Wall -DNDEBUG -D_REENTRANT -D_FILE_OFFSET_BITS=64 -DXINE_COMPILE -Wnested-externs -Wcast-align -Wchar-subscripts -Wmissing-declarations -Wmissing-prototypes -g -MT color.lo -MD -MP -MF .deps/color.Tpo -c color.c -fPIC -DPIC -o .libs/color.o
color.c: In function 'vscale_chroma_line':
color.c:498: error: invalid lvalue in increment
color.c:499: error: invalid lvalue in increment
make[4]: *** [color.lo] Error 1
make[4]: Leaving directory `/xine-lib-1.0/src/xine-utils'

With the attached patch 'xine-lib' can be compiled
on amd64 using gcc-4.0.

Regards
Andreas Jochens

diff -urN ../tmp-orig/xine-lib-1.0/src/libxineadec/nosefart/nes_apu.c ./src/libxineadec/nosefart/nes_apu.c
--- ../tmp-orig/xine-lib-1.0/src/libxineadec/nosefart/nes_apu.c 2004-12-12 07:55:59.000000000 +0100
+++ ./src/libxineadec/nosefart/nes_apu.c 2005-01-02 11:08:42.578949720 +0100
@@ -1012,9 +1012,9 @@

/* signed 16-bit output, unsigned 8-bit */
if (16 == apu->sample_bits)
- *((int16 *) buffer)++ = (int16) accum;
+ buffer = *((int16 *) buffer) + (int16) accum;
else
- *((uint8 *) buffer)++ = (accum >> 8) ^ 0x80;
+ buffer = *((uint8 *) buffer) + (accum >> 8) ^ 0x80;
}

/* resync cycle counter */
diff -urN ../tmp-orig/xine-lib-1.0/src/post/audio/stretch.c ./src/post/audio/stretch.c
--- ../tmp-orig/xine-lib-1.0/src/post/audio/stretch.c 2004-10-30 01:11:38.000000000 +0200
+++ ./src/post/audio/stretch.c 2005-01-02 11:18:07.362089632 +0100
@@ -476,7 +476,7 @@
memcpy( outbuf->mem, data_out,
outbuf->num_frames * this->bytes_per_frame );
num_frames_out -= outbuf->num_frames;
- (uint8_t *)data_out += outbuf->num_frames * this->bytes_per_frame;
+ data_out = (uint8_t *)data_out + outbuf->num_frames * this->bytes_per_frame;

outbuf->vpts = this->pts;
this->pts = 0;
@@ -587,7 +587,7 @@
memcpy( (uint8_t *)this->audiofrag + this->num_frames * this->bytes_per_frame,
data_in, frames_to_copy * this->bytes_per_frame );

- (uint8_t *)data_in += frames_to_copy * this->bytes_per_frame;
+ data_in = (uint8_t *)data_in + frames_to_copy * this->bytes_per_frame;
this->num_frames += frames_to_copy;
buf->num_frames -= frames_to_copy;

diff -urN ../tmp-orig/xine-lib-1.0/src/xine-engine/post.c ./src/xine-engine/post.c
--- ../tmp-orig/xine-lib-1.0/src/xine-engine/post.c 2004-10-17 21:14:30.000000000 +0200
+++ ./src/xine-engine/post.c 2005-01-02 10:31:06.000000000 +0100
@@ -241,7 +241,7 @@
if (!*input) return port;
(*input)->xine_in.name = "video in";
(*input)->xine_in.type = XINE_POST_DATA_VIDEO;
- (xine_video_port_t *)(*input)->xine_in.data = &port->new_port;
+ (*input)->xine_in.data = &port->new_port;
(*input)->post = post;
xine_list_append_content(post->input, *input);
}
@@ -251,7 +251,7 @@
if (!*output) return port;
(*output)->xine_out.name = "video out";
(*output)->xine_out.type = XINE_POST_DATA_VIDEO;
- (xine_video_port_t **)(*output)->xine_out.data = &port->original_port;
+ (*output)->xine_out.data = &port->original_port;
(*output)->xine_out.rewire = post_video_rewire;
(*output)->post = post;
(*output)->user_data = port;
@@ -718,7 +718,7 @@
if (!*input) return port;
(*input)->xine_in.name = "audio in";
(*input)->xine_in.type = XINE_POST_DATA_AUDIO;
- (xine_audio_port_t *)(*input)->xine_in.data = &port->new_port;
+ (*input)->xine_in.data = &port->new_port;
(*input)->post = post;
xine_list_append_content(post->input, *input);
}
@@ -728,7 +728,7 @@
if (!*output) return port;
(*output)->xine_out.name = "audio out";
(*output)->xine_out.type = XINE_POST_DATA_AUDIO;
- (xine_audio_port_t **)(*output)->xine_out.data = &port->original_port;
+ (*output)->xine_out.data = &port->original_port;
(*output)->xine_out.rewire = post_audio_rewire;
(*output)->post = post;
(*output)->user_data = port;
diff -urN ../tmp-orig/xine-lib-1.0/src/xine-utils/color.c ./src/xine-utils/color.c
--- ../tmp-orig/xine-lib-1.0/src/xine-utils/color.c 2003-12-09 01:02:38.000000000 +0100
+++ ./src/xine-utils/color.c 2005-01-02 10:27:12.000000000 +0100
@@ -495,8 +495,10 @@

/* process blocks of 4 pixels */
for (x=0; x < (width / 4); x++) {
- n1 = *(((unsigned int *) src1)++);
- n2 = *(((unsigned int *) src2)++);
+ n1 = *(((unsigned int *) src1));
+ src1 = ((unsigned int *) src1) + 1;
+ n2 = *(((unsigned int *) src2));
+ src2 = ((unsigned int *) src2) + 1;
n3 = (n1 & 0xFF00FF00) >> 8;
n4 = (n2 & 0xFF00FF00) >> 8;
n1 &= 0x00FF00FF;
diff -urN ../tmp-orig/xine-lib-1.0/src/xine-utils/memcpy.c ./src/xine-utils/memcpy.c
--- ../tmp-orig/xine-lib-1.0/src/xine-utils/memcpy.c 2004-12-20 22:22:22.000000000 +0100
+++ ./src/xine-utils/memcpy.c 2005-01-02 10:28:34.000000000 +0100
@@ -218,8 +218,8 @@
"movntps %%xmm2, 32(%1)\n"
"movntps %%xmm3, 48(%1)\n"
:: "r" (from), "r" (to) : "memory");
- ((const unsigned char *)from)+=64;
- ((unsigned char *)to)+=64;
+ from = ((const unsigned char *)from)+64;
+ to = ((unsigned char *)to)+64;
}
else
/*
@@ -241,8 +241,8 @@
"movntps %%xmm2, 32(%1)\n"
"movntps %%xmm3, 48(%1)\n"
:: "r" (from), "r" (to) : "memory");
- ((const unsigned char *)from)+=64;
- ((unsigned char *)to)+=64;
+ from = ((const unsigned char *)from)+64;
+ to = ((unsigned char *)to)+64;
}
/* since movntq is weakly-ordered, a "sfence"
* is needed to become ordered again. */
@@ -296,8 +296,8 @@
"movq %%mm6, 48(%1)\n"
"movq %%mm7, 56(%1)\n"
:: "r" (from), "r" (to) : "memory");
- ((const unsigned char *)from)+=64;
- ((unsigned char *)to)+=64;
+ from = ((const unsigned char *)from)+64;
+ to = ((unsigned char *)to)+64;
}
__asm__ __volatile__ ("emms":::"memory");
}
@@ -363,8 +363,8 @@
"movntq %%mm6, 48(%1)\n"
"movntq %%mm7, 56(%1)\n"
:: "r" (from), "r" (to) : "memory");
- ((const unsigned char *)from)+=64;
- ((unsigned char *)to)+=64;
+ from = ((const unsigned char *)from)+64;
+ to = ((unsigned char *)to)+64;
}
/* since movntq is weakly-ordered, a "sfence"
* is needed to become ordered again. */


--
To UNSUBSCRIBE, email to debian-bugs-...@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listm...@lists.debian.org

0 new messages