Changes between Version 50 and Version 51 of CompilationGuide/Centos
- Timestamp:
- Nov 15, 2016, 8:38:34 PM (10 years ago)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
CompilationGuide/Centos
v50 v51 11 11 {{{ 12 12 #!div style="border: 1pt dotted; margin: 1em; background-color: #fffff9;" 13 '''Note:''' The `#` indicates that the command should be executed as superuser or root .14 }}} 15 16 Get the dependencies. These are required compiling, but you can remove them when you are done if you prefer (except `make`; it should be installed by default and many things depend on it).17 {{{ 18 # yum install autoconf automake cmake freetype-devel gcc gcc-c++ git libtool make mercurial nasm pkgconfig zlib-devel13 '''Note:''' The `#` indicates that the command should be executed as superuser or root and is only required in this guide for the `yum` command. 14 }}} 15 16 Get the dependencies. These are required for compiling, but you can remove them when you are done if you prefer (except `make`; it should be installed by default and many things depend on it). 17 {{{ 18 # yum install autoconf automake bzip2 cmake freetype-devel gcc gcc-c++ git libtool make mercurial nasm pkgconfig zlib-devel 19 19 }}} 20 20 … … 32 32 '''Note:''' If you do not require certain encoders you may skip the relevant section and then remove the appropriate `./configure` option in FFmpeg. For example, if libvorbis is not needed, then skip that section and then remove `--enable-libvorbis` from the [#FFmpeg Install FFmpeg] section. 33 33 }}} 34 35 If a particular library doesn't compile, this may be due to a new bug recently introduced. You can either skip that library or try compiling an older version. This is especially true for libraries obtained via Git. A simple way to look for the last good "release" is the following:36 37 {{{38 $ git clone <URL>39 (note that the "--depth 1" option is absent)40 $ git tag -l41 (look for the most recent release tag.)42 $ git checkout tags/<tag name>43 }}}44 45 Then continue the process as normal.46 34 47 35 === Yasm === … … 57 45 make 58 46 make install 59 make distclean 60 }}} 47 echo 48 }}} 49 50 51 {{{ 52 #!div style="border: 1pt dotted; margin: 1em; background-color: #fffff9;" 53 '''Note:''' The `echo` at the end is just a sacrificial command because some users are forgetting to manually execute the last command when copying and pasting each code block. 54 }}} 55 61 56 62 57 === libx264 === … … 70 65 git clone --depth 1 git://git.videolan.org/x264 71 66 cd x264 72 export PKG_CONFIG_PATH="$HOME/ffmpeg_build/lib/pkgconfig" 73 ./configure --prefix="$HOME/ffmpeg_build" --bindir="$HOME/bin" --enable-static 74 make 75 make install 76 make distclean 67 PKG_CONFIG_PATH="$HOME/ffmpeg_build/lib/pkgconfig" ./configure --prefix="$HOME/ffmpeg_build" --bindir="$HOME/bin" --enable-static 68 make 69 make install 70 echo 77 71 }}} 78 72 … … 90 84 make 91 85 make install 86 echo 92 87 }}} 93 88 … … 106 101 make 107 102 make install 108 make distclean 103 echo 109 104 }}} 110 105 … … 123 118 make 124 119 make install 125 make distclean 120 echo 126 121 }}} 127 122 … … 137 132 cd opus 138 133 autoreconf -fiv 139 export PKG_CONFIG_PATH="$HOME/ffmpeg_build/lib/pkgconfig" 140 ./configure --prefix="$HOME/ffmpeg_build" --disable-shared 141 make 142 make install 143 make distclean 134 PKG_CONFIG_PATH="$HOME/ffmpeg_build/lib/pkgconfig" ./configure --prefix="$HOME/ffmpeg_build" --disable-shared 135 make 136 make install 137 echo 144 138 }}} 145 139 … … 156 150 make 157 151 make install 158 make distclean 152 echo 159 153 }}} 160 154 … … 170 164 tar xzvf libvorbis-1.3.4.tar.gz 171 165 cd libvorbis-1.3.4 172 LDFLAGS="-L$HOME/ffmeg_build/lib"173 CPPFLAGS="-I$HOME/ffmpeg_build/include"174 166 ./configure --prefix="$HOME/ffmpeg_build" --with-ogg="$HOME/ffmpeg_build" --disable-shared 175 167 make 176 168 make install 177 make distclean 169 echo 178 170 }}} 179 171 … … 191 183 make 192 184 make install 193 make clean 185 echo 194 186 }}} 195 187 … … 198 190 {{{ 199 191 cd ~/ffmpeg_sources 200 git clone https://git.ffmpeg.org/ffmpeg.git ffmpeg 192 curl -O http://ffmpeg.org/releases/ffmpeg-snapshot.tar.bz2 193 tar xjvf ffmpeg-snapshot.tar.bz2 201 194 cd ffmpeg 202 PKG_CONFIG_PATH="$HOME/ffmpeg_build/lib/pkgconfig" 203 ./configure --prefix="$HOME/ffmpeg_build" --extra-cflags="-I$HOME/ffmpeg_build/include" --extra-ldflags="-L$HOME/ffmpeg_build/lib -ldl" --bindir="$HOME/bin" --pkg-config-flags="--static" --enable-gpl --enable-nonfree --enable-libfdk-aac --enable-libfreetype --enable-libmp3lame --enable-libopus --enable-libvorbis --enable-libvpx --enable-libx264 --enable-libx265 204 make 205 make install 206 make distclean 195 PKG_CONFIG_PATH="$HOME/ffmpeg_build/lib/pkgconfig" ./configure --prefix="$HOME/ffmpeg_build" --extra-cflags="-I$HOME/ffmpeg_build/include" --extra-ldflags="-L$HOME/ffmpeg_build/lib -ldl" --bindir="$HOME/bin" --pkg-config-flags="--static" --enable-gpl --enable-nonfree --enable-libfdk-aac --enable-libfreetype --enable-libmp3lame --enable-libopus --enable-libvorbis --enable-libvpx --enable-libx264 --enable-libx265 196 make 197 make install 207 198 hash -r 208 199 }}} … … 223 214 {{{ 224 215 rm -rf ~/ffmpeg_build ~/bin/{ffmpeg,ffprobe,ffserver,lame,vsyasm,x264,x265,yasm,ytasm} 225 # yum install autoconf automake cmake gcc gcc-c++ git libtool make mercurial nasm pkgconfig zlib-devel 226 }}} 227 216 # yum install autoconf automake cmake freetype-devel gcc gcc-c++ git libtool make mercurial nasm pkgconfig zlib-devel 217 }}} 228 218 229 219 === Update Yasm === … … 263 253 {{{ 264 254 cd ~/ffmpeg_sources/libvpx 265 make clean255 make distclean 266 256 git pull 267 257 }}} … … 270 260 === Update FFmpeg === 271 261 {{{ 272 cd ~/ffmpeg_sources/ffmpeg 273 make distclean 274 git pull 275 }}} 276 Then run `./configure`, `make`, and `make install` as shown in the [#FFmpeg Install FFmpeg] section. 262 rm -rf ~/ffmpeg_sources/ffmpeg 263 }}} 264 Then re-run the [#FFmpeg Install FFmpeg] section. 277 265 278 266 ---- … … 282 270 {{{ 283 271 rm -rf ~/ffmpeg_build ~/ffmpeg_sources ~/bin/{ffmpeg,ffprobe,ffserver,lame,vsyasm,x264,yasm,ytasm} 284 # yum erase autoconf automake cmakegcc gcc-c++ git libtool mercurial nasm pkgconfig zlib-devel272 # yum erase autoconf automake bzip2 cmake freetype-devel gcc gcc-c++ git libtool mercurial nasm pkgconfig zlib-devel 285 273 hash -r 286 274 }}}
