X-Git-Url: https://git.cinelerra-gg.org/git/?a=blobdiff_plain;f=cinelerra-5.1%2Fbld_appimage.sh;h=fb7a5cb9e5ae2c345442c871de4cdad04dc17341;hb=07a0e1f6f49dc7c4229a3a296b722a0571c17e81;hp=e4d174f58b592773f97f1eaf8885ea5fdb72179d;hpb=194ea84742f4d9973b1aad567fe833ca13a8c4f9;p=goodguy%2Fcinelerra.git diff --git a/cinelerra-5.1/bld_appimage.sh b/cinelerra-5.1/bld_appimage.sh index e4d174f5..fb7a5cb9 100755 --- a/cinelerra-5.1/bld_appimage.sh +++ b/cinelerra-5.1/bld_appimage.sh @@ -1,5 +1,13 @@ #!/bin/bash +# Build Cinelerra-GG as AppImage. +# This follows four steps: +# - Build static version of Cinelerra-GG. +# - If desired and needed, build the manual for context-sensitive help. +# - Organize code and manual in a AppImage specific format AppDir. Do +# this with tool makeappimage, which is built if needed. +# - Call an external tool to make the AppDuir into an AppImage + # We don't do cross-compiling, so the system we're running on # is the target too. Some extra options have to be passed to # the configure script depending on the target. The configure.ac @@ -12,32 +20,48 @@ CONFIG_OPTIONS="--with-single-user --with-booby --enable-static-build" if [ $target = "aarch64" ] ; then CONFIG_OPTIONS="$CONFIG_OPTIONS --disable-dav1d" elif [ $target = "armv7l" ] ; then -CONFIG_OPTIONS="$CONFIG_OPTIONS --disable-dav1d --disable-libaom --disable libwebp --without-nv" +CONFIG_OPTIONS="$CONFIG_OPTIONS --disable-dav1d --disable-libaom --disable-libwebp --without-nv" fi echo configure script options are $CONFIG_OPTIONS -# this should basically be the same as a static build, but the -# "make install" is followed by the appimage creation. After the -# install does its work, the bin directory and subdirectories -# contain the whole application. - # Build Cinelerra itself. ( ./autogen.sh ./configure $CONFIG_OPTIONS make && make install ) 2>&1 | tee log mv Makefile Makefile.cfg cp Makefile.devel Makefile - + +# To include the context-sensitive help, specify the directory +# where the manual source is. This script will then call the "translate" +# script there to build the manual, and copy it to the proper place +# before the AppImage is built. + +CINGG_DIRECTORY=$(pwd) +MANUAL_DIRECTORY=$(pwd)/../../cin-manual-latex + +# Build the manual if the directory is specified and exists, and copy it +# to CinGG +if [ -d "$MANUAL_DIRECTORY" ]; then + pushd $MANUAL_DIRECTORY + # run the build in a subshell so if some error causes an exit + # the popd will still work. + (./translate_manual) 2>&1 | tee $CINGG_DIRECTORY/manual.log + popd + rm -rf bin/doc/CinelerraGG_Manual + cp -r $MANUAL_DIRECTORY/CinelerraGG_Manual bin/doc/ +fi + rm -rf AppDir # remove old in case a file gets deleted from the distribution mkdir AppDir # create lowest level mkdir AppDir/usr cp -r bin AppDir/usr/ # copy whole of bin directory -# Use own version of linuxdeploy, makeappimage, plus plugin makeappimageplugin. -# They should be in the subdirectory tools, if not, go to tools/makeappimagetool -# and do bld.sh there. That will place the two needed executables in tools, and -# then delete all other generated files (except the small log). +# Use own version of linuxdeploy, makeappimage. This should be in +# subdirectory tools, if not, go to tools/makeappimagetool and do bld.sh +# there. That will place the makeappimage executable in tools, and +# then delete all other generated files (except the small log). The tools +# directory is not cleared with "make clean" or "autogen.sh clean" if [ ! -f tools/makeappimage ]; then export cingg=`pwd` @@ -55,7 +79,8 @@ fi # - appimagetool-i686.AppImage # - appimagetool-x86_64.AppImage # Get the appropriate appimagetool from https://github.com/AppImage/AppImageKit/releases -# and put it in your path. Only install the version for your platform. +# and put it in your path. Only install the version for your platform +# and mark it executable. The file name must start with "appimagetool". tools/makeappimage --appdir=AppDir -d image/cin.desktop -i image/cin.svg -e bin/cin -e bin/mpeg2enc -e bin/mplex -e bin/hveg2enc -e bin/lv2ui -e bin/bdwrite -e bin/zmpeg3toc -e bin/zmpeg3show -e bin/zmpeg3cat -e bin/zmpeg3ifochk -e bin/zmpeg3cc2txt -e bin/mplexlo 2>&1 | tee appimage.log