Skip to content

Instantly share code, notes, and snippets.

@timokau
Created October 30, 2019 08:55
Show Gist options
  • Save timokau/a50d1033bce78f56804406bb8585b607 to your computer and use it in GitHub Desktop.
Save timokau/a50d1033bce78f56804406bb8585b607 to your computer and use it in GitHub Desktop.
export HOME=$(mktemp -d)
for i in `env | sed 's/=.*//' | grep XDG`; do unset $i; done
cd "$HOME"
mkdir -p "$HOME/Pictures"
mkdir -p "$HOME/build/share"
export XDG_DATA_DIRS="$HOME/build/share"
export PKG_CONFIG_PATH="/home/timo/tmp/opencv-install/lib64/pkgconfig:$PKG_CONFIG_PATH"
export LD_LIBRARY_PATH="/home/timo/tmp/opencv-install/lib64:$LD_LIBRARY_PATH"
export PATH="/home/timo/tmp/opencv-install/bin:$PATH"
export DK_PLUGIN_PATH="$HOME/build/lib/plugins/digikam/"
ln -s /home/timo/tmp/deletable-pics "$HOME/Pictures/p"
nix-shell -A digikam "$ppwd" --command '
unpackPhase &&
cd digikam || cd source &&
cmake -DCMAKE_INSTALL_PREFIX=$HOME/build -DCMAKE_BUILD_TYPE=debug . ;
make -j4 &&
make install &&
echo -e "gdb -q -ex r core/app/digikam" > run-in-gdb.sh &&
chmod +x run-in-gdb.sh &&
wrapQtApp run-in-gdb.sh &&
./run-in-gdb.sh;
return
'
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment