1 # Maintainer: Djibb <ashashiwa@gmail.com>
2 # Contributor: Daneel <aur@gnoulibre.org>
4 # Pymecavideo permet de tracer point par point la trajectoire de point ainsi
5 # que choisir un référentiel particulier pour étudier la trajectoire dans
6 # celui-ci. Les données ainsi recueillies peuvent être exportées dans un
7 # logiciel de traitement.
12 pkgdesc="Tool allowing to study trajectory of object from video."
14 url="http://outilsphysiques.tuxfamily.org/pmwiki.php/Oppl/Pymecavideo"
16 makedepends=('subversion' 'docbook-xsl' 'libxslt')
17 depends=('python2-qt' 'ffmpeg' 'vlc' 'opencv' 'python2-matplotlib')
18 optdepends=('gnuplot: draw graph'
20 'mplayer: make coffee')
24 _svntrunk="svn://svn.tuxfamily.org/svnroot/oppl/pymecavideo/branches/5.4"
31 msg "Connecting to SVN server..."
33 if [ -d $pkgname-$pkgver/.svn ]; then
34 (cd $pkgname-$pkgver && svn up -r $pkgver)
36 svn co $_svntrunk --config-dir ./ -r $pkgver $pkgname-$pkgver
39 msg "SVN checkout done or server timeout"
41 cd $srcdir/$pkgname-$pkgver
45 sed -i 's@stylesheet/nwalsh@xsl-stylesheets-*@' data/help/Makefile
46 sed -i 's@"python @"python2 @' src/cadreur.py
47 sed -i 's@/usr/share/python-mecavideo@/usr/lib/python2.7/site-packages/pymecavideo/data@g' src/globdef.py
48 sed -i 's@/usr/share/doc/HTML/fr/pymecavideo@/usr/lib/python2.7/site-packages/pymecavideo/data/help@g' src/globdef.py
50 msg "Starting make..."
52 cd $srcdir/$pkgname-$pkgver/src
57 cd $srcdir/$pkgname-$pkgver
58 python2 setup.py install --root=$pkgdir/ --optimize=1 || return 1
60 cat > $srcdir/$pkgname.sh << EOF
62 if [ ! -d ~/.local/share/data/pymecavideo ]; then
63 mkdir -p ~/.local/share/data/pymecavideo/videos_recodees
65 python2 /usr/lib/python2.7/site-packages/pymecavideo/pymecavideo.py \$*
68 cat > $srcdir/$pkgname.desktop << EOF
73 Exec=/usr/bin/pymecavideo
74 Icon=/usr/share/pixmaps/pymecavideo.xpm
77 GenericName=Meca Video
78 GenericName[fr_FR]=Méca Vidéo
79 Comment=Interactive tool to track moving points in video framesets
80 Comment[fr_FR]=Outil interactif pour le suivi de points dans des vidéos
81 Categories=KDE;GNOME;Application;Video;Education;Science;Physics
84 install -D -m644 $srcdir/$pkgname-$pkgver/COPYING $pkgdir/usr/share/licenses/$pkgname/LICENSE
85 install -D -m644 $srcdir/$pkgname-$pkgver/data/icones/$pkgname.xpm $pkgdir/usr/share/pixmaps/$pkgname.xpm
86 install -dD -m755 $srcdir/$pkgname-$pkgver/data $pkgdir/usr/lib/python2.7/site-packages/$pkgname/data
87 cp -r $srcdir/$pkgname-$pkgver/data/* $pkgdir/usr/lib/python2.7/site-packages/$pkgname/data/
88 install -D -m644 $srcdir/$pkgname.desktop $pkgdir/usr/share/applications/$pkgname.desktop
89 install -D -m644 $srcdir/$pkgname-$pkgver/$pkgname.xml $pkgdir/usr/share/mime/packages/$pkgname.xml
90 install -D -m755 $srcdir/$pkgname.sh $pkgdir/usr/bin/$pkgname
92 msg "TODO: update-desktop-database ; update-mime-database"