Invalid opus configuration for gstreamer - plugins

I'm struggling to figure out how to install opus plugin for gstreamer. I have installed
opus-tools & libopus0 by apt-get (everything happens on Ubuntu 14.04). I have also gstreamer-plugins-bad installed.
After multiple trials, bugs, etc. gstreamer displays the following error each time I try to call gst-inspect-1.0:
*(gst-plugin-scanner:17408): GStreamer-WARNING **: Failed to load plugin '/opt/gstreamer-1.4.0/lib/gstreamer-1.0/libgstopus.so': /opt/gstreamer-1.4.0/lib/gstreamer-1.0/libgstopus.so: undefined symbol: opus_multistream_encode*
What could have gone wrong during opus installation process that could cause this error?
If it's of any use here's result of ldd /opt/gstreamer-1.4.0/lib/libgstopus.so
*/opt/gstreamer-1.4.0/lib$ ldd /opt/gstreamer-1.4.0/lib/libgstopus.so
linux-vdso.so.1 => (0x00007fff859fe000)
libm.so.6 => /lib/x86_64-linux-gnu/libm.so.6 (0x00007f4f9004f000)
libgstaudio-1.0.so.0 => /opt/gstreamer-1.4.0/lib/libgstaudio-1.0.so.0 (0x00007f4f8fe08000)
libgsttag-1.0.so.0 => /opt/gstreamer-1.4.0/lib/libgsttag-1.0.so.0 (0x00007f4f8fbcf000)
libgstrtp-1.0.so.0 => /opt/gstreamer-1.4.0/lib/libgstrtp-1.0.so.0 (0x00007f4f8f9b5000)
libgstbase-1.0.so.0 => /opt/gstreamer-1.4.0/lib/libgstbase-1.0.so.0 (0x00007f4f8f75c000)
libgstreamer-1.0.so.0 => /opt/gstreamer-1.4.0/lib/libgstreamer-1.0.so.0 (0x00007f4f8f450000)
libgobject-2.0.so.0 => /usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0 (0x00007f4f8f1ff000)
libglib-2.0.so.0 => /lib/x86_64-linux-gnu/libglib-2.0.so.0 (0x00007f4f8eef7000)
libpthread.so.0 => /lib/x86_64-linux-gnu/libpthread.so.0 (0x00007f4f8ecd8000)
libc.so.6 => /lib/x86_64-linux-gnu/libc.so.6 (0x00007f4f8e912000)
libz.so.1 => /lib/x86_64-linux-gnu/libz.so.1 (0x00007f4f8e6f9000)
libgmodule-2.0.so.0 => /usr/lib/x86_64-linux-gnu/libgmodule-2.0.so.0 (0x00007f4f8e4f4000)
libdl.so.2 => /lib/x86_64-linux-gnu/libdl.so.2 (0x00007f4f8e2f0000)
libffi.so.6 => /usr/lib/x86_64-linux-gnu/libffi.so.6 (0x00007f4f8e0e7000)
libpcre.so.3 => /lib/x86_64-linux-gnu/libpcre.so.3 (0x00007f4f8dea9000)
/lib64/ld-linux-x86-64.so.2 (0x00007f4f90587000)*
I must have missed something when installing opus, however i've no more ideas what to do, so I'm counting someone can give me some hint where to look for, or what could have gone wrong?
Thanks for any help :)

your error means that opus library has not been correctly linked into your gstreamer.
Did you install gstreamer-plugins-bad yourself? while doing so, when you run the configuration script from the plugin-bad package, you could add following options:
./configure --host=xxxx --with-plugin=opus --prefix=xxxxx

Related

Zend Skeleton Application A 404 error occurred Page not found

I'm new to ZF. I'm using wamp 3. I followed the instructions from the Zend Framework Documentation (https://framework.zend.com/manual/2.4/en/user-guide/database-and-models.html), installed ZendSkeletonApplication and everything worked fine until step 3 (routing and controllers) when I got the error:
"A 404 error occurred
Page not found.
The requested URL could not be matched by routing.
No Exception available".
I don't know what the problem is, since I copied everything from the tutorial on the site (so that I don't make any typo) and it still won't work.
Any suggestions what the problem might be?
module.config.php looks like this:
return array(
'controllers' => array(
'invokables' => array(
'Album\Controller\Album' => 'Album\Controller\AlbumController',
),
),
'router' => array(
'routes' => array(
'album' => array(
'type' => 'segment',
'options' => array(
'route' => '/album[/:action][/:id]',
'constraints' => array(
'action' => '[a-zA-Z][a-zA-Z0-9_-]*',
'id' => '[0-9]+',
),
'defaults' => array(
'controller' => 'Album\Controller\Album',
'action' => 'index',
),
),
),
),
),
'view_manager' => array(
'template_path_stack' => array(
'album' => __DIR__ . '/../view',
),
),
);
I did everything as they wrote, but when I go to "myvirtualhostname/album" it shows me the error above.
make sure you add this line (highlighted by comment) to the top of your public/index.php
<?php
use Zend\Mvc\Application;
use Zend\Stdlib\ArrayUtils; //<-- add this line
Note#1: you need to follow instructions of editing the index.php file for developing mode enabled, they just forgot to tell about using ArrayUtils in this tutorials.
Note#2 make sure to enable dev mod from the composer and dump autoload like this :
$ composer development-enable
and then:
[$ composer dump-autoload]
I believe you can specify the version you want to install with the initial composer command, something like this:
composer create-project -sdev zendframework/skeleton-application:^2.4 path/to/zf2-app
although you may be able to change the version on your existing skeleton app, it might be easier to run the above command in a different folder, and then copy over the files you've added or changed whilst following the tutorial.
And just to say again, unless you specifically need to learn ZF2.4, it would be better to stick with ZF3 (since that's the current version), and just follow the ZF3 tutorial instead. The differences between them are not that big.

Make sure the prerequisite module are installed on the unix/linux os

I am cpan module which have prerequisite on other module. Is there any process to make sure the module can be installed only after the installation of the prerequisite module while
manual installation of the module.
perl MakeFile.pl
make
make test
make install
Yes. Use a standard build management module like
ExtUtils::MakeMaker or Module::Build, which have conventions to handle prerequisites.
For ExtUtils::MakeMaker, the convention is to pass prerequisite information in the PREREQ_PM argument to the WriteMakefile function. Here's what it might look like:
use ExtUtils::MakeMaker;
WriteMakefile(
NAME => 'My::Module',
AUTHOR => 'Me',
VERSION_FROM => 'lib/My/Module.pm',
PREREQ_PM => {
'Some::Module' => 0.42, # need >=v0.42 of Some::Module
'Some::Other::Module' => 0, # but any version of Some::Other::Module is ok
}
dist => ... ,
clean => ... ,
...
);

What is wrong with my MyConfig.pm?

I'm trying to install perl modules local to my user - I don't have root access. I have setup in my directory structure the following place for perl libs: /dasd/home/miner/perl5lib/lib/lib (don't ask) - I want my perl modules there.
I am going to foolishly post my whole MyConfig.pm - I think just make_arg, make_install_arg, and make_pl_arg are important, but I spose therein lies my question: I'm not sure exactly how cpan works (and can't easily google it) so I don't know exactly the point of params in MyConfig.pm.
'build_dir' => q[/dasd/home/miner/.cpan/build],
'cache_metadata' => q[1],
'cpan_home' => q[/dasd/home/miner/.cpan],
'dontload_hash' => { },
'ftp' => q[/usr/kerberos/bin/ftp],
'ftp_proxy' => q[],
'getcwd' => q[cwd],
'gpg' => q[/usr/bin/gpg],
'gzip' => q[/bin/gzip],
'histfile' => q[/dasd/home/miner/.cpan/histfile],
'histsize' => q[100],
'http_proxy' => q[],
'inactivity_timeout' => q[0],
'index_expire' => q[1],
'inhibit_startup_message' => q[0],
'keep_source_where' => q[/dasd/home/miner/.cpan/sources],
'links' => q[/usr/bin/links],
'make' => q[/usr/bin/make],
'make_arg' => q[LIB= dasd/home/perl5lib/lib/lib PREFIX=~/perl5lib],
'make_install_arg' => q[LIB= dasd/home/perl5lib/lib/lib],
'makepl_arg' => q[PREFIX=~/perl5lib LIB=/dasd/home/perl5lib/lib/lib INSTALLMAN1DIR=~/perl5lib/man1 INSTALLMAN3DIR=~/perl5lib/man3],
'ncftp' => q[],
To further explain, I run 'cpan MongoDB', for example, and I get a lot of output, all screaming a bunch of errors, it all dies on this error:
Checking if your kit is complete...
Looks good
Writing Makefile for File::Slurp
Writing MYMETA.yml and MYMETA.json
make: *** No rule to make target `dasd/home/perl5lib/lib/lib'. Stop.
/usr/bin/make LIB= dasd/home/perl5lib/lib/lib PREFIX=~/perl5lib -- NOT OK
Running make test
Can't test without successful make
Running make install
make had returned bad status, install seems impossible
Running make for K/KR/KRISTINA/MongoDB-0.45.tar.gz
Is already unwrapped into directory /dasd/home/miner/.cpan/build/MongoDB-0.45
CPAN.pm: Going to build K/KR/KRISTINA/MongoDB-0.45.tar.gz
make: *** No rule to make target `dasd/home/perl5lib/lib/lib'. Stop.
/usr/bin/make LIB= dasd/home/perl5lib/lib/lib PREFIX=~/perl5lib -- NOT OK
Running make test
Can't test without successful make
Running make install
make had returned bad status, install seems impossible
What does "No rule to make target `dasd/home/perl5lib/lib/lib' mean? I don't want to make that dir...I want to make the makefile echoed by cpan when they say this "Writing Makefile for File::Slurp". Which i think I want to be in the /dasd/home/perl5lib/lib/lib directory. I'm assuming we are doing File::Slurp because MongoDB depends on it in some way.
I wish I had a better way to phrase the question - but in short here it is: teach me what this all means - how can MyConfig.pm be changed to do what I want?
"No rule to make target `dasd/home/perl5lib/lib/lib'" means that you put a space between LIB= and dasd/home/perl5lib/lib/lib (when it should have been a /), making them separate arguments. make thinks that dasd/home/perl5lib/lib/lib is the name of a file you want it to build, and it doesn't know how.
I'd start by editing MyConfig.pm in a text editor and just search for LIB= dasd and replace it with LIB=/dasd.
You say your libraries are stored in /dasd/home/miner/perl5lib/lib/lib yet your config file has dasd/home/perl5lib/lib/lib.
You seem to need a leading / and a /miner step in the path.

'make installdeps' fails with Net::FTP-related error

I am writing Catalyst application which uses Module::Install for module building. I keep all project-related modules in separate directory with local::lib:
eval $(perl -Mlocal::lib=$HOME/work/projects/freevideo)
Recently I've moved to amd64 environment, and 'make installdeps' stopped working:
nikita#freevideo-dev:~/fv$ make installdeps
/usr/bin/perl "-Iinc" Makefile.PL --config= \
--installdeps=Text::Table,0,Catalyst::Log::Log4perl,1.04,\
Catalyst::Plugin::Session,0,Catalyst::Plugin::Session::State::Cookie,0,\
Catalyst::Plugin::Session::Store::FastMmap,0,Catalyst::Plugin::Authentication,0,\
Catalyst::Plugin::Authorization::Roles,0,Catalyst::Plugin::Unicode,0,\
Catalyst::Plugin::SmartURI,0,Catalyst::Model::DBIC::Schema,0.5,\
Catalyst::View::JSON,0.33,Catalyst::View::TT,0.37,\
Template::Plugin::ListUtil,0.02,Template::Stash::ForceUTF8,0.03,\
Encode,2.43,DateTime,0.70,DateTime::Format::MySQL,0.04,\
Mail::RFC822::Address,0.3,Digest::MD5,2.51,Data::Dumper,2.131,DBIx::Class,0.08194
include /home/nikita/work/projects/freevideo/FreeVideo/inc/Module/Install.pm
include inc/Module/Install/Metadata.pm
include inc/Module/Install/Base.pm
include inc/Module/Install/Makefile.pm
Cannot determine perl version info from lib/FV.pm
Cannot determine license info from lib/FV.pm
include inc/Module/Install/Catalyst.pm
include inc/Module/Install/Include.pm
include inc/File/Copy/Recursive.pm
*** Module::Install::Catalyst
Please run "make catalyst_par" to create the PAR package!
*** Module::Install::Catalyst finished.
include inc/Module/Install/Scripts.pm
include inc/Module/Install/AutoInstall.pm
include inc/Module/AutoInstall.pm
*** Installing dependencies...
Can't use an undefined value as a symbol reference at \
/usr/share/perl/5.10/Net/FTP/dataconn.pm line 54.
Compilation failed in require at \
/usr/share/perl5/Module/Install/AutoInstall.pm line 37.
make: *** [installdeps] Error 111
Here's my Makefile.PL:
# IMPORTANT: if you delete this file your app will not work as
# expected. you have been warned
use inc::Module::Install;
use strict;
use warnings;
name 'FV';
all_from 'lib/FV.pm';
requires 'Moose'; # Moose is required for Catalyst
# Catalyst components
requires 'Catalyst::Runtime' => '5.7015';
requires 'Catalyst::Log::Log4perl' => '1.04';
requires 'Catalyst::Plugin::ConfigLoader';
requires 'Catalyst::Plugin::Static::Simple';
requires 'Catalyst::Plugin::Session';
requires 'Catalyst::Plugin::Session::State::Cookie';
requires 'Catalyst::Plugin::Session::Store::FastMmap';
requires 'Catalyst::Plugin::Authentication';
requires 'Catalyst::Plugin::Authorization::Roles';
requires 'Catalyst::Plugin::Unicode';
requires 'Catalyst::Plugin::SmartURI';
requires 'Catalyst::Action::RenderView';
requires 'Catalyst::Model::DBIC::Schema' => '0.5';
requires 'Catalyst::View::JSON' => '0.33';
requires 'Catalyst::View::TT' => '0.37';
# pragmas
requires 'parent';
requires 'utf8' => '1.07';
requires 'feature' => '1.13';
requires 'Config::General'; # This should reflect the config file format you've chosen
# See Catalyst::Plugin::ConfigLoader for supported formats
# Template Toolkit
requires 'Template' => '2.22';
requires 'Template::Plugin::ListUtil' => '0.02';
requires 'Template::Stash::ForceUTF8' => '0.03';
# other
requires 'POSIX' => '1.17';
requires 'Exporter' => '5.63';
requires 'Encode' => '2.43';
requires 'Data::GUID' => '0.046';
requires 'DateTime' => '0.70';
requires 'DateTime::Format::MySQL' => '0.04';
requires 'Mail::RFC822::Address' => '0.3';
requires 'Digest::MD5' => '2.51';
requires 'Data::Dumper' => '2.131';
requires 'File::Copy' => '2.14';
requires 'DBIx::Class' => '0.08194';
test_requires 'Test::More';
test_requires 'Test::Exception';
test_requires 'Text::Table';
catalyst;
install_script glob('script/*.pl');
auto_install;
WriteAll;
Everything runs on Ubuntu Natty amd64. Is there any workaround for this?
Solved! CPANPLUS had FTP mirrors written in its configuration, and I was too lazy to properly configure my ftp proxy. After replacing all ftp mirrors with http dependencies were successfully installed.
I had a similar error message : Can't use an undefined value as a symbol reference at /System/Library/Perl/5.12/Net/FTP/dataconn.pm line 54.
From reading Nikita answer, I made these changes to fix it:
sudo vim ~/.cpan/CPAN/MyConfig.pm
in the 'urllist' line: replace ftp by http

How do I find the standard site_perl directory for Perl?

How can I find the standard site_perl (non-arch specific) location? Is it safe to just loop over #INC and find the path ending with "site_perl", or is there a standard way to do this?
The reason for trying to find this, is I have a very large project built up from hundreds of individual modules, all with their own Makefile.PL files (pretty much every .pm file has been built as its own CPAN style module). Along with this, each module may have artifacts (templates, .cgi's, etc), in various locations, all which need to be deployed to various locations, nothing is standard. This is the first step in trying to get this under control, basically having a single Makefile which can find and deploy everything, the next step will be getting it in sensible layout in version control.
I've spent time trying to do this with standard installation tools, but have had no luck.
C:\Temp> perl -MConfig -e "print qq{$_ => $Config{$_}\n} for grep { /site/ } keys %Config"
d_sitearch => define
installsitearch => C:\opt\perl\site\lib
installsitebin => C:\opt\perl\site\bin
installsitehtml1dir =>
installsitehtml3dir =>
installsitelib => C:\opt\perl\site\lib
installsiteman1dir =>
installsiteman3dir =>
installsitescript => C:\opt\perl\site\bin
sitearch => C:\opt\perl\site\lib
sitearchexp => C:\opt\perl\site\lib
sitebin => C:\opt\perl\site\bin
sitebinexp => C:\opt\perl\site\bin
sitehtml1dir =>
sitehtml1direxp =>
sitehtml3dir =>
sitehtml3direxp =>
sitelib => C:\opt\perl\site\lib
sitelib_stem =>
sitelibexp => C:\opt\perl\site\lib
siteman1dir =>
siteman1direxp =>
siteman3dir =>
siteman3direxp =>
siteprefix => C:\opt\perl\site
siteprefixexp => C:\opt\perl\site
sitescript =>
sitescriptexp =>
usesitecustomize => define
Or, as #ysth points out in comments, you can use:
C:\Temp> perl -V:.*site.*
on Windows and
$ perl '-V:.*site.*'
in *nix shells.
Is there a reason not to use one of the module installers (ExtUtils::MakeMaker, Module::Build, Module::Install)?
But if you must, the directory is available (after loading Config) as $Config::Config{'installsitelib'}. Note that some platforms may configure perl such that this directory doesn't literally appear in #INC, instead having some other directory that's symlinked to the installsitelib directory.
Just run perl -V. It will print the default #INC at the end.
It is not safe to loop over #INC as it can be modified by code or the environment, and, therefore, may contain multiple directories that end in site_perl.
If you are trying to determine where a given module is installed use %INC.