summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDon Kjer <don@lindenlab.com>2012-12-14 01:24:32 +0000
committerDon Kjer <don@lindenlab.com>2012-12-14 01:24:32 +0000
commitf9b235adf87819a727a6d656736111b776021ffb (patch)
tree79193c632e5c3f1e699ae4fa98dc6f77a966ae58
parentedcdce226a7ff599e43c89fe7e4d37350650ae96 (diff)
Attempt at fixing linux shader support on ubuntu 12.04
-rw-r--r--indra/llwindow/llwindowsdl.cpp11
-rwxr-xr-xindra/newview/linux_tools/wrapper.sh11
2 files changed, 13 insertions, 9 deletions
diff --git a/indra/llwindow/llwindowsdl.cpp b/indra/llwindow/llwindowsdl.cpp
index 39f8a36a6e..2f397c6372 100644
--- a/indra/llwindow/llwindowsdl.cpp
+++ b/indra/llwindow/llwindowsdl.cpp
@@ -682,12 +682,7 @@ BOOL LLWindowSDL::createContext(int x, int y, int width, int height, int bits, B
// fixme: actually, it's REALLY important for picking that we get at
// least 8 bits each of red,green,blue. Alpha we can be a bit more
// relaxed about if we have to.
-#if LL_SOLARIS && defined(__sparc)
-// again the __sparc required because Xsun support, 32bit are very pricey on SPARC
- if(colorBits < 24) //HACK: on SPARC allow 24-bit color
-#else
- if (colorBits < 32)
-#endif
+ if(colorBits < 24)
{
close();
setupFailure(
@@ -697,9 +692,9 @@ BOOL LLWindowSDL::createContext(int x, int y, int width, int height, int bits, B
"You may also need to adjust the X11 setting in SMF. To do so use\n"
" 'svccfg -s svc:/application/x11/x11-server setprop options/default_depth=24'\n"
#else
- "Second Life requires True Color (32-bit) to run in a window.\n"
+ "Second Life requires at least 24-bit color to run in a window.\n"
"Please go to Control Panels -> Display -> Settings and\n"
- "set the screen to 32-bit color.\n"
+ "set the screen to 24-bit color.\n"
#endif
"Alternately, if you choose to run fullscreen, Second Life\n"
"will automatically adjust the screen each time it runs.",
diff --git a/indra/newview/linux_tools/wrapper.sh b/indra/newview/linux_tools/wrapper.sh
index 20936c6460..0aba4bf0d6 100755
--- a/indra/newview/linux_tools/wrapper.sh
+++ b/indra/newview/linux_tools/wrapper.sh
@@ -45,6 +45,7 @@ if [ "`uname -m`" = "x86_64" ]; then
echo '64-bit Linux detected.'
fi
+
## Everything below this line is just for advanced troubleshooters.
##-------------------------------------------------------------------
@@ -60,7 +61,15 @@ fi
export SDL_VIDEO_X11_DGAMOUSE=0
## - Works around a problem with misconfigured 64-bit systems not finding GL
-export LIBGL_DRIVERS_PATH="${LIBGL_DRIVERS_PATH}":/usr/lib64/dri:/usr/lib32/dri:/usr/lib/dri
+I386_MULTIARCH="$(dpkg-architecture -ai386 -qDEB_HOST_MULTIARCH 2>/dev/null)"
+MULTIARCH_ERR=$?
+if [ $MULTIARCH_ERR -eq 0 ]; then
+ echo 'Multi-arch support detected.'
+ MULTIARCH_GL_DRIVERS="/usr/lib/${I386_MULTIARCH}/dri"
+ export LIBGL_DRIVERS_PATH="${LIBGL_DRIVERS_PATH}:${MULTIARCH_GL_DRIVERS}:/usr/lib64/dri:/usr/lib32/dri:/usr/lib/dri"
+else
+ export LIBGL_DRIVERS_PATH="${LIBGL_DRIVERS_PATH}:/usr/lib64/dri:/usr/lib32/dri:/usr/lib/dri"
+fi
## - The 'scim' GTK IM module widely crashes the viewer. Avoid it.
if [ "$GTK_IM_MODULE" = "scim" ]; then