2006-11-25 11:49:17 -07:00
|
|
|
# Configuration for BeOS
|
|
|
|
# Written by Philippe Houdoin
|
|
|
|
|
|
|
|
include $(TOP)/configs/default
|
|
|
|
|
|
|
|
CONFIG_NAME = beos
|
|
|
|
|
|
|
|
|
|
|
|
DEFINES = \
|
|
|
|
-DBEOS_THREADS
|
|
|
|
|
|
|
|
MACHINE=$(shell uname -m)
|
|
|
|
ifeq ($(MACHINE), BePC)
|
|
|
|
CPU = x86
|
|
|
|
else
|
|
|
|
CPU = ppc
|
|
|
|
endif
|
|
|
|
|
|
|
|
ifeq ($(CPU), x86)
|
|
|
|
# BeOS x86 settings
|
|
|
|
|
|
|
|
DEFINES += \
|
|
|
|
-DGNU_ASSEMBLER \
|
|
|
|
-DUSE_X86_ASM \
|
|
|
|
-DUSE_MMX_ASM \
|
|
|
|
-DUSE_3DNOW_ASM \
|
|
|
|
-DUSE_SSE_ASM
|
|
|
|
|
2010-05-22 14:05:42 -06:00
|
|
|
MESA_ASM_SOURCES = $(X86_SOURCES)
|
|
|
|
GLAPI_ASM_SOURCES = $(X86_API)
|
2006-11-25 11:49:17 -07:00
|
|
|
|
|
|
|
CC = gcc
|
|
|
|
CXX = g++
|
|
|
|
LD = gcc
|
|
|
|
|
|
|
|
CFLAGS = \
|
|
|
|
-Wall -Wno-multichar -Wno-ctor-dtor-privacy \
|
|
|
|
$(DEFINES)
|
|
|
|
|
|
|
|
CXXFLAGS = $(CFLAGS)
|
|
|
|
|
2008-02-12 14:09:25 -07:00
|
|
|
# Work around aliasing bugs - developers should comment this out
|
|
|
|
CFLAGS += -fno-strict-aliasing
|
|
|
|
CXXFLAGS += -fno-strict-aliasing
|
|
|
|
|
2006-11-25 11:49:17 -07:00
|
|
|
LDFLAGS += -Xlinker
|
|
|
|
|
|
|
|
ifdef DEBUG
|
|
|
|
CFLAGS += -g -O0
|
|
|
|
LDFLAGS += -g
|
|
|
|
DEFINES += -DDEBUG
|
|
|
|
else
|
|
|
|
CFLAGS += -O3
|
|
|
|
endif
|
|
|
|
|
|
|
|
GLUT_CFLAGS = -fexceptions
|
|
|
|
|
|
|
|
else
|
|
|
|
# BeOS PPC settings
|
|
|
|
|
|
|
|
CC = mwcc
|
|
|
|
CXX = $(CC)
|
|
|
|
LD = mwldppc
|
|
|
|
|
|
|
|
CFLAGS = \
|
|
|
|
-w on -requireprotos \
|
|
|
|
$(DEFINES)
|
|
|
|
|
|
|
|
CXXFLAGS = $(CFLAGS)
|
|
|
|
|
|
|
|
LDFLAGS += \
|
|
|
|
-export pragma \
|
|
|
|
-init _init_routine_ \
|
|
|
|
-term _term_routine_ \
|
|
|
|
-lroot \
|
|
|
|
/boot/develop/lib/ppc/glue-noinit.a \
|
|
|
|
/boot/develop/lib/ppc/init_term_dyn.o \
|
|
|
|
/boot/develop/lib/ppc/start_dyn.o
|
|
|
|
|
|
|
|
ifdef DEBUG
|
|
|
|
CFLAGS += -g -O0
|
|
|
|
CXXFLAGS += -g -O0
|
|
|
|
LDFLAGS += -g
|
|
|
|
else
|
|
|
|
CFLAGS += -O7
|
|
|
|
CXXFLAGS += -O7
|
|
|
|
endif
|
|
|
|
|
|
|
|
GLUT_CFLAGS = -fexceptions
|
|
|
|
endif
|
|
|
|
|
|
|
|
# Directories
|
2011-10-23 07:37:25 -06:00
|
|
|
SRC_DIRS = gallium mesa glu glut/beos
|
2006-11-25 11:49:17 -07:00
|
|
|
GLU_DIRS = sgi
|
|
|
|
DRIVER_DIRS = beos
|
|
|
|
|
|
|
|
# Library/program dependencies
|
|
|
|
GL_LIB_DEPS =
|
|
|
|
OSMESA_LIB_DEPS = -L$(TOP)/$(LIB_DIR) -l$(GL_LIB)
|
|
|
|
GLU_LIB_DEPS =
|
|
|
|
GLUT_LIB_DEPS = -lgame -L$(TOP)/$(LIB_DIR) -l$(GL_LIB)
|
|
|
|
APP_LIB_DEPS = -lbe -L$(TOP)/$(LIB_DIR) -l$(GL_LIB) -l$(GLUT_LIB)
|
|
|
|
|