Package: quelcom
Version: 0.4.0-8
Severity: serious
Tags: patch

When building 'quelcom' on amd64/unstable,
I get the following error:

g++ -g -DNLS -Wall -fPIC -o qwavsample.o -c qwavsample.cc
qwavsample.cc: In constructor 'qwavsample::qwavsample(qwav*, u_int32_t)':
qwavsample.cc:29: error: cast from 'qwavsample::sample*' to 'int' loses 
precision
qwavsample.cc: In constructor 'qwavsample::qwavsample(char*, u_int32_t, 
u_int32_t)':
qwavsample.cc:66: error: cast from 'qwavsample::sample*' to 'int' loses 
precision
make[2]: *** [qwavsample.o] Error 1

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

Regards
Andreas Jochens

diff -urN 
../tmp-orig/quelcom-0.4.0/debian/patches/05_wavheaderdump-endian.patch 
./debian/patches/05_wavheaderdump-endian.patch
--- ../tmp-orig/quelcom-0.4.0/debian/patches/05_wavheaderdump-endian.patch      
2005-08-13 11:41:57.000000000 +0000
+++ ./debian/patches/05_wavheaderdump-endian.patch      2005-08-13 
11:41:25.000000000 +0000
@@ -24,7 +24,7 @@
          continue;
        }
  
-+        if ((int)f.getMap() % sizeof(u_int32_t) != 0) {
++        if ((long)f.getMap() % sizeof(u_int32_t) != 0) {
 +              // should never happen with a mapping at offset 0, but if it 
does,
 +              // we need to catch it rather than tossing subtle memory misread
 +              // bugs.  32-bit alignment is adequate since no integer in a 
WAV header
diff -urN ../tmp-orig/quelcom-0.4.0/debian/patches/06_wavsample-endian.patch 
./debian/patches/06_wavsample-endian.patch
--- ../tmp-orig/quelcom-0.4.0/debian/patches/06_wavsample-endian.patch  
2005-08-13 11:41:57.000000000 +0000
+++ ./debian/patches/06_wavsample-endian.patch  2005-08-13 11:41:55.000000000 
+0000
@@ -14,7 +14,7 @@
    sample = (union sample*) (wav->getMap()+wav->getOffset(s));
  
    if (wav->getBitsPerSample()==16) {
-+      if ((int)sample % sizeof(int16_t) != 0)
++      if ((long)sample % sizeof(int16_t) != 0)
 +        throw qexception(__PRETTY_FUNCTION__, _("misaligned 16-bit sample"));
 +
      if (wav->getChannels()==2) {
@@ -24,7 +24,7 @@
    sample = (union sample*) pointer;
    
    if (bitspersample==16) {
-+      if ((int)sample % sizeof(int16_t) != 0)
++      if ((long)sample % sizeof(int16_t) != 0)
 +        throw qexception(__PRETTY_FUNCTION__, _("misaligned 16-bit sample"));
      if (channels==2) {
        type = STEREO16;


-- 
To UNSUBSCRIBE, email to [EMAIL PROTECTED]
with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]

Reply via email to