LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Slackware (https://www.linuxquestions.org/questions/slackware-14/)
-   -   motion not building on RPi (Slackware ARM 14.2) - THE FIX (https://www.linuxquestions.org/questions/slackware-14/motion-not-building-on-rpi-slackware-arm-14-2-the-fix-4175586224/)

arfon 08-03-2016 08:44 PM

motion not building on RPi (Slackware ARM 14.2) - THE FIX
 
Motion fails to build on Slackware ARM 14.2 (RaspberryPi3 4.4.16-v7+)-

"uname -m" returns "armv7l"


Ran the Slackbuild and it failed with:
Code:

*** Error in `gcc': double free or corruption (top): 0x00310550 ***
Edited the MOTION configure script-
CHANGED:
Code:

*)
                        CPU_OPTIONS="-march=native -mtune=native"
                        ;;
                esac

TO:
Code:

*)
                        CPU_OPTIONS="-march=armv7-a -mtune=arm7"
                        ;;
                esac




Ran Slackbuild script again and it failed with:
Code:

  /tmp/ccQG2Q9Q.s: Assembler messages:
  /tmp/ccQG2Q9Q.s:1452: Error: bad instruction `emms'
  <builtin>: recipe for target 'ffmpeg.o' failed
  make: *** [ffmpeg.o] Error 1

Edited the MOTION ffmpeg.c file-
CHANGED:
Code:

  #ifndef __SSE_MATH__
    __asm__ __volatile__ ( "emms");
  #endif

TO:
Code:

  /* #ifndef __SSE_MATH__
    __asm__ __volatile__ ( "emms");
  #endif */


Motion compiled after that.

Credit where credit is due: This fix was found by LQ user 'elrod'.

stormtracknole 08-04-2016 02:07 PM

Quote:

Originally Posted by arfon (Post 5585614)
Motion fails to build on Slackware ARM 14.2 (RaspberryPi3 4.4.16-v7+)-

"uname -m" returns "armv7l"


Ran the Slackbuild and it failed with:
Code:

*** Error in `gcc': double free or corruption (top): 0x00310550 ***
Edited the MOTION configure script-
CHANGED:
Code:

*)
                        CPU_OPTIONS="-march=native -mtune=native"
                        ;;
                esac

TO:
Code:

*)
                        CPU_OPTIONS="-march=armv7-a -mtune=arm7"
                        ;;
                esac




Ran Slackbuild script again and it failed with:
Code:

  /tmp/ccQG2Q9Q.s: Assembler messages:
  /tmp/ccQG2Q9Q.s:1452: Error: bad instruction `emms'
  <builtin>: recipe for target 'ffmpeg.o' failed
  make: *** [ffmpeg.o] Error 1

Edited the MOTION ffmpeg.c file-
CHANGED:
Code:

  #ifndef __SSE_MATH__
    __asm__ __volatile__ ( "emms");
  #endif

TO:
Code:

  /* #ifndef __SSE_MATH__
    __asm__ __volatile__ ( "emms");
  #endif */


Motion compiled after that.

Credit where credit is due: This fix was found by LQ user 'elrod'.

Awesome! Thanks for sharing. I tried building motion with ffmpeg support, but ended up having to drop support for it. May have to give this a try again.

On a side note, not sure you are are aware that there is a Slackware ARM sub-forum here at LQ. :)


All times are GMT -5. The time now is 07:02 PM.