Ticket #456: configure.diff

File configure.diff, 1.5 KB (added by foobum@…, 15 years ago)
  • mythtv-0.18.

    diff -u mythtv-0.18.1/configure mythtv-0.18.1-p/configure
    old new  
    11691169
    11701170fi
    11711171
     1172# "CPU_CLIP" test for SRC / libsamplerate
     1173# test positive wrap
     1174cat > $TMPC << EOF
     1175int main(){
     1176    float f = (1<<(sizeof(short)*8))>>1;
     1177    short s = (short)f;
     1178    if ( s == --f )
     1179        return(0);
     1180    return(1);
     1181}
     1182EOF
     1183
     1184if $cc $CFLAGS $ECFLAGS -o $TMPE $TMPC 2>/dev/null ; then
     1185$TMPE && cpuclipspositive="yes"
     1186fi
     1187
     1188# test negative wrap
     1189cat > $TMPC << EOF
     1190int main(){
     1191    float f = -((1<<(sizeof(short)*8))>>1) - 1;
     1192    short s = (short)f;
     1193    if ( s == ++f)
     1194        return(0);
     1195    return(1);
     1196}
     1197EOF
     1198
     1199if $cc $CFLAGS $ECFLAGS -o $TMPE $TMPC 2>/dev/null ; then
     1200$TMPE && cpuclipsnegative="yes"
     1201fi
     1202
    11721203# test for distcc
    11731204if test x"$distcc" = x"yes"; then
    11741205    if test x"`distcc --version 2> /dev/null`" = x""; then
     
    19301961  echo "#define HAVE_MMX 1" >> $TMPH
    19311962  echo "#define __CPU__ 586" >> $TMPH
    19321963fi
     1964if test "$cpuclipspositive" = "yes"; then
     1965  echo "#define CPU_CLIPS_POSITIVE 1" >> $TMPH
     1966else
     1967  echo "#define CPU_CLIPS_POSITIVE 0" >> $TMPH
     1968fi
     1969if test "$cpuclipsnegative" = "yes"; then
     1970  echo "#define CPU_CLIPS_NEGATIVE 1" >> $TMPH
     1971else
     1972  echo "#define CPU_CLIPS_NEGATIVE 0" >> $TMPH
     1973fi
    19331974#if test "$builtin_vector" = "yes" ; then
    19341975#  echo "TARGET_BUILTIN_VECTOR=yes" >> config.mak
    19351976#  echo "#define HAVE_BUILTIN_VECTOR 1" >> $TMPH