Forums » StepMania Development » Compiling StepMania on Linux with a System FFMPEG?

I'm attempting to package StepMania for my own private software repository. I have already packaged FFMPEG and its shared libraries and headers and compiled it with MP3 support via libmp3lame aka LAME.

I know that in DefineOptions.cmake, I can ask StepMania to compile -DWITH_SYSTEM_FFMPEG:BOOL=YES, but I still see a dependency on libmad for MP3 support.

Does StepMania still rely on libmad or will it use FFPMEG to decode MP3 files?
Reply
If your system ffmpeg isn't the right version, stepmania will likely crash on videos.
Stepmania will only use libmad for mp3s, unless you know someone who wants to rewrite the sound loading code to use ffmpeg.
< cybik> til Kyzentun fixes bugs for breakfast
--
< maxvg1> shakesoda: then why do i still play lol
<@shakesoda> because you're an ITG player. And thus, a masochist
--
<@shakesoda> Kyzentun: I think you might need to put down the meshes for a bit
Reply
I might be willing to do it eventually, but it might be a good idea to move all media handling to FFMPEG. I can't remember at the moment, I know that they support LAME and MAD, but do they have their own native MP3 decoder in later versions? The FFMPEG version I'm packaging is 2.8.6, which is the latest release. In any case, I'll allow StepMania to compile its own FFMPEG for now.
Reply
Oh, and by the way, the forum notifications don't seem to work over email any more.
Reply
Hi, I've been reading a lot XD!!!, I followed Kyzentun's guide, everything right, just the step of "make -j8" I had to change it to 1. I get my executable.
But stepmania crashes with videos,

How do I know if I have the right version of ffmpeg???
Reply
Crashing on videos is the entire reason ffmpeg is bundled with StepMania and we tell people not to build with system ffmpeg. If you want StepMania to play videos without crashing, you need to build with the bundled ffmpeg.
(or write a new ffmpeg backend for StepMania, that works with multiple versions, but nobody has wanted to do that for years)
< cybik> til Kyzentun fixes bugs for breakfast
--
< maxvg1> shakesoda: then why do i still play lol
<@shakesoda> because you're an ITG player. And thus, a masochist
--
<@shakesoda> Kyzentun: I think you might need to put down the meshes for a bit
Reply
How do I build it with the bundled ffmpeg, I'm kinda new in linux

I did this:


sudo apt-get install libxrandr-dev libgl1-mesa-dev libgl1-mesa-dev libpng12-dev libjpeg62-dev zlib1g-dev libogg-dev libvorbis-dev libmad0-dev libavcodec-dev libavformat-dev libtheora-dev libasound2-dev libgtk2.0-dev libswscale-dev libglu1-mesa libglu1-mesa-dev libbz2-dev libglew1.6-dev libva-dev

sudo apt-get install cmake gcc g++ mesa-common-dev libx11-dev libxtst-dev libjpeg8-dev libc6-dev yasm libasound-dev libpulse-dev libjack-dev lame alsa liblua5.1-0-dev nasm

sudo apt-get install linux-headers-$(uname -r)
sudo apt-get install libpcre3-dev
sudo apt-get install linux-libc-dev
sudo apt-get update

GUIDE --------------------------------------------------------

sudo apt-get install build-essential
sudo apt-get install git
git clone --depth=1 https://github.com/stepmania/stepmania.git
cd stepmania
git submodule init
git submodule update
cd Build/
cmake -G 'Unix Makefiles' -DWITH_FFMPEG_JOBS=4 -DCMAKE_BUILD_TYPE=Release .. && cmake ..
make -j1


Did I miss something? or am I wrong with the dependencies????
Reply
Calexil recently said he had to change WITH_FFMPEG_JOBS to 1 to build successfully, so maybe that's your problem. Redo the cmake step with -DWITH_FFMPEG_JOBS=1 and then run the make step.
If it still crashes after that, post the crashlog in your "Help with videos" thread so that it doesn't clog up this thread.
< cybik> til Kyzentun fixes bugs for breakfast
--
< maxvg1> shakesoda: then why do i still play lol
<@shakesoda> because you're an ITG player. And thus, a masochist
--
<@shakesoda> Kyzentun: I think you might need to put down the meshes for a bit
Reply