Take the 2-minute tour ×
Ask Ubuntu is a question and answer site for Ubuntu users and developers. It's 100% free, no registration required.

I am currently working on a web application which requires streaming video, I am using an EC2 Instance on AWS with Ubuntu 12.04 LTS running on it. As I need to transcode video i am wishing to install GPAC 0.5.0 package, however

apt-get install gpac

installs version 0.4.6 where some functionality does not work due to segmentation faults. On my own desktop running Ubuntu 12.10 I can properly install 0.5.0 using same commands and properly transcode my video.

Basically my question is can I expect a GPAC 0.5.0 package to be released for Ubuntu on 12.04 LTS or is there a workaround to get the newer version other then using the source (which is breaking apparently due to Mozzila updating parts of there library which the package relies on). any help or insight would be greatly appreciated.

share|improve this question
add comment

2 Answers

Rather than building from upstream source, try building the package of 12.10 for 12.04.

Warning: this package seems horribly broken... don't expect a nice and clean build. A "nice" package should just build with debuild, this one doesn't.

  1. echo 'DSCVERIFY_KEYRINGS="/etc/apt/trusted.gpg:~/.gnupg/pubring.gpg"' > ~/.devscripts because of Added key, but dget still shows "gpg: Can't check signature: public key not found"

  2. gpg --keyserver keyserver.ubuntu.com --recv-key 311D765A This is the key to verify the source package following below.

  3. dget http://archive.ubuntu.com/ubuntu/pool/universe/g/gpac/gpac_0.5.0~dfsg0-1.dsc to download the source package.

  4. cd gpac-0.5.0~dfsg0/

  5. debuild -uc -us with a failure to expect (example below!):

    dpkg-checkbuilddeps: Unmet build dependencies: freeglut3-dev liba52-0.7.4-dev libavcodec-dev libavformat-dev libfaad-dev libjack-dev libmad0-dev libogg-dev libopenjpeg-dev libpulse-dev libsdl1.2-dev libswscale-dev libtheora-dev libvorbis-dev libwxgtk2.8-dev libxmlrpc-c3-dev libxvidcore-dev
    
  6. Install the build dependencies (satisfy all above from the output you get), e.g.:

    sudo apt-get install freeglut3-dev liba52-0.7.4-dev libavcodec-dev libavformat-dev libfaad-dev libjack-dev libmad0-dev libogg-dev libopenjpeg-dev libpulse-dev libsdl1.2-dev libswscale-dev libtheora-dev libvorbis-dev libwxgtk2.8-dev libxmlrpc-c3-dev libxvidcore-dev
    
  7. Downgrade to Firefox 11.0 as shipped with Ubuntu 12.04. (Ugly, but needed to get it built! Do upgrades after build has finished...)

    sudo apt-get install firefox=11.0+build1-0ubuntu4 firefox-dev=11.0+build1-0ubuntu4 firefox-globalmenu=11.0+build1-0ubuntu4
    
  8. Fix the linker configuration to point to Firefox's libraries (also ugly):

    echo "/usr/lib/firefox" | sudo tee -a /etc/ld.so.conf.d/firefox-gpac.conf
    sudo ldconfig
    
  9. Try again: debuild -uc -us (will take a while to compile)

  10. One directory below, cd .., you'll find your packages.

  11. Install them:

    sudo dpkg -i *gpac*.deb
    

Note: debuild clean does not clean everything after a non-successful build (bug!!). Remove the whole directory and start all over from the dget command.


Advantages over plain building from source:

  • It tells you what build dependencies aren't met by package name.
  • Uninstalling it is really easy.
  • Everything is handled by your package management.

If not reverting to Firefox 11.0, I'm not getting the 0.5.0 compiled at all in 12.04 due to this error:

scenegraph/vrml_smjs.c: In function ‘JS_InitScriptFields’:
scenegraph/vrml_smjs.c:4239:4: warning: passing argument 6 of ‘JS_DefineProperty’ from incompatible pointer type [enabled by default]
/usr/include/firefox/jsapi.h:4458:1: note: expected ‘JSStrictPropertyOp’ but argument is of type ‘JSBool (*)(struct JSContext *, struct JSObject *, jsid,  JSBool,  union jsval *)’
make[2]: *** [scenegraph/vrml_smjs.o] Error 1

After installing Firefox 11 (rather than 18), and getting other errors:

../../bin/gcc/libgpac.so: undefined reference to `JS_NewCompartmentAndGlobalObject'
../../bin/gcc/libgpac.so: undefined reference to `JS_GC'
../../bin/gcc/libgpac.so: undefined reference to `JS_ConvertStub'
../../bin/gcc/libgpac.so: undefined reference to `JS_SetRuntimeThread'
[...] much more...
collect2: ld returned 1 exit status
make[3]: *** [MP4Client] Error 1

You'll need to fix the linker configuration (the ld.conf.so.d/firefox-gpac.conf step).

share|improve this answer
    
Hey thanks, alot the error from what I am understanding is based on firefox libraries that are shared by gpac (or this is what I've read in gpac forum from others attempting to build source). To be honest most of this is above my head at this point but I will take your word for it thank you all the same it's much appreciated!! –  brendosthoughts Jan 16 '13 at 23:42
    
@brendosthoughts Yeah, this is really specific for this package. My common knowledge about building stuff stops here. Try asking how to fix these build errors on the forums of GPAC. –  gertvdijk Jan 16 '13 at 23:46
    
you've read my mind I'm first going to attempt to go through what yopu've outlined and see if I can reproduce the same errors (as they are not the same as other's when building of trunk) and if so I'll post in gpac forum thanks again! –  brendosthoughts Jan 16 '13 at 23:59
    
I am not able to reproduce same things as you if you , when running the command: dpkg-checkbuilddeps: Unmet build dependencies: freeglut3-dev liba52-0.7.4-dev libavcodec-dev libavformat-dev libfaad-dev libjack-dev libmad0-dev libogg-dev libopenjpeg-dev libpulse-dev libsdl1.2-dev libswscale-dev libtheora-dev libvorbis-dev libwxgtk2.8-dev libxmlrpc-c3-dev libxvidcore-dev –  brendosthoughts Jan 17 '13 at 0:14
1  
@brendosthoughts Good to hear. Rather than posting "thank you" comments, consider accepting the answer. (this is how this site works) –  gertvdijk Jan 17 '13 at 1:04
show 11 more comments

According to GPAC site, to install the latest stable release version (0.5.0) in Ubuntu 12.04 you need to do this steps:

  1. Get the code:

    Download it from GPAC on sourceforge and extract the source with tar -xvzf gpac-0.5.0.tar.gz

  2. Get the dependencies: they are a few

    sudo apt-get install make pkg-config g++ zlib1g-dev firefox-dev libfreetype6-dev libjpeg62-dev libpng12-dev libopenjpeg-dev libmad0-dev libfaad-dev libogg-dev libvorbis-dev libtheora-dev liba52-0.7.4-dev libavcodec-dev libavformat-dev libavutil-dev libswscale-dev libxv-dev x11proto-video-dev libgl1-mesa-dev x11proto-gl-dev linux-sound-base libxvidcore-dev libssl-dev libjack-dev libasound2-dev libpulse-dev libsdl1.2-dev dvb-apps

  3. And now compile it:

    cd gpack-0.5.0
    ./configure
    make
    sudo make install

share|improve this answer
    
Hey, thanks but I'm not looking for the latest code as the steps your referring to are for the developer source code which has faults in it and is unstable. I have also attempted to download the stable (0.5.0) code from sourceforge and unpack and install this, but due to the changing mozzila firefox library dependencies I cant seem to properly get this working either –  brendosthoughts Jan 16 '13 at 23:27
    
@brendosthoughts I updated my answer. Try with it and tell me your results. –  Lucio Jan 17 '13 at 0:07
    
Ah, you've found the link to the real 0.5.0 version. Good. Removed my comments. :) –  gertvdijk Jan 17 '13 at 0:38
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.