Added undocumented mount and debug modes to the appimage
authorArt Cancro <ajc@citadel.org>
Sat, 8 May 2021 22:37:38 +0000 (18:37 -0400)
committerArt Cancro <ajc@citadel.org>
Sat, 8 May 2021 22:37:38 +0000 (18:37 -0400)
appimage/build_appimage.sh
appimage/citadel.AppDir/AppRun

index ed363a5e0cb48214951a6c4c01484318c32b5b68..a1675de11e03ee95c51b753b88aff27add487cac 100755 (executable)
@@ -39,7 +39,7 @@ mkdir -p citadel.AppDir/usr/bin
 mkdir -p citadel.AppDir/usr/lib
 
 # Copy over all the libraries we used
-for bin in $CITADEL_BUILD_DIR/citserver $WEBCIT_BUILD_DIR/webcit $CITADEL_BUILD_DIR/ctdlmigrate
+for bin in $CITADEL_BUILD_DIR/citserver $WEBCIT_BUILD_DIR/webcit $CITADEL_BUILD_DIR/ctdlmigrate `which gdb`
 do
        for x in `ldd $bin | awk ' { print $3 } ' | grep -v -e '^$' | grep -v 'libc.so' | grep -v 'libpthread.so' | grep -v 'libresolv.so'`
        do
@@ -49,7 +49,7 @@ done
 ldconfig -v citadel.AppDir/usr/lib
 
 # Copy over some utilities
-for bin in db_dump db_load db_recover
+for bin in db_dump db_load db_recover gdb
 do
        cp `which $bin` citadel.AppDir/usr/bin/ || exit 16
 done
index e498fe4288fad8c21cdc01e2e737185e95723122..9c17f828df78596957e39a71eee2d99dc4590118 100755 (executable)
@@ -205,6 +205,21 @@ case ${1} in
                export PATH=$APPDIR/usr/bin
                exec ctdlvisor -m -h $CTDL_DIR
                ;;
+       mount)
+               echo This mode of operation mounts the AppImage but does not run anything.
+               echo -n Kill it when you are finished...
+               while true
+               do
+                       sleep 1
+               done
+               ;;
+       debug)
+               echo Connecting to the debugger
+               echo Try this: run -x9 -h $CTDL_DIR
+               export LD_LIBRARY_PATH=$APPDIR/usr/lib
+               export PATH=$APPDIR/usr/bin:$PATH
+               exec $APPDIR/usr/bin/gdb $APPDIR/usr/local/citadel/citserver
+               ;;
        *)
                echo Unexpected command: ${1} 
                usage