Toon posts:

[Apache/PHP] ffmpeg

Pagina: 1
Acties:

Verwijderd

Topicstarter
Ik wil de volgende module binnen PHP beschikbaar hebben:

ffmpeg-php-0.4.6

Nu staat in de INSTALL file van ffmpeg-php dat de volgende dingen noodzakelijk zijn:

code:
1
2
3
ffmpeg-0.4.9pre1 or higher built with the --enable-shared option (ffmpeg cvs recommended)
php-4.3.x or higher 
gd-2.0.x or higher or the version of GD bundled with PHP


Ik draai Red Hat Enterprise server met Plesk 7.5 Reloaded. GD 2 was al geïnstalleerd, en php-4.3 ook. Om ffmpeg te installeren heb ik de instructies uit de install file gevolgd:

code:
1
2
3
4
./configure --enable-shared --prefix=/usr
make clean && make
[become root]
make install


Wat dan ook zonder problemen is gelukt. Nu ben ik aangekomen bij het gedeelte waar ik het ffmpeg-php gedeelte moet integreren in PHP. Hierbij staan in de install file 2 mogelijkheden beschreven:

code:
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
BUILDING FFMPEG-PHP AS A SHARED EXTENSION 
-----------------------------------------
1. Build php if not already built (See the file INSTALL in your php source directory)

2. Unpack the archive and copy the ffmpeg extension directory into your the 
   php sources extensions directory

        tar -xjf ffmpeg-php.X.XX.tar.gz
        cp ffmpeg /path/to/php_sources/ext

3. cd into the ffmpeg extension directory

        cd /path/to/php_sources/ext/ffmpeg

4. Run phpize (included in the php installation) to build configuration files

        phpize

5. Configure and build

        ./configure && make

6. Install the shared extension 

        make install (you may need to become root depending on your installation)


Bij deze eerste methode gaat het al bij stap 3 mis:
code:
1
-bash: phpize: command not found


Daarom probeerde ik de tweede methode:
code:
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
BUILDING FFMPEG-PHP AS PART OF THE PHP BINARY 
---------------------------------------------

1. Unpack the archive and copy the ffmpeg extension directory into your the php 
   sources extensions directory

        tar -xjf ffmpeg-php.X.XX.tar.gz
        cp ffmpeg /path/to/php_sources/ext

2. Run autoconf to rebuild the php configure script and add the --with-ffmpeg 
   option

        cd /path/to/php_sources
        autoconf
        
3. configure php using... 

        ./configure --with-ffmpeg=yes 
       
...and build and install php.

Waarbij het bij stap 2 misgaat:
code:
1
-bash: ./autoconf: No such file or directory


Heeft iemand ervaring met het installeren van deze extensie of weet iemand met welk probleem ik zit?

  • MissingDog
  • Registratie: Augustus 2002
  • Niet online
voer je ./autoconf uit of gewoon autoconf? als 't goed is staat autoconf gewoon in je pad namelijk: /usr/bin/autoconf...dus hoef je geen "./" ervoor te zetten. (hij staat niet in je huidige folder)

[ Voor 16% gewijzigd door MissingDog op 12-11-2005 15:40 ]


  • Cyphax
  • Registratie: November 2000
  • Laatst online: 22:38

Cyphax

Moderator LNX
Kijk even of je die scripts/programma'tjes echt niet hebt, misschien staat phpize niet in je $PATH maar heb je 'm wel in een dir van PHP ergens. Zelfde geldt eigenlijk een beetje voor autoconf, dat staat er vast ergens tussen, en kijk ook even de attributen ervan na (als ie niet executable is is de lol er ook zo af)

Saved by the buoyancy of citrus


Verwijderd

Topicstarter
Dat was mijn tweede poging, ook in /usr/bin krijg ik het volgende:
code:
1
-bash: autoconf: command not found

  • MissingDog
  • Registratie: Augustus 2002
  • Niet online
kijk voor de lol eens of je de autoconf package wel geinstalleerd hebt staan. Het zou een losse package moeten zijn onder de /development tree van je distro.

en anders natuurlijk: yum install autoconf

[ Voor 14% gewijzigd door MissingDog op 12-11-2005 15:44 ]


Verwijderd

Topicstarter
-bash: yum: command not found


Er is nog maar erg weinig op m'n server geinstalleerd, en ik heb zelf ook maar weinig kennis. Toch zou ik graag ffmpeg installeren.

En PHP moet toch al een keer geconfigureerd en geinstalled zijn ? (niet door mij..)

[ Voor 23% gewijzigd door Verwijderd op 12-11-2005 15:51 ]


Verwijderd

Topicstarter
Na enig zoekwerk heb ik phpize kunnen vinden, met Plesk zit dat blijkbaar net wat anders. Hij stond namelijk in de directory /usr/local/psa/admin/bin. Maar nu duikt een ander probleem op. In de installatie instructies staat namelijk:
code:
1
2
3
4
5
6
7
3. cd into the ffmpeg extension directory

        cd /path/to/php_sources/ext/ffmpeg

4. Run phpize (included in the php installation) to build configuration files

        phpize

Maar nu is het resultaat:
code:
1
2
3
4
5
6
7
[root@ns1 bin]# phpize
-bash: phpize: command not found
[root@ns1 bin]# ./phpize
Cannot find config.m4.
Make sure that you run './phpize' in the top level source directory of the module

[root@ns1 bin]#

Verwijderd

Ja moet naar die ffmpeg source dir gaan en daar phpize uitvoeren... omdat phpize niet bij jouw in het PATH staat zal je waarschijnlijk /usr/local/psa/admin/bin/phpize moeten uitvoeren
Pagina: 1