rebuild libmlt srpm

Needing some advice with rebuilding a source RPM of “libmlt-0.9.0-9.28.src.rpm”. I think I have all the dependencies installed but the rebuild crashes and do not really know how to untangle the many lines of text within the terminal.

make[2]: Entering directory `/home/allianux/rpmbuild/BUILD/mlt-0.9.0/src/modules/qimage'
cc -O2 -g -m64 -fmessage-length=0 -D_FORTIFY_SOURCE=2 -fstack-protector -funwind-tables -fasynchronous-unwind-tables -DARCH_X86_64 -Wall -DPIC   -O2 -pipe -fno-tree-dominator-opts -fno-tree-pre -ffast-math -DUSE_MMX -DUSE_SSE -DUSE_SSE2 -g -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE -fPIC -pthread -DARCH_X86_64 -Wall -DPIC   -O2 -pipe -fno-tree-dominator-opts -fno-tree-pre -ffast-math -DUSE_MMX -DUSE_SSE -DUSE_SSE2 -g -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE -fPIC -pthread -I../.. -DARCH_X86_64 -Wall -DPIC   -O2 -pipe -fno-tree-dominator-opts -fno-tree-pre -ffast-math -DUSE_MMX -DUSE_SSE -DUSE_SSE2 -g -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE -fPIC -pthread -DGPL3   -c -o factory.o factory.c
cc -O2 -g -m64 -fmessage-length=0 -D_FORTIFY_SOURCE=2 -fstack-protector -funwind-tables -fasynchronous-unwind-tables -DARCH_X86_64 -Wall -DPIC   -O2 -pipe -fno-tree-dominator-opts -fno-tree-pre -ffast-math -DUSE_MMX -DUSE_SSE -DUSE_SSE2 -g -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE -fPIC -pthread -DARCH_X86_64 -Wall -DPIC   -O2 -pipe -fno-tree-dominator-opts -fno-tree-pre -ffast-math -DUSE_MMX -DUSE_SSE -DUSE_SSE2 -g -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE -fPIC -pthread -I../.. -DARCH_X86_64 -Wall -DPIC   -O2 -pipe -fno-tree-dominator-opts -fno-tree-pre -ffast-math -DUSE_MMX -DUSE_SSE -DUSE_SSE2 -g -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE -fPIC -pthread -DGPL3   -c -o producer_qimage.o producer_qimage.c
cc -O2 -g -m64 -fmessage-length=0 -D_FORTIFY_SOURCE=2 -fstack-protector -funwind-tables -fasynchronous-unwind-tables -DARCH_X86_64 -Wall -DPIC   -O2 -pipe -fno-tree-dominator-opts -fno-tree-pre -ffast-math -DUSE_MMX -DUSE_SSE -DUSE_SSE2 -g -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE -fPIC -pthread -DARCH_X86_64 -Wall -DPIC   -O2 -pipe -fno-tree-dominator-opts -fno-tree-pre -ffast-math -DUSE_MMX -DUSE_SSE -DUSE_SSE2 -g -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE -fPIC -pthread -I../.. -DARCH_X86_64 -Wall -DPIC   -O2 -pipe -fno-tree-dominator-opts -fno-tree-pre -ffast-math -DUSE_MMX -DUSE_SSE -DUSE_SSE2 -g -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE -fPIC -pthread -DGPL3   -c -o producer_kdenlivetitle.o producer_kdenlivetitle.c
g++ -O2 -g -m64 -fmessage-length=0 -D_FORTIFY_SOURCE=2 -fstack-protector -funwind-tables -fasynchronous-unwind-tables -O2 -g -m64 -fmessage-length=0 -D_FORTIFY_SOURCE=2 -fstack-protector -funwind-tables -fasynchronous-unwind-tables -DARCH_X86_64 -Wall -DPIC   -O2 -pipe -fno-tree-dominator-opts -fno-tree-pre -ffast-math -DUSE_MMX -DUSE_SSE -DUSE_SSE2 -g -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE -fPIC -pthread -DARCH_X86_64 -Wall -DPIC   -O2 -pipe -fno-tree-dominator-opts -fno-tree-pre -ffast-math -DUSE_MMX -DUSE_SSE -DUSE_SSE2 -g -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE -fPIC -pthread -I../.. -DARCH_X86_64 -Wall -DPIC   -O2 -pipe -fno-tree-dominator-opts -fno-tree-pre -ffast-math -DUSE_MMX -DUSE_SSE -DUSE_SSE2 -g -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE -fPIC -pthread -DGPL3 -DQT_SHARED -I/usr/include/QtXml -I/usr/include/QtSvg -I/usr/include/QtOpenGL -I/usr/include/QtGui -I/usr/include/QtCore  -I/usr/include/ -Wno-deprecated   -c -o qimage_wrapper.o qimage_wrapper.cpp
g++ -O2 -g -m64 -fmessage-length=0 -D_FORTIFY_SOURCE=2 -fstack-protector -funwind-tables -fasynchronous-unwind-tables -O2 -g -m64 -fmessage-length=0 -D_FORTIFY_SOURCE=2 -fstack-protector -funwind-tables -fasynchronous-unwind-tables -DARCH_X86_64 -Wall -DPIC   -O2 -pipe -fno-tree-dominator-opts -fno-tree-pre -ffast-math -DUSE_MMX -DUSE_SSE -DUSE_SSE2 -g -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE -fPIC -pthread -DARCH_X86_64 -Wall -DPIC   -O2 -pipe -fno-tree-dominator-opts -fno-tree-pre -ffast-math -DUSE_MMX -DUSE_SSE -DUSE_SSE2 -g -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE -fPIC -pthread -I../.. -DARCH_X86_64 -Wall -DPIC   -O2 -pipe -fno-tree-dominator-opts -fno-tree-pre -ffast-math -DUSE_MMX -DUSE_SSE -DUSE_SSE2 -g -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE -fPIC -pthread -DGPL3 -DQT_SHARED -I/usr/include/QtXml -I/usr/include/QtSvg -I/usr/include/QtOpenGL -I/usr/include/QtGui -I/usr/include/QtCore  -I/usr/include/ -Wno-deprecated   -c -o kdenlivetitle_wrapper.o kdenlivetitle_wrapper.cpp
qimage_wrapper.cpp:37:28: fatal error: kcomponentdata.h: No such file or directory
 #include <kcomponentdata.h>
                            ^
compilation terminated.
make[2]: *** [qimage_wrapper.o] Error 1
make[2]: *** Waiting for unfinished jobs....
make[2]: Leaving directory `/home/allianux/rpmbuild/BUILD/mlt-0.9.0/src/modules/qimage'
make[1]: *** [all] Error 1
make[1]: Leaving directory `/home/allianux/rpmbuild/BUILD/mlt-0.9.0/src/modules'
make: *** [all] Error 1
error: Bad exit status from /var/tmp/rpm-tmp.mY80FX (%build)

I’d appreciate some guidance on this please. Thank you.

Obviously you do not have all dependencies installed:

qimage_wrapper.cpp:37:28: fatal error: kcomponentdata.h: No such file or directory
 #include <kcomponentdata.h>
                            ^
compilation terminated.

kcomponentdata.h is in the package libkdecore4-devel.

How are you actually building it?
If you would use rpmbuild, you should get a list of the missing dependencies.

Or use “sudo zypper si -d libmlt” to install all needed build dependencies.
“sudo zypper si -d libmlt-0.9.0-9.28.src.rpm” should work as well, I think, to get the dependencies of that particular src package you downloaded.

And why are you building it yourself, btw?
If it’s just because of the missing codec support in the standard openSUSE package, I would suggest to rather install the version from Packman than building it yourself.

Thank you for those pointers, much appreciated… let see if I get it to work.

Thanks, I’ve used your suggestion to install the dependencies (one that I will now remember as its a great bit of advice); however all are installed.

sudo zypper si -d libmlt
Reading installed packages...
Loading repository data...
Resolving package dependencies...

Nothing to do.

I’ll have another read through the rpmbuild terminal output…

The reason for rebuilding MLT is to get it working reliably with Kdenlive. The Packman repository does not provide a stable build. I think the issue is when I use KDE Extra packages. The Frei0r-plugins are also not compiled correctly so… to provide a reliable and stable build I’ve rebuilt frei0r-plugins-1.4-14.1.src.rpm and kdenlive-0.9.8-9.9.src.rpm which has corrected the Frei0r-plugins crashing Kdenlive. So once I have built MLT and Kdenlive again I should have got rid of the remaining instability issues.

rpmbuild should abort if a dependency is missing.

Probably you are building an additional module (qimage) that is not built normally because the necessary libraries are not specified as dependencies.
You might have more packages installed (in comparison to the build on Packman) that the configure script picks up and enables those additional modules therefore.

SO try to install libkdecore4-devel anyway.

The reason for rebuilding MLT is to get it working reliably with Kdenlive. The Packman repository does not provide a stable build.

It seems to work reliable and stable here. But then, I don’t really use it much…

Could you maybe provide steps to reproduce such a crash? (Just OOC)

I think the issue is when I use KDE Extra packages.

Which KDE Extra packages?
kdenlive is available from Packman as well, built against the libmlt from Packman.

The Frei0r-plugins are also not compiled correctly so… to provide a reliable and stable build I’ve rebuilt frei0r-plugins-1.4-14.1.src.rpm and kdenlive-0.9.8-9.9.src.rpm which has corrected the Frei0r-plugins crashing Kdenlive. So once I have built MLT and Kdenlive again I should have got rid of the remaining instability issues.

Hm. AFAICS kdenlive itself does not build against the frei0r-plugins, only libmlt does.

But if there is a problem with Packman’s frei0r plugins you should consider to report it to Packman.