icurafu
The Hallucinogenic Elf
Hello,
This looks like an interesting project to port to the GP2X. Here is the description...
So I snoop around the souce and note that it is ported to QTE (Sharp Zaurus).
this is writen to a X11 window, but it would be easier for us to write to the frame buffer directly, or just using SDL.
Here is the build file...
This looks like an interesting project to port to the GP2X. Here is the description...
Klimt is an open-source 3D library, targeted for PDAs and mobile phones. Its API is very similiar to that of OpenGL and OpenGL|ES. We do not claim conformance with these APIs. Nevertheless, Klimt is able to run Coin3D, a large scene-graph base library that builds on top of OpenGL
Klimt is targeted for hardware independence and speed. The only requirement for an actual device to to be able to run Klimt is a 16-bits (RGB565) linear framebuffer. Klimt compiles without any further dependencies. No additional libraries are required for a minimum version..
So I snoop around the souce and note that it is ported to QTE (Sharp Zaurus).
this is writen to a X11 window, but it would be easier for us to write to the frame buffer directly, or just using SDL.
Here is the build file...
HTML:
<pre>
#############################################################################
# Makefile for building: libKlimt.so.0.5.1
# Generated by qmake (1.06c) (Qt 3.2.3) on: Tue Jan 13 22:14:18 2004
# Project: LinuxQTE.pro
# Template: lib
# Command: $(QMAKE) -o Makefile LinuxQTE.pro
#############################################################################
####### Compiler, tools and options
CC = arm-linux-gcc
CXX = arm-linux-g++ -DQT_QWS_SL5XXX -DQT_QWS_SHARP -DQT_QWS_EBX -DQT_QWS_CUSTOM
LEX = flex
YACC = yacc
CFLAGS = -pipe $(CFLAGS_EXTRA) -Wall -W $(if $(CFLAGS_RELEASE),$(CFLAGS_RELEASE), -O2) -fPIC -D_LINUX -DGCC_295X -DQT_NO_DEBUG
CXXFLAGS = -pipe $(CFLAGS_EXTRA) -DQWS -fno-exceptions -fno-rtti $(CXXFLAGS_EXTRA) -Wall -W $(if $(CFLAGS_RELEASE),$(CFLAGS_RELEASE), -O2) -fPIC -D_LINUX -DGCC_295X -DQT_NO_DEBUG
LEXFLAGS =
YACCFLAGS= -d
INCPATH = -I/usr/lib/qt3/mkspecs/qws/linux-sharp-g++ -I. -I../../src/Linux/zsurface -I../../src/Linux -I../../src -I../../include -I$(QPEDIR)/include -I../../src/Base -I../../RasterizerSW565 -I$(QTDIR)/include -I.ui/ -I.moc/
LINK = arm-linux-gcc
LFLAGS = $(LFLAGS_EXTRA) -Wl,-rpath,$(QTDIR)/lib -shared -Wl,-soname,libKlimt.so.0 -Wl,-rpath,/home/ryanr/devel/klimt/bin
LIBS = $(SUBLIBS) -L$(QTDIR)/lib $(LIBS_EXTRA) -lm -lqte
AR = ar cqs
RANLIB =
MOC = $(QTDIR)/bin/moc
UIC = $(QTDIR)/bin/uic
QMAKE = qmake
TAR = tar -cf
GZIP = gzip -9f
COPY = cp -f
COPY_FILE= $(COPY)
COPY_DIR = $(COPY) -R
DEL_FILE = rm -f
SYMLINK = ln -sf
DEL_DIR = rmdir
MOVE = mv -f
CHK_DIR_EXISTS= test -d
MKDIR = mkdir -p
####### Output directory
OBJECTS_DIR = .obj/
####### Files
HEADERS = ../../src/Linux/zsurface/ZSurface.h \
../../src/Linux/zsurface/ZFont.h
SOURCES = ../../src/klBlitter.cpp \
../../src/klEGLSurfaceBuffer.cpp \
../../src/Linux/klEGLSurfaceQTE.cpp \
../../src/Linux/zsurface/ZSurface.cpp \
../../src/Linux/zsurface/ZFont.cpp \
../../src/Linux/zsurface/BitBlit.S \
../../src/Linux/zsurface/BitBlitKeyed.S \
../../src/Linux/zsurface/BitBlitAlpha.S \
../../src/Linux/zsurface/Flip.S \
../../src/klGlu.cpp \
../../src/klGlut.cpp \
../../src/klImageConverter.cpp \
../../src/klMain.cpp \
../../src/Base/klChunkedMemory.cpp
OBJECTS = .obj/klBlitter.o \
.obj/klEGLSurfaceBuffer.o \
.obj/klEGLSurfaceQTE.o \
.obj/ZSurface.o \
.obj/ZFont.o \
.obj/BitBlit.o \
.obj/BitBlitKeyed.o \
.obj/BitBlitAlpha.o \
.obj/Flip.o \
.obj/klGlu.o \
.obj/klGlut.o \
.obj/klImageConverter.o \
.obj/klMain.o \
.obj/klChunkedMemory.o
FORMS =
UICDECLS =
UICIMPLS =
SRCMOC =
OBJMOC =
DIST = LinuxQTE.pro
QMAKE_TARGET = Klimt
DESTDIR = ../../../bin/
TARGET = libKlimt.so.0.5.1
TARGETA = ../../../bin/libKlimt.a
TARGETD = libKlimt.so.0.5.1
TARGET0 = libKlimt.so
TARGET1 = libKlimt.so.0
TARGET2 = libKlimt.so.0.5
first: all
####### Implicit rules
.SUFFIXES: .c .o .cpp .cc .cxx .C
.cpp.o:
$(CXX) -c $(CXXFLAGS) $(INCPATH) -o $@ $<
.cc.o:
$(CXX) -c $(CXXFLAGS) $(INCPATH) -o $@ $<
.cxx.o:
$(CXX) -c $(CXXFLAGS) $(INCPATH) -o $@ $<
.C.o:
$(CXX) -c $(CXXFLAGS) $(INCPATH) -o $@ $<
.c.o:
$(CC) -c $(CFLAGS) $(INCPATH) -o $@ $<
####### Build rules
all: Makefile ../../../bin/$(TARGET)
../../../bin/$(TARGET): $(UICDECLS) $(OBJECTS) $(OBJMOC) $(SUBLIBS) $(OBJCOMP)
test -d ../../../bin/ || mkdir -p ../../../bin/
-$(DEL_FILE) $(TARGET) $(TARGET0) $(TARGET1) $(TARGET2)
$(LINK) $(LFLAGS) -o $(TARGET) $(OBJECTS) $(OBJMOC) $(LIBS) $(OBJCOMP)
-ln -s $(TARGET) $(TARGET0)
-ln -s $(TARGET) $(TARGET1)
-ln -s $(TARGET) $(TARGET2)
-$(DEL_FILE) ../../../bin/$(TARGET)
-$(DEL_FILE) ../../../bin/$(TARGET0)
-$(DEL_FILE) ../../../bin/$(TARGET1)
-$(DEL_FILE) ../../../bin/$(TARGET2)
-$(MOVE) $(TARGET) $(TARGET0) $(TARGET1) $(TARGET2) ../../../bin/
staticlib: $(TARGETA)
$(TARGETA): $(UICDECLS) $(OBJECTS) $(OBJMOC) $(OBJCOMP)
-$(DEL_FILE) $(TARGETA)
$(AR) $(TARGETA) $(OBJECTS) $(OBJMOC)
mocables: $(SRCMOC)
uicables: $(UICDECLS) $(UICIMPLS)
$(MOC):
( cd $(QTDIR)/src/moc; $(MAKE) )
Makefile: LinuxQTE.pro /usr/lib/qt3/mkspecs/qws/linux-sharp-g++/qmake.conf
$(QMAKE) -o Makefile LinuxQTE.pro
qmake:
@$(QMAKE) -o Makefile LinuxQTE.pro
dist:
@mkdir -p .obj/Klimt && $(COPY_FILE) --parents $(SOURCES) $(HEADERS) $(FORMS) $(DIST) .obj/Klimt/ && ( cd `dirname .obj/Klimt` && $(TAR) Klimt.tar Klimt && $(GZIP) Klimt.tar ) && $(MOVE) `dirname .obj/Klimt`/Klimt.tar.gz . && $(DEL_FILE) -r .obj/Klimt
mocclean:
uiclean:
yaccclean:
lexclean:
clean:
-$(DEL_FILE) $(OBJECTS)
-$(DEL_FILE) *~ core *.core
####### Sub-libraries
distclean: clean
-$(DEL_FILE) ../../../bin/$(TARGET) $(TARGET)
-$(DEL_FILE) ../../../bin/$(TARGET0) ../../../bin/$(TARGET1) ../../../bin/$(TARGET2) $(TARGETA)
FORCE:
####### Compile
.obj/klBlitter.o: ../../src/klBlitter.cpp ../../src/klBlitter.h
$(CXX) -c $(CXXFLAGS) $(INCPATH) -o .obj/klBlitter.o ../../src/klBlitter.cpp
.obj/klEGLSurfaceBuffer.o: ../../src/klEGLSurfaceBuffer.cpp ../../include/klMain.h \
../../src/klEGLSurfaceBuffer.h \
../../src/klEGLSurface.h \
../../include/egl_definitions.h
$(CXX) -c $(CXXFLAGS) $(INCPATH) -o .obj/klEGLSurfaceBuffer.o ../../src/klEGLSurfaceBuffer.cpp
.obj/klEGLSurfaceQTE.o: ../../src/Linux/klEGLSurfaceQTE.cpp ../../src/Linux/klEGLSurfaceQTE.h
$(CXX) -c $(CXXFLAGS) $(INCPATH) -o .obj/klEGLSurfaceQTE.o ../../src/Linux/klEGLSurfaceQTE.cpp
.obj/ZSurface.o: ../../src/Linux/zsurface/ZSurface.cpp ../../src/Linux/zsurface/ZSurface.h \
../../src/Linux/zsurface/ZFont.h
$(CXX) -c $(CXXFLAGS) $(INCPATH) -o .obj/ZSurface.o ../../src/Linux/zsurface/ZSurface.cpp
.obj/ZFont.o: ../../src/Linux/zsurface/ZFont.cpp ../../src/Linux/zsurface/ZFont.h
$(CXX) -c $(CXXFLAGS) $(INCPATH) -o .obj/ZFont.o ../../src/Linux/zsurface/ZFont.cpp
.obj/BitBlit.o: ../../src/Linux/zsurface/BitBlit.S
$(CC) -c $(CFLAGS) $(INCPATH) -o .obj/BitBlit.o ../../src/Linux/zsurface/BitBlit.S
.obj/BitBlitKeyed.o: ../../src/Linux/zsurface/BitBlitKeyed.S
$(CC) -c $(CFLAGS) $(INCPATH) -o .obj/BitBlitKeyed.o ../../src/Linux/zsurface/BitBlitKeyed.S
.obj/BitBlitAlpha.o: ../../src/Linux/zsurface/BitBlitAlpha.S
$(CC) -c $(CFLAGS) $(INCPATH) -o .obj/BitBlitAlpha.o ../../src/Linux/zsurface/BitBlitAlpha.S
.obj/Flip.o: ../../src/Linux/zsurface/Flip.S
$(CC) -c $(CFLAGS) $(INCPATH) -o .obj/Flip.o ../../src/Linux/zsurface/Flip.S
.obj/klGlu.o: ../../src/klGlu.cpp ../../include/klMain.h \
../../include/gl/gl.h \
../../include/gl_definitions.h \
../../include/egl_definitions.h \
../../include/wgl_definitions.h
$(CXX) -c $(CXXFLAGS) $(INCPATH) -o .obj/klGlu.o ../../src/klGlu.cpp
.obj/klGlut.o: ../../src/klGlut.cpp ../../include/gl/gl.h \
../../include/klMain.h \
../../include/gl_definitions.h \
../../include/egl_definitions.h \
../../include/wgl_definitions.h
$(CXX) -c $(CXXFLAGS) $(INCPATH) -o .obj/klGlut.o ../../src/klGlut.cpp
.obj/klImageConverter.o: ../../src/klImageConverter.cpp ../../include/klMain.h \
../../include/gl/gl.h \
../../src/klImageConverter.h \
../../include/gl_definitions.h \
../../include/egl_definitions.h \
../../include/wgl_definitions.h
$(CXX) -c $(CXXFLAGS) $(INCPATH) -o .obj/klImageConverter.o ../../src/klImageConverter.cpp
.obj/klMain.o: ../../src/klMain.cpp ../../include/klMain.h \
../../include/gl_definitions.h \
../../src/Base/klMath.h \
../../src/Base/klStack.h \
../../src/Base/klArray.h \
../../src/klEGLSurfaceNative.h \
../../src/klEGLSurfaceBuffer.h \
../../src/klContext.h \
../../src/klWrapper.h \
../../include/egl_definitions.h \
../../src/klNative_egl.h \
../../src/Base/klMatrix.h \
../../src/Base/klVec4.h \
../../src/Base/klVec3.h \
../../src/Base/klVertex.h \
../../src/Base/klBase.h \
../../src/klEGLSurface.h \
../../src/klImageConverter.h \
../../src/klDisplayList.h \
../../src/klDisplayList_Record.h \
../../src/klDisplayList_Commands.h \
../../src/Base/klChunkedMemory.h \
../../src/Base/klList.h \
../../src/Base/klPtrList.h \
../../src/klEGLDisplay.h
$(CXX) -c $(CXXFLAGS) $(INCPATH) -o .obj/klMain.o ../../src/klMain.cpp
.obj/klChunkedMemory.o: ../../src/Base/klChunkedMemory.cpp ../../src/Base/klChunkedMemory.h \
../../src/Base/klList.h \
../../src/Base/klPtrList.h
$(CXX) -c $(CXXFLAGS) $(INCPATH) -o .obj/klChunkedMemory.o ../../src/Base/klChunkedMemory.cpp
####### Install
install: all
uninstall:
</pre>