1 \chapter{Installation}
2 \label{cha:Instalation}
3 \section{How to Build Cinelerra-GG from Developer's Git Repository}%
4 \label{sec:How_to_build}
6 These are generic build instructions for building Cinelerra-GG Infinity.
7 Known to work on ubuntu, mint, suse/leap, fedora, debian, centos, arch, and slackware.
8 It has not been tested on every single possible distro yet so you might expect to have to make some minor changes.
9 Patches have been created to build on FreeBSD through the work of another programmer and a Gentoo version is being maintained elsewhere by another programmer.
11 Alternatively, there are some pre-built dynamic or static binaries which are updated on a fairly regular basis (as long as code changes have been made) available at the link below.
14 \url{
15 https://cinelerra-gg.org/download/
16 }
18 There are 2 kinds of builds, the default system-build and a single-user build.
19 A system build has results which are installed to the system.
20 The majority of the files are installed in the standard system paths, but some customization is possible.
21 The single user build allows for running completely out of a local user directory so it doesn't affect the system.
23 We recommend the single-user version when possible.
24 It makes it very easy to install a new version without having to delete the older version in case you want it for backup – once you are happy with the new version, all you have to do is delete the entire old directory path.
25 Also, if you install a new Operating System version and if you have Cinelerra on separate disk space that is preserved, you won't have to reinstall Cinelerra.
26 In addition for purposes of having the ability to interrupt or to see any possible error messages, if you start the application from a terminal window command line you will have more control to catch problems.
27 However, the system builds can be useful in a university lab setting where there are possibly multiple users, or multiple versions.
29 There are two notable differences between “standard” views of Cinelerra and this implementation for the system builds.
30 Both of these can be configured during installation.
31 These differences make it possible to have several different versions installed without having them “walk” on each other.
42 \begin{enumerate}
43     \item
44         application name can be set during installation and defaults to: “\texttt{cin}”
45     \item
46         the home configuration directory can also be set and defaults to:\\ “\texttt{\$HOME/.bcast5}” 47 \end{enumerate} 49 \paragraph{To do a system build,} you should read the \texttt{README} that is at the top level after you get the source. 51 \begin{enumerate} 52 \item 53 You need at least 2.5\,GB of disk storage to operate a build + you need to have “\texttt{git}” installed. 54 \item Obviously in order to install into the system, you must run as \textbf{root}. 55 \item The "\texttt{git}" step has to download many files (approx 100\,MB) so allow time. 56 \item Run the following commands (this takes awhile): 58 \begin{lstlisting}[language=bash] 59 cd /<build_path>/ # this is where you need the 2.5GB of disk space 60 git clone --depth 1 "git://git.cinelerra-gg.org/goodguy/cinelerra.git" cinelerra5 61 cd cinelerra5/cinelerra-5.1 # toplevel directory 62 \end{lstlisting} 64 NOTE: if your system has never had Cinelerra-GG Infinity installed, you will have to make sure you have all of the compilers and libraries necessary. 65 So on the very first build you should run: 67 \begin{lstlisting}[language=bash] 68 ./blds/bld_prepare.sh <os> # where <os> represents the Operating System of centos, fedora, suse, leap, ubuntu, debian. 69 ./autogen.sh 70 ./configure --prefix=/usr # optional parameters can be added here 71 make 2>&1 | tee log # make and log the build 72 \end{lstlisting} 73 \item Check for obvious build errors: 74 \begin{lstlisting}[language=bash] 75 grep "\*\*\*.*error" -ai log 76 \end{lstlisting} 77 If this reports errors and you need assistance or you think improvements can be made to the build s, 78 email the log which is listed below to \url{cin@lists.cinelerra-gg.org:} 79 \begin{lstlisting}[language=bash] 80 /<build_path>/cinelerra5/cinelerra-5.1/log 81 \end{lstlisting} 82 \item If there are no build errors, finally just run: 83 \begin{lstlisting}[language=bash] 84 make install 85 \end{lstlisting} 86 \item If it all worked, you are all setup. Just click on the cinelerra desktop icon. 87 \end{enumerate} 89 \paragraph{To do a single-user build,} read the \texttt{README} that is at the top level after you get the source. 90 \begin{enumerate} 91 \item You need at least 2.5\,GB of disk storage to operate a build + you need to have “\texttt{git}” installed. 92 \item Recommend you build and run as \textbf{root}, just to avoid permission issues initially. 93 \item The "\texttt{git}" step has to download many files (approx 100\,MB) so allow time. 94 \item Run the following commands (this takes awhile): 95 \begin{lstlisting}[language=bash] 96 cd /<build_path>/ # this is where you need the 2.5GB of disk space 97 git clone --depth 1 "git://git.cinelerra-gg.org/goodguy/cinelerra.git" cinelerra5 98 cd cinelerra5/cinelerra-5.1 # toplevel directory 99 \end{lstlisting} 100 \end{enumerate} 102 NOTE: if your system has never had Cinelerra-GG Infinity installed, you will have to make sure all 103 the compilers and libraries necessary are installed. So on the very first build you should run as \textbf{root}: 105 \begin{lstlisting}[language=bash] 106 ./blds/bld_prepare.sh <os> # where <os> represents the Operating System of centos, fedora, suse, leap, ubuntu, debian. 107 ./autogen.sh 108 ./configure --with-single-user # the “with-single-user” parameter makes it so 109 make 2>&1 | tee log # make and log build (check for errors before proceeding) 110 make install 111 \end{lstlisting} 113 Then just start the application by keying in: ./cin in the bin subdirectory OR add a desktop icon by 114 using the appropriate directory to copy the files to, run as \textbf{root}, and edit to correct the directory path. 116 \begin{lstlisting}[language=bash] 117 cd /cinelerra_directory_path 118 cp -a image/cin.{svg,xpm} /usr/share/pixmaps/. 119 cp -a image/cin.desktop /usr/share/applications/cin.desktop 120 change the “Exec=cin” line to be “Exec=<your_directory_path>/bin/cin” 121 \end{lstlisting} 123 The preceding directions for doing a single-user build has been meticulously followed to build and run 124 on a newly installed ubuntu 15 system WITHOUT BEING ROOT except for the \texttt{bld\_prepare.sh} and creating the desktop icon. 126 \subsection{Notable Options and Caveats}% 127 \label{sub:notable_options_and_caveats} 129 These procedures and the Cinelerra-GG Infinity software have all been run as “\textbf{root}” on various home laptops and desktops. This provides the best chance to ensure all works correctly and also allows for handling errors, other problems and potential crashes with the most success. Included in this section are some of the build variations easily available for normal builds. 131 To see the full list of features use: 133 \begin{lstlisting}[language=bash] 134 ./configure –help 135 \end{lstlisting} 136 The default build is a system build which uses: 138 \begin{lstlisting}[language=bash] 139 ./configure –without-single-user 140 \end{lstlisting} 142 In the single-user build, the target directory is always “cin”. 143 Because this is also the developer build, constant names are used throughout. 144 However, you can rename files after the install is complete. 146 f your distro/operating system has issues with the default install to \texttt{/usr/local}, you might have to change the location to /usr for a system build. Then you will have to use: 147 \begin{lstlisting}[language=bash] 148 ./configure --prefix=/usr 149 \end{lstlisting} 151 If you wish to change the default directory for a system build you will have to add the destination directory path on the “\texttt{make install}” line. For example: 152 \begin{lstlisting}[language=bash] 153 make install DESTDIR=<your selected target directory path> 154 \end{lstlisting} 156 The application name can be set during installation, but defaults to cin so that the GG/Infinity build can coexist with other Cinelerra builds if necessary. To override the default cin name, use: 157 \begin{lstlisting}[language=bash] 158 ./configure --with-exec-name=cinelerra 159 \end{lstlisting} 161 The home configuration directory can also be set, but defaults to \texttt{\$\$HOME/.bcast5}. 162 For example: 164 \begin{lstlisting}[language=bash] 165 ./configure –with-config-dir=/myusername/.bcast5 166 \end{lstlisting} 168 NOTE: when you specify parameters to the configure program, it will create a make file as a consequence. 169 Since in a make file, the \$ is a special character, it must be escaped so in order to represent a \$as part of an input parameter, it has to be stuttered. 170 That is, you will need \$\$(2 dollar signs) to represent a single dollar sign. 172 It may be necessary on some distros which have missing or incomplete up-to-date libraries, to build cinelerra without Ladspa. 173 To do so, use: 175 \begin{lstlisting}[language=bash] 176 ./configure --prefix=/usr --without-ladspa-build 177 \end{lstlisting} 179 Note that the with-ladspa-dir is the ladspa search path, and exists even if the ladspa build is not selected. This gives you the ability to specify an alternate ladspa system path by utilizing the \texttt{LADSPA\_PATH} environment variable (that is, the default ladspa build is deselected). 181 Note for 32-bit 14.2 Slackware, Debian, Gentoo, Arch, FreeBSD, before running the configure, you will need to set up the following: 183 \begin{lstlisting}[language=bash] 184 export ac_cv_header_xmmintrin_h=no 185 export FFMPEG_EXTRA_CFG=" --disable-vdpau" 186 \end{lstlisting} 188 \subsection{Notes about Building from Git in your Customized Environment}% 189 \label{sub:notes_about_building_from_git_in_your_customized_environment} 191 Getting a build to work in a custom environment is not easy. If you have already installed libraries which are normally in the thirdparty build, getting them to be recognized means you have to install the "devel" version so the header files which match the library interfaces exist. Below is the list of thirdparty builds, but this list may have changed over time: 192 % It's list of Table? 194 \begin{table}[htpb] 195 \centering 196 \caption{List of thirdparty builds} 197 \label{tab:List_of_thirdparty_builds} 198 \begin{tabular}{m{8em}c} 199 \toprule 200 a52dec & yes\\ 201 djbfft & yes\\ 202 fdk & auto\\ 203 ffmpeg & yes\\ 204 fftw & auto\\ 205 flac & auto\\ 206 giflib & yes\\ 207 ilmbase&auto\\ 208 lame & auto\\ 209 libavc1394&auto\\ 210 libraw1394&auto\\ 211 libiec61883&auto\\ 212 libdv &auto\\ 213 libjpeg &auto\\ 214 openjpeg &auto\\ 215 libogg &auto\\ 216 libsndfile&auto\\ 217 libtheora&auto\\ 218 libuuid & yes\\ 219 libvorbis&auto\\ 220 mjpegtools&yes\\ 221 openexr &auto\\ 222 tiff &auto\\ 223 twolame &auto\\ 224 x264 &auto\\ 225 x265 &auto\\ 226 libvpx &auto\\ 227 libwebp&auto\\ 228 libaom& auto\\ 229 \bottomrule 230 \end{tabular} 231 \end{table} 234 The "yes" means force build and “auto” means probe and use the system version if the build operation is not static. 235 To get your customized build to work, you need to change the probe options for the conflicting libraries from "yes" to "auto", or even rework the \texttt{configure.ac} script. 236 There may be several libraries which need special treatment. 238 An example of a problem you might encounter with your customized installation is with “\texttt{a52dec}” which has probes \texttt{(CHECK\_LIB/CHECK\_HEADER)} in \texttt{configure.ac}, but \texttt{djbfft} does not. 239 In this case, \texttt{djbfft} is only built because \texttt{a52dec} is built, so if your system has \texttt{a52dec}, set \texttt{a52dec} to auto and see if that problem is solved by retrying the build with: 240 \begin{lstlisting}[language=bash] 241 ./confgure --with-single-user –enable-a52dec=auto . 242 \end{lstlisting} 244 With persistence, you can get results, but it may take several tries to stabilize the build. 245 If you need help, email the "\texttt{log}" and "\texttt{config.log}", which is usually sufficient to determine why a build failed. 247 If you have already installed the \texttt{libfdk\_aac} development package on your computer because you prefer this version over the default aac, you will have to do the following to get this alternative operational. 249 \begin{lstlisting}[language=bash] 250 export FFMPEG_EXTRA_CFG=" --enable-libfdk-aac --enable-nonfree" 251 export EXTRA_LIBS=" -lfdk-aac" 252 for f in grep -lw aac cinelerra-5.1/ffmpeg/audio/*; do 253 sed -e 's/\<aac\>/libfdk_aac/' -i$f
254 done
255 \end{lstlisting}