From 83b716e3d948ce9447a73afdd73e7cf1089b2f81 Mon Sep 17 00:00:00 2001 From: Alexander von Gluck IV Date: Wed, 19 Dec 2012 23:24:27 -0600 Subject: [PATCH] swpipe: Make softpipe optional * If we're using llvmpipe, don't reference softpipe. Reduce bloat. --- src/add-ons/opengl/swpipe/GalliumContext.cpp | 8 ++++---- src/add-ons/opengl/swpipe/Jamfile | 2 +- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/src/add-ons/opengl/swpipe/GalliumContext.cpp b/src/add-ons/opengl/swpipe/GalliumContext.cpp index de7d458333..bf8ee85eb2 100644 --- a/src/add-ons/opengl/swpipe/GalliumContext.cpp +++ b/src/add-ons/opengl/swpipe/GalliumContext.cpp @@ -26,9 +26,10 @@ extern "C" { #include "state_tracker/st_gl_api.h" #include "state_tracker/st_manager.h" #include "state_tracker/sw_winsys.h" -#include "softpipe/sp_public.h" #ifdef HAVE_LLVM #include "llvmpipe/lp_public.h" +#else +#include "softpipe/sp_public.h" #endif } @@ -212,11 +213,10 @@ GalliumContext::CreateScreen() #ifdef HAVE_LLVM fScreen = llvmpipe_create_screen(winsys); + #else + fScreen = softpipe_create_screen(winsys); #endif - if (fScreen == NULL) - fScreen = softpipe_create_screen(winsys); - if (fScreen == NULL) { ERROR("%s: Couldn't create screen!\n", __FUNCTION__); FREE(winsys); diff --git a/src/add-ons/opengl/swpipe/Jamfile b/src/add-ons/opengl/swpipe/Jamfile index e57905e57c..4b9c588a24 100644 --- a/src/add-ons/opengl/swpipe/Jamfile +++ b/src/add-ons/opengl/swpipe/Jamfile @@ -24,7 +24,7 @@ if $(HAIKU_LLVM_DIR) { SubDirSysHdrs /boot/common/include ; HAIKU_LLVM_DIR = /boot/common/lib ; - HAIKU_SWPIPE_DRIVER += + HAIKU_SWPIPE_DRIVER = $(HAIKU_MESA_DIR)/lib.haiku/libllvmpipe.a ; llvmLibraries =