OpenGL Kit: Use GLU-9.0 for gcc2 and gcc4

* As of Mesa3D 9.0+, GLU is a seperate project
 * Our in-tree GLUT builds with GLU-9.0  without
   modification.
 * We ignore the GLU libraries that Mesa-7.8.2 and
   Mesa-8.1-devel provide and use the glu-9.0 ones
 * This is kind of a limbo state, but works for now.
 * Eventually we will be on Mesa 9.0 (which requires
   the external GLU) and Mesa 7.8.2 (which works with
   the newer external GLU) and will rip GLU out of the
   7.8.2 OptionalBuildPackage.
 * I don't *think* we are using the Mesa GLU headers...
   we will know for sure when I pull'em out of the
   OptionalBuildPackages :D
This commit is contained in:
Alexander von Gluck IV
2012-11-13 10:52:06 -06:00
parent 344b3218d4
commit fb7f48a9eb
3 changed files with 34 additions and 1 deletions
+26 -1
View File
@@ -180,6 +180,29 @@ if $(HAIKU_BUILD_FEATURE_CLUCENE) {
}
# GLU (GL Utilities)
if $(TARGET_ARCH) = x86 {
if $(HAIKU_GCC_VERSION[1]) >= 4 {
HAIKU_GLU_FILE = glu-9.0-x86-gcc4-2012-11-13.zip ;
} else {
HAIKU_GLU_FILE = glu-9.0-x86-gcc2-2012-11-13.zip ;
}
local zipFile = [ DownloadFile $(HAIKU_GLU_FILE)
: $(baseURL)/lib/$(HAIKU_GLU_FILE) ] ;
HAIKU_GLU_DIR = [ FDirName $(HAIKU_OPTIONAL_BUILD_PACKAGES_DIR)
$(HAIKU_GLU_FILE:B) ] ;
HAIKU_GLU_HEADERS_DEPENDENCY = [ ExtractArchive $(HAIKU_GLU_DIR)
: develop/headers/os/opengl/GL : $(zipFile) : extracted-glu-headers ] ;
HAIKU_GLU_LIBS = [ ExtractArchive $(HAIKU_GLU_DIR)
: system/lib/libGLU.a : $(zipFile) : extracted-glu ] ;
HAIKU_GLU_HEADERS = [ FDirName $(HAIKU_GLU_DIR) develop headers os opengl ] ;
} else {
Echo "GLU not yet available on $(TARGET_ARCH)" ;
}
# Mesa
if $(TARGET_ARCH) = x86 {
local glslObject ;
@@ -205,7 +228,6 @@ if $(TARGET_ARCH) = x86 {
HAIKU_MESA_LIBS = [ ExtractArchive $(HAIKU_MESA_DIR)
:
lib.haiku/libglu.a
$(galliumObjects)
lib.haiku/libglapi.a
$(glslObject)
@@ -215,6 +237,9 @@ if $(TARGET_ARCH) = x86 {
HAIKU_MESA_HEADERS = [ FDirName $(HAIKU_MESA_DIR) include ] ;
Depends $(HAIKU_MESA_HEADERS_DEPENDENCY) : $(HAIKU_GLU_HEADERS_DEPENDENCY) ;
Depends $(HAIKU_MESA_LIBS) : $(HAIKU_GLU_LIBS) ;
} else {
Echo "Mesa 3D rendering support not available on $(TARGET_ARCH)" ;
}
+5
View File
@@ -19,7 +19,9 @@ if $(TARGET_PLATFORM) != haiku {
}
SubDirSysHdrs $(HAIKU_GLU_HEADERS) ;
SubDirSysHdrs $(HAIKU_MESA_HEADERS) ;
Includes [ FGristFiles $(sources) ] : $(HAIKU_GLU_HEADERS_DEPENDENCY) ;
Includes [ FGristFiles $(sources) ] : $(HAIKU_MESA_HEADERS_DEPENDENCY) ;
UseHeaders [ FDirName $(HAIKU_MESA_DIR) include ] ;
@@ -41,6 +43,9 @@ if $(HAIKU_GCC_VERSION[1]) < 3 {
SharedLibrary libGL.so : $(sources) :
# GLU
$(HAIKU_GLU_LIBS)
# Glut
<opengl>glut.o
+3
View File
@@ -55,6 +55,9 @@ if $(HAIKU_GCC_VERSION[1]) < 3 {
}
# Ensure GLU dependency is met
Includes [ FGristFiles $(sourcesCc) $(sourcesCpp) ]
: $(HAIKU_GLU_HEADERS_DEPENDENCY) ;
# Ensure Mesa dependency is met
Includes [ FGristFiles $(sourcesCc) $(sourcesCpp) ]
: $(HAIKU_MESA_HEADERS_DEPENDENCY) ;