How To Install Phpmotion on Centos 5.3 07/28/2010
1. setup centos 5.3 with server and server gui options, then set the repository configuration 2. install httpd as a service, modify httpd.conf to add index.php in your directory index 3. modify php.ini: - open_basedir = (no value) - upload_max_filesize = 1000M - post_max_size = 1000M - max_execution_time = 1500 - session.gc_maxlifetime = 14000 - safe_mode = off - Thread saftery = disabled - enable_dl = On 4. Install php extension (mysql,gd,and whatever you like), gcc, subversion, ruby, ncurses-devel, libogg, libvorbis, dan libvorbis-devel 5. Install: ffmpeg, ffmpeg-php and Audio Binaries (LAME MP3 Encoder, Libogg + Libvorbis, Mencoder and also Mplayer, FFMpeg-PHP): # reference : http://linuxsysadminblog.com/2008/06/install-ffmpeg-ffmpeg-php-and-audio-binaries-on-centos-rhel-system-with-cpanel/ cd /usr/src su # Download files: wget http://www3.mplayerhq.hu/MPlayer/releases/codecs/essential-20071007.tar.bz2 wget http://www4.mplayerhq.hu/MPlayer/releases/MPlayer-1.0rc2.tar.bz2 wget http://rubyforge.org/frs/download.php/17497/flvtool2-1.0.6.tgz wget http://downloads.sourceforge.net/project/lame/lame/3.98.2/lame-398-2.tar.gz wget http://downloads.sourceforge.net/project/ffmpeg-php/ffmpeg-php/0.6.0/ffmpeg-php-0.6.0.tbz2 wget http://ffmpeg.org/releases/ffmpeg-0.5.tar.bz2 # Extract downloaded files: tar -zxvf flvtool2-1.0.6.tgz tar -zxvf lame-398-2.tar.gz bunzip2 essential-20071007.tar.bz2 tar xvf essential-20071007.tar bunzip2 MPlayer-1.0rc2.tar.bz2 tar xvf MPlayer-1.0rc2.tar bunzip2 ffmpeg-php-0.6.0.tbz2 tar xvf ffmpeg-php-0.6.0.tar bunzip2 ffmpeg-0.5.tar.bz2 tar xvf ffmpeg-0.5.tar # Create and import the Codecs directory: mkdir /usr/local/lib/codecs/ mv essential-20071007/* /usr/local/lib/codecs/ chmod -Rf 755 /usr/local/lib/codecs/ # Install LAME: cd /usr/src/lame-398-2 ./configure && make && make install #Install flvtool2: cd /usr/src/flvtool2-1.0.6/ ruby setup.rb config ruby setup.rb setup ruby setup.rb install # Install MPlayer: cd /usr/src/MPlayer-1.0rc2 ./configure && make && make install # Install ffMPEG: cd /usr/src/ffmpeg-0.5/ mkdir tmp chmod 777 tmp export TMPDIR=./tmp ./configure –enable-libmp3lame –enable-libvorbis –disable-mmx –enable-shared echo ‘#define HAVE_LRINTF 1′ >> config.h make && make install export TMPDIR=/tmp # Finalize the codec setup: ln -s /usr/local/lib/libavformat.so.52 /usr/lib/libavformat.so.52 ln -s /usr/local/lib/libavcodec.so.52 /usr/lib/libavcodec.so.52 ln -s /usr/local/lib/libavutil.so.49 /usr/lib/libavutil.so.49 ln -s /usr/local/lib/libmp3lame.so.0 /usr/lib/libmp3lame.so.0 ln -s /usr/local/lib/libavdevice.so.52 /usr/lib/libavdevice.so.52 # You may get an error about a library path not being found, if so, run: export LD_LIBRARY_PATH=/usr/local/lib # Install FFMPEG-PHP: cd /usr/src/ffmpeg-php-0.6.0/ phpize ./configure && make && make install ln -s /usr/local/bin/ffmpeg /usr/bin/ffmpeg ln -s /usr/local/bin/mplayer /usr/bin/mplayer ln -s /usr/local/bin/mencoder /usr/bin/mencoder # Add extension to php.ini (find the correct php.ini file): [ffmpeg] ;extension_dir=/usr/lib/php/modules extension=ffmpeg.so # Restart Apache and check that the module is loaded in PHP using phpinfo(). If you get the following results then FFMPEG and all it’s components are installed correctly: ffmpeg ffmpeg-php version 0.6.0-svn ffmpeg-php built on Oct 16 2009 14:38:43 ffmpeg-php gd support enabled ffmpeg libavcodec version Lavc52.20.0 ffmpeg libavformat version Lavf52.31.0 ffmpeg swscaler disabled 6. download phpmotion3 to document root, Install phpmotion by opening this page on web browser: http://localhost/setup/index.php ; and follow the instructions |







RSS Feed