3 # script for pulling together a Linux app bundle.
5 # This will create a bundle for a single architecture.
6 # Execute this scirpt on both x86 and x86_64 and then use
7 # package to merge the 2 bundles into a final package with the
8 # installer. See "noderun" for a complete build script.
10 # where the GTK stack is installed
11 GTKSTACK_ROOT=$HOME/gtk/inst
12 # where the Ardour dependencies are installed
13 ARDOURSTACK_ROOT=$HOME/a3/inst
14 # the waf build tree to use when copying built/generated files
15 BUILD_ROOT=../../build
17 . ../define_versions.sh
19 # where harvid and xjadeo binaries are cached
20 if test -z "$CACHEDIR" -o ! -d "$CACHEDIR"; then
38 NOSTRIP="libsuil|libserd|libsord|liblilv|libsratom|liblrdf|libardour|libpbd|libevoral"
39 : ${HARRISONCHANNELSTRIP=harrison_channelstrip}
42 if [ $# -eq 0 ] ; then
44 echo "ERROR - Please specify build type"
51 while [ $# -gt 0 ] ; do
56 # top level build targets
94 --test) WITH_LADSPA=; STRIP= ; shift ;;
97 # specific build flags
100 --nojack) INTERNAL_JACK= ; shift ;;
101 --noladspa) WITH_LADSPA= ; shift ;;
102 --strip) STRIP=$2 ; shift ; shift ;;
103 --sysdeps) PRINT_SYSDEPS=1; shift ;;
104 --nls) WITH_NLS=1 ; shift ;;
105 --harvid) WITH_HARVID=1 ; shift ;;
106 --gcc5abi) GCC5ABI=true ; shift ;;
107 --chanstrip) HARRISONCHANNELSTRIP=$2 ; shift; shift ;;
110 #catch all for unknown arguments
112 echo "!!! ERROR !!! - Unknown argument $1"
119 if test x$STRIP != xall -a x$STRIP != xnone -a x$STRIP != xsome ; then
120 echo "Unknown strip option \"$STRIP\""
121 echo "Legal values are: all, none, some"
125 . ../define_versions.sh
127 echo "Version is $release_version"
128 if [ "x$commit" != "x" ] ; then
129 info_string="$release_version ($commit) built on `hostname` by `whoami` on `date`"
131 info_string="$release_version built on `hostname` by `whoami` on `date`"
133 echo "Info string is $info_string"
135 # Figure out our CPU type
137 i[3456789]86|x86|i86pc)
138 echo "Architecture is x86"
143 MULTIARCH='i386-linux-gnu'
146 echo "Architecture is x86_64"
151 MULTIARCH='x86_64-linux-gnu'
155 echo "ERROR - Unknown architecture `uname -m`"
161 if [ x$DEBUG = xT ]; then
163 if [ x$STRIP = xall ] ; then
164 echo "A debug build with --strip all makes no sense - STRIP reset to \"some\""
169 # setup directory structure
171 if [ -z "${BUILDTYPE}" ]; then
172 APPDIR=${APPNAME}_${ARCH}-${release_version}
173 APP_VER_NAME=${APPNAME}-${release_version}
175 APPDIR=${APPNAME}_${ARCH}-${release_version}-${BUILDTYPE}
176 APP_VER_NAME=${APPNAME}-${release_version}-${BUILDTYPE}
185 Plugins=$APPLIB/plugins
186 Surfaces=$APPLIB/surfaces
187 Panners=$APPLIB/panners
188 Backends=$APPLIB/backends
190 Themes=$Shared/themes
191 Templates=$Shared/templates
192 ExportFormats=$Shared/export
193 Locale=$Shared/locale
194 MidiMaps=$Shared/midi_maps
195 PatchFiles=$Shared/patchfiles
196 LuaScripts=$Shared/scripts
197 MackieControl=$Shared/mcp
199 if [ x$PRINT_SYSDEPS != x ] ; then
201 # print system dependencies
204 for file in $APPBIN/* $Libraries/* $Plugins/*.so ; do
205 if ! file $file | grep -qs Mach-O ; then
208 otool -L $file | awk '{print $1}' | egrep -v "(^@executable_path|^Ardour[0-9][.0-9]*.app)"
213 echo "Removing old $APPDIR tree ..."
216 echo "Building new app directory structure ..."
218 # only bother to make the longest paths
231 mkdir -p $MackieControl
232 mkdir -p $ExportFormats
238 # maybe set variables
239 ENVIRONMENT=environment
243 if test x$MIXBUS != x ; then
244 echo export ARDOUR_MIXBUS=true >> $ENVIRONMENT
246 # current default for MIXBUS version is US keyboard layout without a keypad
248 echo export ARDOUR_KEYBOARD_LAYOUT=us-nokeypad >> $ENVIRONMENT
249 echo export ARDOUR_UI_CONF=ardour3_ui.conf >> $ENVIRONMENT
253 # if we're not going to bundle JACK, make sure we can find
254 # jack in the places where it might be
257 echo export 'PATH=/usr/local/bin:/opt/bin:$PATH' >> $ENVIRONMENT
259 # create startup helper script
260 if test -d $BUILD_ROOT/vst; then
263 echo export INSTALL_DIR >> $ENVIRONMENT
268 sed -e "/^%ENV%/r $ENVIRONMENT" -e '/^%ENV%/d' -e 's/%VER%/'"${release_version}"'/;s/%EXENAME%/'"${EXENAME}"'/;s/%WINE%/'"$WINEEXE"'/' < ardour.sh.in > $APPBIN/${EXENAME}${major_version}
269 rm $ENVIRONMENT && chmod 775 $APPBIN/${EXENAME}${major_version}
271 echo "Copying ardour executable ...."
272 if test -d $BUILD_ROOT/vst; then
273 #cp -v $BUILD_ROOT/gtk2_ardour/libgtk2_ardour.so $APPLIB/
274 cp -v $BUILD_ROOT/gtk2_ardour/ardour-${release_version}-vst.exe.so $APPBIN/${EXENAME}-${release_version}
276 cp -v $BUILD_ROOT/gtk2_ardour/ardour-${release_version}* $APPBIN/${EXENAME}-${release_version}
279 if test x$STRIP = xall ; then
280 strip -s $APPBIN/${EXENAME}-${release_version}
284 # note that at present(feb 2011), the .mo files end up in the source tree which is
285 # not really as it should be.
286 if test x$WITH_NLS != x ; then
287 echo "NLS support ..."
288 echo "I hope you remembered to run scons msgupdate!"
291 for pkg in gtk2_ardour libs/ardour libs/gtkmm2ext ; do
292 files=`find ../../$pkg -name "*.mo"`
295 # the package name is appended with a number so that
296 # it can be parallel installed during a regular install
297 # with older (and newer) versions. it is just the major
298 # number of the release (i.e. leading digits)
301 vsuffix=`echo $release_version | sed 's/^\([0-9][0-9]*\).*/\1/'`
303 if [ -z "$files" ]; then
305 echo "!!!! WARNING !!!! - Did not find any .mo files in ../../$pkg"
312 lang=`basename $file | sed 's/\.mo//'`
313 mkdir -p $Locale/$lang/LC_MESSAGES
314 cp $file $Locale/$lang/LC_MESSAGES/`basename $pkg`$vsuffix.mo
315 echo copy $file to $Locale/$lang/LC_MESSAGES/`basename $pkg`$vsuffix.mo
316 if echo $LINGUAS | grep $lang >/dev/null 2>&1 ; then
319 LINGUAS="$LINGUAS $lang"
324 GTK_MESSAGES="atk10.mo gdk-pixbuf.mo gtk20-properties.mo gtk20.mo atk10.mo glib20.mo"
325 LOCALEROOT=$GTKSTACK_ROOT/share/locale
327 for l in $LINGUAS ; do
328 echo "Copying GTK i18n files for $l..."
329 for MO in $GTK_MESSAGES ; do
330 if [ -f $LOCALEROOT/$l/LC_MESSAGES/$MO ] ; then
331 cp $LOCALEROOT/$l/LC_MESSAGES/$MO $Locale/$l/LC_MESSAGES
333 # try with just the language spec
334 just_lang=`echo $l | sed 's/_[A-Z][A-Z]$//'`
335 if [ -f $LOCALEROOT/$just_lang/LC_MESSAGES/$MO ] ; then
336 cp $LOCALEROOT/$just_lang/LC_MESSAGES/$MO $Locale/$just_lang/LC_MESSAGES
342 echo "Skipping NLS support"
346 # Copy stuff that may be dynamically loaded
349 cp -R $GTKSTACK_ROOT/etc/* $Etc
351 # We rely on clearlooks, so include a version from our own build tree
352 # this one is special - we will set GTK_PATH to $Libraries/gtkengines
354 GTK_ENGINE_DIR=$Libraries/gtkengines/engines
355 mkdir -p $GTK_ENGINE_DIR
357 echo "Copying GTK engines ..."
358 cp $BUILD_ROOT/libs/clearlooks-newer/libclearlooks.so $Libraries
359 (cd $GTK_ENGINE_DIR && ln -s ../../libclearlooks.so . )
361 cp $GTKSTACK_ROOT/lib/gtk-2.0/2.10.0/engines/libpixmap.so $Libraries
362 (cd $GTK_ENGINE_DIR && ln -s ../../libpixmap.so . )
365 if test x$WITH_LADSPA != x ; then
366 if test x$MIXBUS != x ; then
367 plugdir=mixbus_ladspa
371 echo "Copying `ls $plugdir | wc -l` plugins ..."
372 if [ -d $plugdir ] ; then
374 cp -r $plugdir/* $Plugins
379 cp $BUILD_ROOT/libs/surfaces/*/libardour_*.so* $Surfaces
380 cp $BUILD_ROOT/libs/surfaces/control_protocol/libardourcp.so* $Libraries
383 # got to be careful with names here
384 for x in $BUILD_ROOT/../midi_maps/*.map ; do
389 # got to be careful with names here
390 for x in $BUILD_ROOT/../patchfiles/*.midnam ; do
395 # got to be careful with names here
396 for x in $BUILD_ROOT/../scripts/*.lua ; do
397 if test "${x:0:1}" = "_"; then
404 # got to be careful with names here
405 for x in $BUILD_ROOT/../mcp/*.device $BUILD_ROOT/../mcp/*.profile ; do
406 cp "$x" $MackieControl
410 #for f in $BUILD_ROOT/../templates/* ; do
411 # if [ -d "$f" ] ; then
412 # echo Template: $f ; cp -r "$f" $Templates ;
417 # got to be careful with names here
418 for x in $BUILD_ROOT/../export/*.preset $BUILD_ROOT/../export/*.format ; do
419 cp "$x" $ExportFormats
423 cp $BUILD_ROOT/libs/panners/*/lib*.so* $Panners
426 for backend in jack alsa dummy wavesaudio ; do
427 cp $BUILD_ROOT/libs/backends/$backend/lib*.so* $Backends
430 # VAMP plugins that we use
431 cp $BUILD_ROOT/libs/vamp-plugins/libardourvampplugins.so* $Libraries
433 # Suil modules (new dir 'build-stack')
434 if test -d $GTKSTACK_ROOT/lib/suil-0/ ; then
435 cp $GTKSTACK_ROOT/lib/suil-0/lib* $Libraries
438 # Suil modules (old dir 'build-ardour-stack')
439 if test -d $ARDOURSTACK_ROOT/lib/suil-0/ ; then
440 cp $ARDOURSTACK_ROOT/lib/suil-0/lib* $Libraries
443 # VST scanner app (both LXVST as well as WIN-VST, 2in1)
444 # (if build with wine: ardour-vst-scanner is a wrapper
445 # script for ardour-vst-scanner.exe.so, if VST is disabled
446 # neither binary nor script exists)
447 if test -d $BUILD_ROOT/libs/fst ; then
448 cp $BUILD_ROOT/libs/fst/ardour-vst-scanner* $APPLIB || true
449 if test x$STRIP = xall ; then
450 strip -s $APPLIB/ardour-vst-scanner*
455 if test -f $BUILD_ROOT/libs/vfork/ardour-exec-wrapper ; then
456 cp $BUILD_ROOT/libs/vfork/ardour-exec-wrapper $APPLIB
457 if test x$STRIP = xall ; then
458 strip -s $APPLIB/ardour-exec-wrapper
462 # ALSA device reservation tool (if available)
463 if test -f $BUILD_ROOT/libs/ardouralsautil/ardour-request-device; then
464 cp $BUILD_ROOT/libs/ardouralsautil/ardour-request-device $APPLIB/ || true
465 if test x$STRIP = xall ; then
466 strip -s $APPLIB/ardour-request-device
470 OURLIBDIR=$BUILD_ROOT/libs
471 OURLIBS=$OURLIBDIR/vamp-sdk:$OURLIBDIR/surfaces/control_protocol:$OURLIBDIR/ardour:$OURLIBDIR/midi++2:$OURLIBDIR/pbd:$OURLIBDIR/rubberband:$OURLIBDIR/soundtouch:$OURLIBDIR/gtkmm2ext:$OURLIBDIR/sigc++2:$OURLIBDIR/glibmm2:$OURLIBDIR/gtkmm2/atk:$OURLIBDIR/gtkmm2/pango:$OURLIBDIR/gtkmm2/gdk:$OURLIBDIR/gtkmm2/gtk:$OURLIBDIR/canvas:$OURLIBDIR/libsndfile:$OURLIBDIR/evoral:$OURLIBDIR/evoral/src/libsmf:$OURLIBDIR/audiographer:$OURLIBDIR/timecode:$OURLIBDIR/taglib:$OURLIBDIR/libltc:$OURLIBDIR/qm-dsp:$OURLIBDIR/ardouralsautil:$OURLIBDIR/ptformat:$BUILD_ROOT/gtk2_ardour
473 echo $OURLIBS${LD_LIBRARY_PATH:+:$LD_LIBRARY_PATH}
477 # these are dynamically loaded by NSS
478 deplibs="libfreeblpriv3.so libsoftokn3.so libnsspem.so"
479 cp -v $GTKSTACK_ROOT/lib/libsoftokn3.so $Libraries/
480 cp -v $GTKSTACK_ROOT/lib/libfreeblpriv3.so $Libraries/
481 cp -v $GTKSTACK_ROOT/lib/libnsspem.so $Libraries/
482 chrpath -r foo $Libraries/libsoftokn3.so
483 chrpath -r foo $Libraries/libfreeblpriv3.so
484 chrpath -r foo $Libraries/libnsspem.so
488 filelist=`find $APPLIB/ -type f`
489 filelist="$APPBIN/${EXENAME}-${release_version} $filelist"
491 for file in $filelist ; do
492 if ! file $file | grep -qs ELF ; then
496 # speed this up a bit by not checking things multiple times.
497 for i in "${depCheckedList[@]}"; do
498 if [ $i == $file ]; then
502 depCheckedList[$checkIdx]=$file
503 checkIdx=$(($checkIdx + 1))
505 # ignore suil/qt wrappers - the plugin will pull in QT4.
506 if echo $file | grep -qs 'libsuil_.*qt4' ; then continue; fi
508 # do not include libjack, nor libwine
509 deps=`LD_LIBRARY_PATH=$OURLIBS${LD_LIBRARY_PATH:+:$LD_LIBRARY_PATH} ldd $file | grep -v libwine.so | awk '{print $3}'`
512 for dep in $deps ; do
513 if test "not" = ${dep}; then
515 echo "!!! ERROR !!! - Missing dependant library for $file."
516 echo "Searched: " $OURLIBS${LD_LIBRARY_PATH:+:$LD_LIBRARY_PATH}
518 (LD_LIBRARY_PATH=$OURLIBS${LD_LIBRARY_PATH:+:$LD_LIBRARY_PATH} ldd $file)
520 echo "!!! ERROR !!! - See Above"
524 # don't use anything mapped at a specific address
525 if echo $dep | grep -qs '0x' ; then continue; fi
527 if echo $dep | grep -qs "^/lib/" ; then continue; fi
529 if echo $dep | grep -qs libjack ; then continue; fi
531 if echo $dep | grep -qs libasound ; then continue; fi
532 # don't include any X Window libraries
533 if echo $dep | grep -qs libX\. ; then continue; fi
534 if echo $dep | grep -qs libxcb ; then continue; fi
535 if echo $dep | grep -qs libICE\. ; then continue; fi
536 if echo $dep | grep -qs libSM\. ; then continue; fi
538 if echo $dep | grep -qs 'libc\.' ; then continue; fi
539 # don't include libstdc++
540 if echo $dep | grep -qs libstdc++ ; then continue; fi
541 # don't include libdbus
542 if echo $dep | grep -qs libdbus ; then continue; fi
545 if ! test -f $Libraries/$base; then
546 parent=$(basename ${file})
547 if echo $dep | grep -sq '^libs' ; then
548 echo "Copying dependant lib $BUILD_ROOT/$dep (required by ${parent})"
549 cp $BUILD_ROOT/$dep $Libraries
551 echo "Copying dependant lib $dep (required by ${parent})"
555 # reset RPATH so that the runtime linker never looks
556 # in places we don't want it to
558 chrpath -r foo $Libraries/`basename $dep`
559 if echo $dep | grep -sq '^/' ; then
560 # absolute path, candidate for stripping
561 deplibs="$deplibs $base"
567 if test x$missing = xfalse ; then
568 # everything has been found
575 if test x$STRIP = xall ; then
576 echo Stripping all libraries
577 # Must be writable so that we can strip
578 find $APPLIB/ -name "*.so*" -print0 | xargs -0 chmod u+w
580 find $APPLIB/ -name "*.so*" -print0 | xargs -0 strip -s
581 elif test x$STRIP = xsome ; then
582 echo Stripping dependent libraries
583 for l in $deplibs ; do
584 if echo "$l" | grep -qE "$NOSTRIP"; then
591 find $APPLIB/ -name "*.so*" -print0 | xargs -0 chmod a+rx
593 echo "Copying other stuff to $APPDIR ..."
595 # these are all generated by waf
596 cp $BUILD_ROOT/gtk2_ardour/ardour.keys $Etc
597 cp $BUILD_ROOT/gtk2_ardour/ardour.menus $Etc
598 cp $BUILD_ROOT/gtk2_ardour/clearlooks.rc $Etc
599 cp $BUILD_ROOT/gtk2_ardour/default_ui_config $Etc
601 # Copied directly from source tree
603 mkdir ${Shared}/icons
604 mkdir ${Shared}/resources
605 cp ../../system_config $Etc/system_config
606 cp ../../instant.xml $Shared/instant.xml
607 cp ../../gtk2_ardour/icons/*.png ${Shared}/icons
608 cp -r ../../gtk2_ardour/icons/cursor_* ${Shared}/icons/
609 cp ../../gtk2_ardour/ArdourMono.ttf $Shared
610 cp ../../gtk2_ardour/resources/${APPNAME}-* ${Shared}/resources/
612 # Themes: only install those named for this app
613 lower_case_appname=`echo $APPNAME | tr '[:upper:]' '[:lower:]'`
614 cp ../../gtk2_ardour/themes/*-${lower_case_appname}.colors $Themes
617 # put sooper sekrit ingredients here and they will be copied
620 if [ -d specialSauce ] ; then
621 cp -r specialSauce $Etc
624 # install bundled LV2s to <app>/lib/LV2/
625 cp -R $BUILD_ROOT/libs/LV2 $APPLIB/
627 # lv2 core, classifications etc - TODO check if we need the complete LV2 ontology
628 if test -d $ARDOURSTACK_ROOT/lib/lv2/lv2core.lv2 ; then
629 mkdir -p $APPLIB/LV2/lv2core.lv2
630 cp -R $ARDOURSTACK_ROOT/lib/lv2/lv2core.lv2/*.ttl $APPLIB/LV2/lv2core.lv2/
631 elif test -d $GTKSTACK_ROOT/lib/lv2/lv2core.lv2 ; then
632 mkdir -p $APPLIB/LV2/lv2core.lv2
633 cp -R $GTKSTACK_ROOT/lib/lv2/lv2core.lv2/*.ttl $APPLIB/LV2/lv2core.lv2/
636 # go through and recursively remove any .svn dirs in the bundle
637 for svndir in `find $APPDIR -name .svn -type d`; do
642 ################################################################################
643 ### Mixbus plugins, etc
644 if test x$WITH_HARRISON_LV2 != x ; then
645 echo "Adding Harrison LV2s"
648 curl -s -S --fail -# \
649 -z "${CACHEDIR}/harrison_lv2s.${HARCH}.zip" \
650 -o "${CACHEDIR}/harrison_lv2s.${HARCH}.zip" \
651 "http://www.harrisonconsoles.com/mixbus/mb3/beta/harrison-dsp/harrison_lv2s.${HARCH}.zip"
652 unzip -q -d "$APPLIB/LV2/" "${CACHEDIR}/harrison_lv2s.${HARCH}.zip"
655 if test -n "$MIXBUS"; then
656 echo "Adding Mixbus Channelstrip"
658 mkdir -p $APPLIB/ladspa/strip/
659 curl -s -S --fail -# \
660 -z "${CACHEDIR}/${HARRISONCHANNELSTRIP}.${HARCH}.so" \
661 -o "${CACHEDIR}/${HARRISONCHANNELSTRIP}.${HARCH}.so" \
662 "http://www.harrisonconsoles.com/mixbus/mb3/beta/harrison-dsp/${HARRISONCHANNELSTRIP}.${HARCH}.so"
664 cp "${CACHEDIR}/${HARRISONCHANNELSTRIP}.${HARCH}.so" \
665 $APPLIB/ladspa/strip/${HARRISONCHANNELSTRIP}.so
666 chmod +x $APPLIB/ladspa/strip/${HARRISONCHANNELSTRIP}.so
668 echo "Adding Harrison Vamp Plugins"
670 if test "$GCC5ABI" = "true"; then
671 VAMPARCH="${HARCH}gcc5"
675 curl -s -S --fail -# \
676 -z "${CACHEDIR}/harrison_vamp.${VAMPARCH}.so" \
677 -o "${CACHEDIR}/harrison_vamp.${VAMPARCH}.so" \
678 "http://www.harrisonconsoles.com/mixbus/mb3/beta/harrison-dsp/harrison_vamp.${VAMPARCH}.so"
680 cp "${CACHEDIR}/harrison_vamp.${VAMPARCH}.so" \
681 $APPLIB/harrison_vamp.so
682 chmod +x $APPLIB/harrison_vamp.so
685 if test x$WITH_X42_LV2 != x ; then
688 echo "Adding x42 Plugins"
690 for proj in x42-meters x42-midifilter x42-midimap x42-stereoroute x42-eq setBfree; do
691 X42_VERSION=$(curl -s -S http://x42-plugins.com/x42/linux/${proj}.latest.txt)
692 rsync -a -q --partial \
693 rsync://x42-plugins.com/x42/linux/${proj}-lv2-linux-${WARCH}-${X42_VERSION}.zip \
694 "${CACHEDIR}/${proj}-lv2-linux-${WARCH}-${X42_VERSION}.zip"
695 unzip -q -d "$APPLIB/LV2/" "${CACHEDIR}/${proj}-lv2-linux-${WARCH}-${X42_VERSION}.zip"
698 ################################################################################
701 if test x$WITH_HARVID != x ; then
703 HARVID_VERSION=$(curl -s -S http://ardour.org/files/video-tools/harvid_version.txt)
704 XJADEO_VERSION=$(curl -s -S http://ardour.org/files/video-tools/xjadeo_version.txt)
707 rsync://ardour.org/video-tools/harvid-${MULTIARCH}-${HARVID_VERSION}.tgz \
708 "$CACHEDIR/harvid-${MULTIARCH}-${HARVID_VERSION}.tgz"
711 rsync://ardour.org/video-tools/xjadeo-${MULTIARCH}-${XJADEO_VERSION}.tgz \
712 "$CACHEDIR/xjadeo-${MULTIARCH}-${XJADEO_VERSION}.tgz"
715 --exclude=README --exclude=harvid.1 --strip-components=1 \
716 -f "$CACHEDIR/harvid-${MULTIARCH}-${HARVID_VERSION}.tgz" || exit 1
719 --exclude=README --exclude=xjadeo.1 --strip-components=1 \
720 -f "$CACHEDIR/xjadeo-${MULTIARCH}-${XJADEO_VERSION}.tgz" || exit 1
726 # Add the uninstaller
728 sed -e "s/%REPLACE_PGM%/${APPNAME}/" -e "s/%REPLACE_VENDOR%/${VENDOR}/" -e "s/%REPLACE_MAJOR_VERSION%/${major_version}/" -e "s/%REPLACE_VERSION%/${release_version}/" -e "s/%REPLACE_TYPE%/${BUILDTYPE}/" < uninstall.sh.in > $APPBIN/${APP_VER_NAME}.uninstall.sh
729 chmod a+x $APPBIN/${APP_VER_NAME}.uninstall.sh
732 # Add the stage2.run script
734 sed -e "s/%REPLACE_MAJOR_VERSION%/${major_version}/;s/%REPLACE_PGM%/${APPNAME}/;s/%REPLACE_VENDOR%/${VENDOR}/;s/%REPLACE_EXE%/${EXENAME}/;s/%REPLACE_GCC5%/${GCC5ABI}/;s/%REPLACE_WINE%/${USEWINE}/" < stage2.run.in > stage2.run
739 if [ -e $BUILD_ROOT/tools/sanity_check/sanityCheck ]; then
740 cp $BUILD_ROOT/tools/sanity_check/sanityCheck $APPBIN
742 echo "!!!ERROR !!! sanityCheck program is missing. packager will exit without being complete"
746 echo "Building tarball ..."
749 tar -cf $APPDIR.tar $APPDIR
751 echo "Calculating bundle size"
752 du -sb $APPDIR/ | awk '{print $1}' > $APPDIR.size
754 ( cd $APPDIR ; find . ) > file_list.txt