cant compile gst-plaugin-bad-0.10 on ubuntu 12.04 - makefile

I have floowing directory structure for gstraemer sources
/home/dev/cerbero/sources/linux_x86_64/gst-plugins-bad-0.10.23
when i run .autogen.sh it runs fine
but when i do "make"
it gives follwing error
gst-plugins_bad_compile_error
more specifically
Making all in gst
make[2]: Entering directory `/home/dev/cerbero/sources/linux_x86_64/gst-plugins- bad-0.10.23/gst'
make -C adpcmdec
make[3]: Entering directory `/home/dev/cerbero/sources/linux_x86_64/gst-plugins-bad-0.10.23/gst/adpcmdec'
CC libgstadpcmdec_la-adpcmdec.lo
adpcmdec.c:586:21: error: expected declaration specifiers or '...' before '(' token
adpcmdec.c:586:40: error: expected declaration specifiers or '...' before '(' token
adpcmdec.c:586:59: error: unknown type name 'adpcmdec'
adpcmdec.c:587:5: error: expected declaration specifiers or '...' before string constant
adpcmdec.c:587:22: error: expected declaration specifiers or '...' before 'plugin_init'
adpcmdec.c:587:35: error: expected declaration specifiers or '...' before string constant
adpcmdec.c:587:44: error: expected declaration specifiers or '...' before string constant
adpcmdec.c:587:52: error: expected declaration specifiers or '...' before string constant
adpcmdec.c:588:5: error: expected declaration specifiers or '...' before string constant
adpcmdec.c:576:1: warning: 'plugin_init' defined but not used [-Wunused-function]
make[3]: *** [libgstadpcmdec_la-adpcmdec.lo] Error 1
make[3]: Leaving directory `/home/dev/cerbero/sources/linux_x86_64/gst-plugins- bad-0.10.23/gst/adpcmdec'
make[2]: *** [adpcmdec] Error 2
make[2]: Leaving directory `/home/dev/cerbero/sources/linux_x86_64/gst-plugins-bad-0.10.23/gst'
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory `/home/dev/cerbero/sources/linux_x86_64/gst-plugins-bad-0.10.23'
make: *** [all] Error 2

A few things before building
Did you install liboil and orc compiler?
Run ./configure --enable-orc if you did
Run ./configure if you did not
Then do a make
Remember to do a make distclean before you do the above steps or simply get clean source. Do not do this on the "dirty half built" folder directly.
It could also be a nasm/yasm issue though I doubt it.
EDIT: My suggestin is to install orc because that speeds up gstreamer by a lot!

Related

Calling Octave interpreter from C - Problems compiling and running example

I'm trying to implement calling octave from C, as per the example shown in this answer Call GNU Octave functions in C?
I'm trying this in Nebeans on Linux.
I've created the files calloctave.cc, calloctave.h, main.c and myfunction.m as per the example. Pointed the links and includes to the correct places (in my case /usr/include/octave-5.2.0/octave/ and /usr/lib64/octave/5.2.0 ). I've chosen C++11 as the standard. In the code, there are no errors highlighted and it seems to find everything it needs, and nothing is highlighted as missing.
When I try to compile it, I just get a series of errors as follows....
cd '/home/arwel/NetBeansProjects/callOctave_new'
/bin/gmake -f Makefile CONF=Debug
"/bin/gmake" -f nbproject/Makefile-Debug.mk QMAKE= SUBPROJECTS= .build-conf
gmake[1]: Entering directory `/home/arwel/NetBeansProjects/callOctave_new'
"/bin/gmake" -f nbproject/Makefile-Debug.mk dist/Debug/GNU-Linux/libcallOctave_new.so
gmake[2]: Entering directory `/home/arwel/NetBeansProjects/callOctave_new'
mkdir -p build/Debug/GNU-Linux
rm -f "build/Debug/GNU-Linux/calloctave.o.d"
g++ -c -g -I/usr/include/octave-5.2.0/octave -include /usr/include/octave-5.2.0/octave/mex.h -std=c++11 -fPIC -MMD -MP -MF "build/Debug/GNU-Linux/calloctave.o.d" -o build/Debug/GNU-Linux/calloctave.o calloctave.cc
In file included from /usr/include/octave-5.2.0/octave/Cell.h:33:0,
from /usr/include/octave-5.2.0/octave/gtk-manager.h:32,
from /usr/include/octave-5.2.0/octave/interpreter.h:36,
from calloctave.cc:7:
/usr/include/octave-5.2.0/octave/ov.h:52:7: error: using typedef-name ‘mxArray’ after ‘class’
class mxArray;
^
In file included from <command-line>:0:0:
/usr/include/octave-5.2.0/octave/mex.h:55:14: note: ‘mxArray’ has a previous declaration here
typedef void mxArray;
^
In file included from /usr/include/octave-5.2.0/octave/ov.h:62:0,
from /usr/include/octave-5.2.0/octave/Cell.h:33,
from /usr/include/octave-5.2.0/octave/gtk-manager.h:32,
from /usr/include/octave-5.2.0/octave/interpreter.h:36,
from calloctave.cc:7:
/usr/include/octave-5.2.0/octave/ov-base.h:57:7: error: using typedef-name ‘mxArray’ after ‘class’
class mxArray;
^
In file included from <command-line>:0:0:
/usr/include/octave-5.2.0/octave/mex.h:55:14: note: ‘mxArray’ has a previous declaration here
typedef void mxArray;
^
calloctave.cc: In function ‘int mexCallOctave(int, mxArray**, int, mxArray**, const char*)’:
calloctave.cc:26:15: error: ‘mxArray’ is not a class, namespace, or enumeration
args(i) = mxArray::as_octave_value (argin[i]);
^
calloctave.cc:42:41: error: invalid use of ‘mxArray {aka void}’
argout[i] = new mxArray (retval(i));
^
calloctave.cc: In function ‘void free_arg_list(int, mxArray**)’:
calloctave.cc:56:29: warning: deleting ‘mxArray* {aka void*}’ is undefined [enabled by default]
delete arglist[i];
^
gmake[2]: *** [build/Debug/GNU-Linux/calloctave.o] Error 1
gmake[2]: Leaving directory `/home/arwel/NetBeansProjects/callOctave_new'
gmake[1]: *** [.build-conf] Error 2
gmake[1]: Leaving directory `/home/arwel/NetBeansProjects/callOctave_new'
gmake: *** [.build-impl] Error 2
BUILD FAILED (exit value 2, total time: 1s)
It seems to be not understanding the mex interface in some way. I'm not very knowledgeable about C/C++, so am at a loss as to how to proceed here. What could be causing these errors and how might I resolve them?

Make threw out an error but no detailed error message

Here's the last few lines from the output of running "make install" at root level /home/gm/TEST/:
make[3]: Leaving directory `/home/gm/TEST/tppf/tm/ipmgt'
ld ipfac.o ipfacV.o ipfac_rset.o ipfac_args.o ipfac_d2a.o ipfac_a2d.o ipfac_modr.o ipfac_mod.o ipfac_read.o ipfac_add.o ipfac_del.o ipfac_list.o ipfac_unlk.o ipfac_lock.o ipfac_util.o ipfac_lkid.o -r -o /home/gm/TEST/tppf/lib/ipfac_tppf.o
make[3]: Leaving directory `/home/gm/TEST/tppf/tm/ipfac'
make[2]: Leaving directory `/home/gm/TEST/tppf/tm'
make[1]: *** [i_tm] Error 2
make[1]: Leaving directory `/home/gm/TEST/tppf'
make: *** [i_tppf] Error 2
And the Makefile under /home/gm/TEST/tppf/tm/ipfac contains this rule:
install: ipfac.h $(TPPLIB)/ipfac_tppf.o
$(TPPLIB)/ipfac_tppf.o: $(PROPOBJS)
ld $(PROPOBJS) -r -o $(TPPLIB)/ipfac_tppf.o
Is there something wrong with the linking process? Make should've told me what the error actually is, but it didn't.
BTW, I think /home/gm/TEST/tppf/lib/ipfac_tppf. O was linked and created successfully, or at least it was there in directory /home/gm/TEST/tppf/lib/ after make failed and exited.
That line is not the error line. You can tell that it succeeded because there was no error message there, for building the target /home/gm/TEST/tppf/lib/ipfac_tppf.o.
The error is here:
make[1]: *** [i_tm] Error 2
The [1] means that it was the first level of makefile (note the recipe you are quoting here was in the 3rd level of makefile) and the [i_tm] means that the build of the target i_tm failed. You need to look back up further in the output of make, earlier than what you've shown us, and find the *** error line for building the i_tm target and see what errors were generated there.

Gnu plot error with lua/torch (OS X)

I want to run some code in torch that requires the gnuplot lib however I get the following error;
/Users/mattsmith/torch/install/bin/luajit: ...attsmith/torch/install/share/lua/5.1/gnuplot/gnuplot.lua:127: Gnuplot terminal is not set
stack traceback:
[C]: in function 'error'
...attsmith/torch/install/share/lua/5.1/gnuplot/gnuplot.lua:127: in function 'getfigure'
...attsmith/torch/install/share/lua/5.1/gnuplot/gnuplot.lua:808: in function 'figure'
...attsmith/torch/install/share/lua/5.1/gnuplot/gnuplot.lua:288: in function 'getCurrentPlot'
...attsmith/torch/install/share/lua/5.1/gnuplot/gnuplot.lua:308: in function 'writeToCurrent'
...attsmith/torch/install/share/lua/5.1/gnuplot/gnuplot.lua:836: in function 'gnulplot'
...attsmith/torch/install/share/lua/5.1/gnuplot/gnuplot.lua:976: in function 'plot'
practical3.lua:217: in main chunk
[C]: in function 'dofile'
...mith/torch/install/lib/luarocks/rocks/trepl/scm-1/bin/th:131: in main chunk
[C]: at 0x0104467190
I read here Lua Error: "Gnuplot terminal is not set" that I require the gnu plot executable installed. So I downloaded this and followed the website instructions here http://gnuplot.sourceforge.net/ReleaseNotes_5_0.html and then I get this error;
In file included from ./term.h:414:
../term/lua.trm:113:10: fatal error: 'lua.h' file not found
#include <lua.h>
^
1 error generated.
make[3]: *** [term.o] Error 1
make[2]: *** [install-recursive] Error 1
make[1]: *** [install] Error 2
make: *** [install-recursive] Error 1
Not too sure if I am going about this the correct way. Any help would be greatly appreciated!
Thanks
Find wherever lua.h is located. For me it was in: /usr/local/Cellar/lua/5.3.5_1/include/lua
Then, open lua.trm inside the gnuplot installation files, find #include lua.h and replace it with path/lua.h. In my case: /usr/local/Cellar/lua/5.3.5_1/include/lua/lua.h
You will notice that there are other "includes" that will throw the same error as the one with lua.h. There are all on the same path. Therefore, modify the includes the in the same manner.

SkaMPI compilation error, Makefile.dep:5: *** missing separator.

I was trying to compile SkaMPI 5 using latest GNU make(3.81), but getting below error :
make -f Makefile.dep MPICC="mpicc" CFLAGS="-O2" skampi
make[1]: Entering directory
Makefile.dep:5: *** missing separator. Stop.
make[1]: Leaving directory
make: *** [skampi] Error 2

coreutils make failed

I need to do some business on coreutils as a part of a project for school, but I am stuck right at the beginning of README-hacking, I have done all things and they were successful until make. It failed and gave me this kind of response:
$ make
make all-recursive
make[1]: Entering directory `/home/andrej/Projects/coreutils'
Making all in lib
make[2]: Entering directory `/home/andrej/Projects/coreutils/lib'
make all-recursive
make[3]: Entering directory `/home/andrej/Projects/coreutils/lib'
make[4]: Entering directory `/home/andrej/Projects/coreutils/lib'
CC printf-frexp.o
In file included from printf-frexp.c:27:0:
./math.h:558:5: error: token "#" is not valid in preprocessor expressions
./math.h:634:5: error: token "#" is not valid in preprocessor expressions
./math.h:657:5: error: token "#" is not valid in preprocessor expressions
./math.h:743:5: error: token "#" is not valid in preprocessor expressions
./math.h:814:5: error: token "#" is not valid in preprocessor expressions
make[4]: *** [printf-frexp.o] Error 1
make[4]: Leaving directory `/home/andrej/Projects/coreutils/lib'
make[3]: *** [all-recursive] Error 1
make[3]: Leaving directory `/home/andrej/Projects/coreutils/lib'
make[2]: *** [all] Error 2
make[2]: Leaving directory `/home/andrej/Projects/coreutils/lib'
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory `/home/andrej/Projects/coreutils'
make: *** [all] Error 2
and now I am stuck here, because I dont want to touch the code in this state, dont you know whats is wrong, I mean I know that there is something wrong with my machine, but where and how to solve this one?
Thanks a lot for your responses
Andrej

Resources