Here is a Makefile for Linux/GCC 4.3.0-users:
Code:
# MAKEFILE for Game::AI++
# 5 Files have to be modifed to work with linux and gcc 4.3.0
# tests/unit_Selector.h
# Add the <cstdlib> header
# alive/tree/Selector.h
# Add the <cstdlib> header
# alive/core/Core.h
# Uncomment line 25:
# // #include "../thirdparty/mmgr.h"
# alive/core/Generic.h
# Add the <cstdio> header
# At line 150 replace:
# typedef VTable< const Base, Func > VTable;
# const VTable* vtable_; // vtable pointer
# with
# typedef VTable< const Base, Func > _VTable;
# const _VTable* vtable_; // vtable pointer
# Replace VTable with _VTable in lines 265, 234
# alive/core/SignalSlot.h
# At line 67 and 125 replace:
# typename Delegates::iterator it =
# std::find(m_Delegates.begin(),m_Delegates.end(), d);
# if (it != m_Delegates.end())
# {
# m_Delegates.erase(it);
# }
# with (67)
# Delegates::iterator it;
# for (it = m_Delegates.begin(); it != m_Delegates.end(); ++it){
# m_Delegates.erase(it);
# return;
# }
# with (125)
# typename Delegates::iterator it;
# for (it = m_Delegates.begin(); it != m_Delegates.end(); ++it){
# m_Delegates.erase(it);
# return;
# }
# Result of tests/tests:
# OK (165)
CC=g++ -I. -Ialive
TESTOBJ=tests/doc_OrderedPlanning.o tests/doc_ConditionExecution.o tests/unit_Node.o tests/unit_Task.o tests/unit_Selector.o tests/unit_Filter.o tests/unit_Delegate.o tests/doc_FuturePlanning.o tests/unit_LookupTable.o tests/unit_ControlFlow.o tests/unit_Decorator.o tests/doc_SequenceExecution.o tests/doc_ActionExecution.o tests/doc_ConditionalAction.o tests/unit_Repeat.o tests/func_LookupTable.o tests/func_Stack.o tests/unit_Stack.o tests/unit_SignalSlot.o tests/unit_Memory.o tests/func_Node.o tests/unit_BlackboardCompare.o tests/func_Condition.o tests/func_Tree.o tests/MockNode.o tests/unit_Core.o tests/unit_Sequence.o tests/func_ControlBehavior.o tests/unit_Scheduler.o tests/doc_SelectorExecution.o tests/TestFramework.o tests/unit_Interpreter.o tests/unit_Resolve.o tests/unit_Registry.o tests/func_Visitor.o tests/func_Action.o tests/doc_GreedyPlanning.o tests/stress_Nodes.o tests/doc_ParallelExecution.o tests/unit_Parallel.o tests/unit_Transform.o tests/func_Persistence.o tests/func_PrettyPrinter.o
ALIVEOBJ=alive/Condition.o alive/Brain.o alive/framework/Registry.o alive/framework/Task.o alive/framework/Scheduler.o alive/engine/Interpreter.o alive/engine/Node.o alive/engine/Transform.o alive/thirdparty/mmgr.o alive/tree/Decorator.o alive/tree/CompositeTools.o alive/tree/Filter.o alive/tree/Sequence.o alive/tree/Selector.o alive/tree/ControlFlow.o alive/tree/Parallel.o alive/tree/Repeat.o alive/tree/Resolve.o alive/core/Core.o alive/extensions/ControlBehavior.o alive/extensions/LookupTable.o alive/extensions/Stack.o
all: alive test
alive: libalive.so
alive.a: $(ALIVEOBJ)
ar q $@ $(ALIVEOBJ)
libalive.so: $(ALIVEOBJ)
$(CC) -shared -o $@ $(ALIVEOBJ)
alive/%.o: alive/%.cpp
$(CC) -c -o $@ $?
test: tests/tests
tests/tests: $(TESTOBJ)
$(CC) -L. -ldl -lcppunit -lalive -o tests/tests $(TESTOBJ)
tests/%.o: tests/%.cpp
$(CC) -Itest -c -o $@ $?
David