remove global LV2 external GUI list, always call LV2 UI cleanup method when appropria...
[ardour2.git] / gtk2_ardour / ardour.sh.in
blobe1a0bd64ace57b7f02a57a96ef948919e01b7d70
1 #!/bin/sh
3 export GTK_PATH=%INSTALL_PREFIX%/%LIBDIR%/ardour2:$GTK_PATH
5 export LD_LIBRARY_PATH=%INSTALL_PREFIX%/%LIBDIR%/ardour2:$LD_LIBRARY_PATH
6 # DYLD_LIBRARY_PATH is for Darwin
7 export DYLD_LIBRARY_PATH=$LD_LIBRARY_PATH
9 ## Memlock check
11 MLOCK_LIMIT=$(ulimit -l)
12 if [ "$MLOCK_LIMIT" != "unlimited" ]; then
13 echo "WARNING: Your system has a limit for maximum amount of locked memory!"
14 echo " This might cause Ardour to run out of memory before your system runs"
15 echo " out of memory. You can view the memory limit with 'ulimit -l', and it"
16 echo " is normally controlled by /etc/security/limits.conf"
17 echo ""
22 ## Glib atomic test
24 GLIB=$(ldd %INSTALL_PREFIX%/%LIBDIR%/ardour2/ardour-%VERSION% 2> /dev/null | grep glib-2.0 | sed 's/.*=> \([^ ]*\) .*/\1/')
26 if [ "$GLIB" = "" ]; then
27 echo "WARNING: Could not check your glib-2.0 for mutex locking atomic operations."
28 echo ""
29 elif [ $(nm -D --radix=dec --defined-only -S $GLIB | grep -w g_atomic_int_add | cut -d ' ' -f 2) -gt 32 ]; then
30 echo "WARNING: Your system contains a suspect libglib-2.0. Your version might be built"
31 echo " to use mutex locking atomic operations. This is a fallback solution to"
32 echo " a more robust hardware supported atomicity. It might cause reduced "
33 echo " performance and/or deadlocks. Please contact your distribution support"
34 echo " about this issue."
35 echo " Unfortunately this check is not 100% accurate, so this might not be"
36 echo " the case with your system."
37 echo ""
40 exec %INSTALL_PREFIX%/%LIBDIR%/ardour2/ardour-%VERSION% "$@"