prussia
Posts: 30
Joined: Sun Jan 13, 2013 12:03 am

mjpg-streamer-experimental make breaking on cmakelist

Sat Aug 31, 2013 5:16 am

Hey guys,
I've tried every which version or way of getting this mjpg-streamer to compile on my wheezy (latest) raspberry pi rev 2. To no avail

The ultimate goal is two fold so if there is an alternate way to do this please let me know :) .
1. To create a webpage with an embeded stream of the camera.. (I will be adding pan tilt controls to that) so I'd like to stream my video.
2. I want to pipe the video to my connected 1.8" HY tft monitor.

Surprisingly I have an older version of mpg-streamer on there. It seems to run other then I never get an image streamed.

Also my camera module takes pictures and video properly ro raspivid etc seems to be working..

My latest attempt was to get this:
mjpg-streamer-experimental
and follow the way to make:

Code: Select all

make USE_LIBV4l2=true clean all
I get this error:

Code: Select all

gcc -c -DLINUX -D_GNU_SOURCE -Wall -shared -fPIC -Wuninitialized -o httpd.lo httpd.c
gcc -DLINUX -D_GNU_SOURCE -Wall -shared -fPIC -Wuninitialized -o output_http.so output_http.c httpd.lo
make[1]: Leaving directory `/home/pi/temp/mjpg-streamer-from-instructables/mjpg-streamer/mjpg-streamer-experimental/plugins/output_http'
cp plugins/output_http/output_http.so .
cd plugins/input_raspicam/build; cmake ..
/bin/sh: 1: cd: can't cd to plugins/input_raspicam/build
CMake Error: The source directory "/home/pi/temp/mjpg-streamer-from-instructables/mjpg-streamer" does not appear to contain CMakeLists.txt.
Specify --help for usage, or press the help button on the CMake GUI.
make: *** [input_raspicam.so] Error 1
That is correct there is no CMakeLists.txt in those folders but I have no clue how to get around that.

Any help in getting a stream up and running from a webpage would be much appreciated :).. Wasted way to much time on this already.

benbois
Posts: 1
Joined: Sun Sep 01, 2013 3:27 pm

Re: mjpg-streamer-experimental make breaking on cmakelist

Sun Sep 01, 2013 3:30 pm

Hi,
I got the same message but the file CMakeLists.txt was in the folder.

To resolve the problem, I've only created the build folder in mjpg-streamer/plugins/input_raspicam/
and re-launch the make clean all command.

That's it.

User avatar
jacksonliam
Posts: 181
Joined: Tue Feb 07, 2012 10:09 pm

Re: mjpg-streamer-experimental make breaking on cmakelist

Sun Sep 01, 2013 6:23 pm

Yeah that was my fault, I'm used to SVN where you don't have to run push after commit!

I've fixed it now, if you've not created the dir you can just run 'git pull' inside the mjpg-streamer-experimental dir to update, then run 'make clean all' again :)

prussia
Posts: 30
Joined: Sun Jan 13, 2013 12:03 am

Re: mjpg-streamer-experimental make breaking on cmakelist

Sun Sep 01, 2013 8:12 pm

Yep I had to move the cmakelist out to the main folder and create a build directory that's it

glad it's fixed for others.

Thanks for the great tool.. i'm still getting slow rates though which kind of sucks.. but i might be unique to my situation on the pi..

ricgal
Posts: 4
Joined: Tue Jul 16, 2013 5:33 pm

Re: mjpg-streamer-experimental make breaking on cmakelist

Tue Oct 01, 2013 2:13 am

To run mjpg-streamer from the desktop, I set up a script. The name of this script on my system is run-raspicam-stream but you can name it what you like on your system.

Here is the working code:

Code: Select all

cd /usr/local/src/mjpg-streamer-master/mjpg-streamer-experimental
export LD_LIBRARY_PATH=.
./mjpg_streamer -i "input_raspicam.so" -o "output_http.so -w ./www/"
The first line, cd /usr/local/src/mjpg-streamer-master/mjpg-streamer-experimental, will need to be adjusted to your particular setup.

When you save the file to your Desktop, you will need to make the file executable. After that, when you open the file, raspian will ask you if you want to execute the file.

The one problem is that the program will not turn off until you shutdown. The solution for that is to run the program in the terminal window. The sure way of doing that is to a) open the terminal window, b) cd to the Desktop and then run the line:

Code: Select all

./run-raspicam-stream
. This will run the program in the terminal window, and closing the terminal window will stop the program.

Return to “Camera board”