diff --git a/SConstruct b/SConstruct
index 954422e0b3da7795d2bd35fa7da715a93172a403..e928970f6b84da541facf6d2801ca789b68d9e52 100644
--- a/SConstruct
+++ b/SConstruct
@@ -568,9 +568,10 @@ pluglist.append('source/blender/blenpluginapi/plugin.DEF')
 plugtargetlist.append(os.path.join(env['BF_INSTALLDIR'], VERSION, 'plugins', 'include', 'plugin.def'))
 
 plugininstall = []
-for targetdir,srcfile in zip(plugtargetlist, pluglist):
-    td, tf = os.path.split(targetdir)
-    plugininstall.append(env.Install(dir=td, source=srcfile))
+# plugins in blender 2.5 don't work at the moment.
+#for targetdir,srcfile in zip(plugtargetlist, pluglist):
+#    td, tf = os.path.split(targetdir)
+#    plugininstall.append(env.Install(dir=td, source=srcfile))
 
 textlist = []
 texttargetlist = []
diff --git a/build_files/scons/config/darwin-config.py b/build_files/scons/config/darwin-config.py
index 0c51476a6d0913ece91b7618198dcd722fdcbbb5..a3ee937f703f3b36ec87007dae09866b128f883d 100644
--- a/build_files/scons/config/darwin-config.py
+++ b/build_files/scons/config/darwin-config.py
@@ -14,7 +14,7 @@ USE_SDK=True
 ###################     Cocoa & architecture settings      ##################
 #############################################################################
 WITH_GHOST_COCOA=True
-MACOSX_ARCHITECTURE = 'i386' # valid archs: ppc, i386, ppc64, x86_64
+MACOSX_ARCHITECTURE = 'x86_64' # valid archs: ppc, i386, ppc64, x86_64
 
 
 cmd = 'uname -p'
diff --git a/doc/doxygen/doxygen.source b/doc/doxygen/doxygen.source
index 9cd86e23e591c52ef393df3fb876b0dc659adf06..ccdf3448f180c8c7f60eeb2004c42366dcd13f11 100644
--- a/doc/doxygen/doxygen.source
+++ b/doc/doxygen/doxygen.source
@@ -342,17 +342,5 @@
 
 /* ================================ */
 
-/** \defgroup kernel kernel */
-
-/** \defgroup genmess gen_messaging
- *  \ingroup kernel
- */
-
-/** \defgroup gensys gen_system
- *  \ingroup kernel
- */
-
-/* ================================ */
-
 /** \defgroup undoc Undocumented
  *  \brief Modules and libraries that are still undocumented, or lacking proper integration into the doxygen system, are marked in this group. */
diff --git a/intern/container/CMakeLists.txt b/intern/container/CMakeLists.txt
index 7f15854e538e41874f490e628940c3704945a214..7e83acf68cec4f2cbb3990ededdd82c40cebfb2e 100644
--- a/intern/container/CMakeLists.txt
+++ b/intern/container/CMakeLists.txt
@@ -26,11 +26,13 @@
 
 set(INC
 	.
+	../guardedalloc
 )
 
 set(SRC
 	intern/CTR_List.cpp
 
+	CTR_HashedPtr.h
 	CTR_List.h
 	CTR_Map.h
 	CTR_TaggedIndex.h
diff --git a/source/kernel/gen_system/GEN_HashedPtr.h b/intern/container/CTR_HashedPtr.h
similarity index 67%
rename from source/kernel/gen_system/GEN_HashedPtr.h
rename to intern/container/CTR_HashedPtr.h
index 86a7ceb9ae77937e359aadfbff469ddde3901571..0291535d7185c6928ab4533fa3fb5cd932a2a96a 100644
--- a/source/kernel/gen_system/GEN_HashedPtr.h
+++ b/intern/container/CTR_HashedPtr.h
@@ -28,24 +28,30 @@
  *
  */
 
-/** \file kernel/gen_system/GEN_HashedPtr.h
- *  \ingroup gensys
+/** \file container/CTR_HashedPtr.h
+ *  \ingroup ctr
  */
 
-#ifndef __GEN_HASHEDPTR
-#define __GEN_HASHEDPTR
+#ifndef CTR_HASHEDPTR_H
+#define CTR_HASHEDPTR_H
 
-unsigned int GEN_Hash(void * inDWord);
+#include <stdlib.h>
 
-class GEN_HashedPtr
+inline unsigned int CTR_Hash(void *inDWord)
+{
+	size_t key = (size_t)inDWord;
+	return (unsigned int)(key ^ (key>>4));
+}
+
+class CTR_HashedPtr
 {
 	void* m_valptr;
 public:
-	GEN_HashedPtr(void* val) : m_valptr(val) {};
-	unsigned int hash() const { return GEN_Hash(m_valptr);};
-	inline friend bool operator ==(const GEN_HashedPtr & rhs, const GEN_HashedPtr & lhs) { return rhs.m_valptr == lhs.m_valptr;};
+	CTR_HashedPtr(void* val) : m_valptr(val) {};
+	unsigned int hash() const { return CTR_Hash(m_valptr);};
+	inline friend bool operator ==(const CTR_HashedPtr & rhs, const CTR_HashedPtr & lhs) { return rhs.m_valptr == lhs.m_valptr;};
 	void *getValue() const { return m_valptr; }
 };
 
-#endif //__GEN_HASHEDPTR
+#endif //CTR_HASHEDPTR_H
 
diff --git a/intern/container/CTR_Map.h b/intern/container/CTR_Map.h
index cbd67fdeaca5bd30cbd1970a996209ff34fc4336..1991ec19e3a6e37b824d0cdb1235c510bc828031 100644
--- a/intern/container/CTR_Map.h
+++ b/intern/container/CTR_Map.h
@@ -55,6 +55,19 @@ public:
             m_buckets[i] = 0;
         }
     }
+
+	CTR_Map(const CTR_Map& map)
+	{
+		m_num_buckets = map.m_num_buckets;
+		m_buckets = new Entry *[m_num_buckets];
+
+		for (int i = 0; i < m_num_buckets; ++i) {
+			m_buckets[i] = 0;
+
+			for(Entry *entry = map.m_buckets[i]; entry; entry=entry->m_next)
+				insert(entry->m_key, entry->m_value);
+		}
+	}
     
     int size() { 
         int count=0;
@@ -87,6 +100,24 @@ public:
         }
         return 0;
     }
+
+    Key* getKey(int index) {
+        int count=0;
+        for (int i=0;i<m_num_buckets;i++)
+        {
+            Entry* bucket = m_buckets[i];
+            while(bucket)
+            {
+                if (count==index)
+                {
+                    return &bucket->m_key;
+                }
+                bucket = bucket->m_next;
+                count++;
+            }
+        }
+        return 0;
+    }
     
     void clear() {
         for (int i = 0; i < m_num_buckets; ++i) {
diff --git a/intern/container/SConscript b/intern/container/SConscript
index 2d93e90b555df5aee467d741fd90366b16e0d940..8edf86d7d4acc1e8f68c8bea3cd09c7165168763 100644
--- a/intern/container/SConscript
+++ b/intern/container/SConscript
@@ -2,6 +2,6 @@
 Import ('env')
 
 sources = env.Glob('intern/*.cpp')
-incs = '.'
+incs = '. #intern/guardedalloc'
 
 env.BlenderLib ('bf_intern_ctr', sources, Split(incs) , [], libtype='intern', priority = 10 )
diff --git a/source/CMakeLists.txt b/source/CMakeLists.txt
index 1929f19f38f829a61a28b90c94ef3839b1999011..5d0354ccd721e031dd03388f416f05912d943e6f 100644
--- a/source/CMakeLists.txt
+++ b/source/CMakeLists.txt
@@ -27,7 +27,6 @@
 add_subdirectory(blender)
 
 if(WITH_GAMEENGINE)
-	add_subdirectory(kernel)
 	add_subdirectory(gameengine)
 endif()
 	
diff --git a/source/SConscript b/source/SConscript
index 8d08d9cca0838a1beb04eb2cb8a360440da3fd6e..0002cb4cf0bef0d363c5c32bea553b534ed42c29 100644
--- a/source/SConscript
+++ b/source/SConscript
@@ -4,7 +4,7 @@ Import ('env')
 SConscript(['blender/SConscript', 'creator/SConscript'])
 
 if env['WITH_BF_GAMEENGINE']:
-    SConscript (['kernel/SConscript', 'gameengine/SConscript'])
+    SConscript (['gameengine/SConscript'])
 
 if env['WITH_BF_PLAYER']:
     SConscript (['blenderplayer/bad_level_call_stubs/SConscript'])
diff --git a/source/blender/editors/space_view3d/CMakeLists.txt b/source/blender/editors/space_view3d/CMakeLists.txt
index 9744887ed9f077a0713ed145c166fccf70b49f3d..f923c578769367b16b42a2473b5c01be2f9dffab 100644
--- a/source/blender/editors/space_view3d/CMakeLists.txt
+++ b/source/blender/editors/space_view3d/CMakeLists.txt
@@ -58,7 +58,7 @@ set(SRC
 )
 
 if(WITH_GAMEENGINE)
-	list(APPEND INC ../../../kernel/gen_system)
+	list(APPEND INC ../../../../source/gameengine/BlenderRoutines)
 	add_definitions(-DWITH_GAMEENGINE)
 endif()
 
diff --git a/source/blender/editors/space_view3d/SConscript b/source/blender/editors/space_view3d/SConscript
index 3df59d485d5cd84ffcb4516341ca551e36159cb9..84ba8d1fe861b195d5f8d8c10a76a788e2f9dc9f 100644
--- a/source/blender/editors/space_view3d/SConscript
+++ b/source/blender/editors/space_view3d/SConscript
@@ -9,7 +9,7 @@ incs += ' ../../windowmanager #/intern/guardedalloc #/extern/glew/include'
 incs += ' ../../render/extern/include ../../blenloader'
 incs += ' ../../gpu ../../makesrna ../../blenfont'
 incs += ' #/intern/smoke/extern'
-incs += ' #source/kernel/gen_system'
+incs += ' #source/gameengine/BlenderRoutines'
 
 if env['WITH_BF_GAMEENGINE']:
     defs.append('WITH_GAMEENGINE')
diff --git a/source/blender/editors/space_view3d/view3d_view.c b/source/blender/editors/space_view3d/view3d_view.c
index 8a975eec40f1b088d353102c703c665f2ef0f60a..b46c7236170c9ec2f15ef7be18ea1f165f102e91 100644
--- a/source/blender/editors/space_view3d/view3d_view.c
+++ b/source/blender/editors/space_view3d/view3d_view.c
@@ -65,7 +65,7 @@
 #include "ED_armature.h"
 
 #ifdef WITH_GAMEENGINE
-#include "SYS_System.h"
+#include "BL_System.h"
 #endif
 
 #include "view3d_intern.h"	// own include
@@ -1764,9 +1764,6 @@ static void game_set_commmandline_options(GameData *gm)
 	}
 }
 
-/* maybe we need this defined somewhere else */
-extern void StartKetsjiShell(struct bContext *C, struct ARegion *ar, rcti *cam_frame, int always_use_expand_framing);
-
 #endif // WITH_GAMEENGINE
 
 static int game_engine_poll(bContext *C)
diff --git a/source/blender/readblenfile/CMakeLists.txt b/source/blender/readblenfile/CMakeLists.txt
index 8d3633b4918f31a10eb0da635186f314dcfa9d99..9b869d39697d119182cb928f36b774394124e461 100644
--- a/source/blender/readblenfile/CMakeLists.txt
+++ b/source/blender/readblenfile/CMakeLists.txt
@@ -31,7 +31,6 @@ set(INC
 	../blenkernel
 	../blenlib
 	../makesdna
-	../../kernel/gen_messaging
 )
 
 set(SRC
diff --git a/source/blender/readblenfile/SConscript b/source/blender/readblenfile/SConscript
index 6d8749df1e2cd78df8bb6f7aa1d18617c0efb14f..07f84eb52d5deeb21ae6aee6a42fb329c17f443b 100644
--- a/source/blender/readblenfile/SConscript
+++ b/source/blender/readblenfile/SConscript
@@ -3,6 +3,6 @@ Import ('env')
 
 sources = env.Glob('intern/*.c')
 
-incs = '.  ../blenloader ../blenloader/intern ../blenkernel ../blenlib ../makesdna ../../kernel/gen_messaging'
+incs = '.  ../blenloader ../blenloader/intern ../blenkernel ../blenlib ../makesdna'
 
 env.BlenderLib ( 'bf_readblenfile', sources, Split(incs), [], libtype=['core','player'], priority = [0,5] )
diff --git a/source/blender/readblenfile/stub/BLO_readblenfileSTUB.c b/source/blender/readblenfile/stub/BLO_readblenfileSTUB.c
index 4900f0c3338da6e384340fee03c9c0c6bb8d72b2..0f3541b510dc0111466546a8b7db31ef751944e7 100644
--- a/source/blender/readblenfile/stub/BLO_readblenfileSTUB.c
+++ b/source/blender/readblenfile/stub/BLO_readblenfileSTUB.c
@@ -34,7 +34,6 @@
 
 
 #include <stdio.h>
-#include "GEN_messaging.h"
 
 int BLO_readblenfilememory( char *fromBuffer, int fromBufferSize);
 int BLO_readblenfilename( char *fileName);
@@ -47,7 +46,7 @@ BLO_readblenfilememory(
 	char *fromBuffer, int fromBufferSize)
 {
 #if defined(DEBUG)
-	fprintf(GEN_errorstream,
+	fprintf(stderr,
 			"Error BLO_readblenfilename is a stub\n");
 #endif
 	return(1);
@@ -58,7 +57,7 @@ BLO_readblenfilename(
 	char *fileName)
 {
 #if defined(DEBUG)
-	fprintf(GEN_errorstream,
+	fprintf(stderr,
 			"Error BLO_readblenfilename is a stub\n");
 #endif
 	return(1);
@@ -69,7 +68,7 @@ BLO_readblenfilehandle(
 	int fileHandle)
 {
 #if defined(DEBUG)
-	fprintf(GEN_errorstream,
+	fprintf(stderr,
 			"Error BLO_readblenfilehandle is a stub\n");
 #endif
 	return(1);
@@ -80,7 +79,7 @@ BLO_is_a_runtime(
 	char *file)
 {
 #if defined(DEBUG)
-	fprintf(GEN_errorstream,
+	fprintf(stderr,
 			"Error BLO_is_a_runtime is a stub\n");
 #endif
 	return 0;
@@ -91,7 +90,7 @@ BLO_read_runtime(
 	char *file) 
 {
 #if defined(DEBUG)
-	fprintf(GEN_errorstream,
+	fprintf(stderr,
 			"Error BLO_read_runtime is a stub\n");
 #endif
 	return 0;
diff --git a/source/blender/render/CMakeLists.txt b/source/blender/render/CMakeLists.txt
index f00e54c1796cbbf8c7a8c6be708af9d9b7fa369c..bcb427abd6cf25b4292181ddbc4c866b3fcd9c3e 100644
--- a/source/blender/render/CMakeLists.txt
+++ b/source/blender/render/CMakeLists.txt
@@ -36,7 +36,6 @@ set(INC
 	../makesrna
 	../blenkernel
 	../imbuf
-	../../kernel/gen_messaging
 	../../../intern/smoke/extern
 	../../../intern/mikktspace
 	../../../intern/guardedalloc
diff --git a/source/blender/windowmanager/CMakeLists.txt b/source/blender/windowmanager/CMakeLists.txt
index 251f6605f5e3eefce89388ef485b1e5fd42a96ee..6f03928e1fc562b0d3c8d51172e341cabf94ab84 100644
--- a/source/blender/windowmanager/CMakeLists.txt
+++ b/source/blender/windowmanager/CMakeLists.txt
@@ -37,12 +37,12 @@ set(INC
 	../blenloader
 	../editors/include
 	../render/extern/include
-	../../kernel/gen_system
 	../../../intern/guardedalloc
 	../../../intern/memutil
 	../../../intern/elbeem/extern
 	../../../intern/ghost
 	../../../intern/opennl/extern
+	../../../source/gameengine/BlenderRoutines
 	${ZLIB_INCLUDE_DIRS}
 	${OPENGL_INCLUDE_DIR}
 	${GLEW_INCLUDE_PATH}
diff --git a/source/blender/windowmanager/SConscript b/source/blender/windowmanager/SConscript
index 3826671736999c85df23e6fc48d20007247f68a8..f52ac8ba3cb87f852dfdeed88583c096ab9db84f 100644
--- a/source/blender/windowmanager/SConscript
+++ b/source/blender/windowmanager/SConscript
@@ -8,11 +8,12 @@ sources = env.Glob('intern/*.c')
 
 incs = '. ../editors/include ../python ../makesdna ../blenlib ../blenkernel'
 incs += ' ../nodes ../imbuf ../blenloader ../render/extern/include'
-incs += ' ../radiosity/extern/include ../../kernel/gen_system'
+incs += ' ../radiosity/extern/include'
 incs += ' ../makesrna ../gpu ../blenfont'
 
 incs += ' #/intern/guardedalloc #/intern/memutil #/intern/ghost'
 incs += ' #/intern/elbeem #/extern/glew/include'
+incs += ' #source/gameengine/BlenderRoutines'
 
 incs += ' ' + env['BF_ZLIB_INC']
 
diff --git a/source/blender/windowmanager/intern/wm_init_exit.c b/source/blender/windowmanager/intern/wm_init_exit.c
index 620d3314d431dee0ee3dbddebbd6a33286bc8efa..b09e264bd1d14d0012848756352c1b0925c4f69b 100644
--- a/source/blender/windowmanager/intern/wm_init_exit.c
+++ b/source/blender/windowmanager/intern/wm_init_exit.c
@@ -72,7 +72,7 @@
 #endif
 
 #ifdef WITH_GAMEENGINE
-#include "SYS_System.h"
+#include "BL_System.h"
 #endif
 #include "GHOST_Path-api.h"
 #include "GHOST_C-api.h"
diff --git a/source/blenderplayer/CMakeLists.txt b/source/blenderplayer/CMakeLists.txt
index 83dfd15f2ddbcc77d935eddd54dd86ae9db93195..b88c0fd04c1a2d7652ce1383021ea6f5b80e8a8b 100644
--- a/source/blenderplayer/CMakeLists.txt
+++ b/source/blenderplayer/CMakeLists.txt
@@ -110,7 +110,6 @@ endif()
 		bf_intern_smoke
 		bf_modifiers
 		bf_intern_moto 
-		bf_gen_system 
 		bf_nodes
 		bf_gpu
 		bf_imbuf
diff --git a/source/creator/CMakeLists.txt b/source/creator/CMakeLists.txt
index a039dca208e2a3c59d247eca93c6cc5994dc97ac..b39393bc8b7d39081279f5315219a96aa70c81f3 100644
--- a/source/creator/CMakeLists.txt
+++ b/source/creator/CMakeLists.txt
@@ -82,10 +82,7 @@ if(WITH_PYTHON)
 endif()
 
 if(WITH_GAMEENGINE)
-	blender_include_dirs(
-		../kernel/gen_messaging
-		../kernel/gen_system
-	)
+	blender_include_dirs(../gameengine/BlenderRoutines)
 
 	add_definitions(-DWITH_GAMEENGINE)
 endif()
@@ -778,7 +775,6 @@ endif()
 		bf_collada
 		bf_intern_bsp
 		bf_intern_bop
-		bf_gen_system
 		bf_intern_decimate
 		bf_intern_elbeem
 		bf_intern_ik
@@ -800,7 +796,6 @@ endif()
 		ge_logic_expressions
 		ge_scenegraph
 		ge_logic_network
-		bf_gen_system
 		bf_python # duplicate for BPY_driver_exec
 		ge_logic_ngnetwork
 		extern_bullet
diff --git a/source/creator/SConscript b/source/creator/SConscript
index 8577872c48ac6be256256f0eebee04f2a7f8002d..79e03c8dddc03f3ffcaf13c2ab62a2021a6f04c1 100644
--- a/source/creator/SConscript
+++ b/source/creator/SConscript
@@ -7,8 +7,8 @@ sources = 'creator.c'
 incs = '#/intern/guardedalloc ../blender/blenlib ../blender/blenkernel'
 incs += ' ../blender/editors/include ../blender/blenloader ../blender/imbuf'
 incs += ' ../blender/renderconverter ../blender/render/extern/include ../blender/windowmanager'
-incs += ' ../blender/makesdna ../blender/makesrna ../kernel/gen_messaging'
-incs += ' ../kernel/gen_system #/extern/glew/include ../blender/gpu'
+incs += ' ../blender/makesdna ../blender/makesrna'
+incs += ' ../gameengine/BlenderRoutines #/extern/glew/include ../blender/gpu'
 incs += ' ' + env['BF_OPENGL_INC']
 
 defs = []
diff --git a/source/creator/creator.c b/source/creator/creator.c
index ab94131966f6ed667b2fc320cf0d2acfa2d63a20..2b146822194183394749d6b9a74b89dada18830c 100644
--- a/source/creator/creator.c
+++ b/source/creator/creator.c
@@ -108,8 +108,7 @@
 
 /* for passing information between creator and gameengine */
 #ifdef WITH_GAMEENGINE
-#include "GEN_messaging.h"
-#include "SYS_System.h"
+#include "BL_System.h"
 #else /* dummy */
 #define SYS_SystemHandle int
 #endif
@@ -1216,7 +1215,6 @@ int main(int argc, const char **argv)
 
 #ifdef WITH_GAMEENGINE
 	syshandle = SYS_GetSystem();
-	GEN_init_messaging_system();
 #else
 	syshandle= 0;
 #endif
diff --git a/source/gameengine/BlenderRoutines/BL_KetsjiEmbedStart.cpp b/source/gameengine/BlenderRoutines/BL_KetsjiEmbedStart.cpp
index b94d15d2fbf9bd8f3a000069aa1c62c1a84b4741..571cc9087b3b461c36dc56d80d51942738b3312a 100644
--- a/source/gameengine/BlenderRoutines/BL_KetsjiEmbedStart.cpp
+++ b/source/gameengine/BlenderRoutines/BL_KetsjiEmbedStart.cpp
@@ -64,7 +64,7 @@
 
 #include "NG_LoopBackNetworkDeviceInterface.h"
 
-#include "SYS_System.h"
+#include "BL_System.h"
 
 #include "GPU_extensions.h"
 #include "Value.h"
diff --git a/source/kernel/gen_system/SYS_System.cpp b/source/gameengine/BlenderRoutines/BL_System.cpp
similarity index 60%
rename from source/kernel/gen_system/SYS_System.cpp
rename to source/gameengine/BlenderRoutines/BL_System.cpp
index b2de797fc8d59cb8253fbe9a9daf0ba23f5155f8..30b8beef15689ac36f9f53272163749f84deeeba 100644
--- a/source/kernel/gen_system/SYS_System.cpp
+++ b/source/gameengine/BlenderRoutines/BL_System.cpp
@@ -25,55 +25,80 @@
  * Contributor(s): none yet.
  *
  * ***** END GPL LICENSE BLOCK *****
- * System specific information / access.
  * Interface to the commandline arguments
  */
 
-/** \file kernel/gen_system/SYS_System.cpp
- *  \ingroup gensys
+/** \file gameengine/BlenderRoutines/BL_System.cpp
+ *  \ingroup blroutines
  */
 
-#include "SYS_System.h"
-#include "SYS_SingletonSystem.h"
+#include "CTR_Map.h"
+#include "STR_HashedString.h"
+#include "BL_System.h"
+
+struct SingletonSystem {
+	CTR_Map<STR_HashedString,int> int_params;
+	CTR_Map<STR_HashedString,float> float_params;
+	CTR_Map<STR_HashedString,STR_String> string_params;
+};
+
+static SingletonSystem *_system_instance = NULL;
 
 SYS_SystemHandle SYS_GetSystem()
 {
-	return (SYS_SystemHandle) SYS_SingletonSystem::Instance();
+	if(!_system_instance)
+		_system_instance = new SingletonSystem();
+
+	return (SYS_SystemHandle)_system_instance;
 }
 
 void SYS_DeleteSystem(SYS_SystemHandle sys)
 {
-	if (sys) {
-		((SYS_SingletonSystem *) sys)->Destruct();
+	if(_system_instance) {
+		delete _system_instance;
+		_system_instance = NULL;
 	}
 }
 
 int SYS_GetCommandLineInt(SYS_SystemHandle sys, const char *paramname, int defaultvalue)
 {
-	return ((SYS_SingletonSystem *) sys)->SYS_GetCommandLineInt(paramname, defaultvalue);
+	int *result = ((SingletonSystem *)sys)->int_params[paramname];
+	if(result)
+		return *result;
+
+	return defaultvalue;
 }
 
 float SYS_GetCommandLineFloat(SYS_SystemHandle sys, const char *paramname, float defaultvalue)
 {
-	return ((SYS_SingletonSystem *) sys)->SYS_GetCommandLineFloat(paramname, defaultvalue);
+	float *result = ((SingletonSystem *)sys)->float_params[paramname];
+	if(result)
+		return *result;
+
+	return defaultvalue;
 }
 
 const char *SYS_GetCommandLineString(SYS_SystemHandle sys, const char *paramname, const char *defaultvalue)
 {
-	return ((SYS_SingletonSystem *) sys)->SYS_GetCommandLineString(paramname, defaultvalue);
+	STR_String *result = ((SingletonSystem *)sys)->string_params[paramname];
+	if(result)
+		return *result;
+
+	return defaultvalue;
 }
 
 void SYS_WriteCommandLineInt(SYS_SystemHandle sys, const char *paramname, int value)
 {
-	((SYS_SingletonSystem *) sys)->SYS_WriteCommandLineInt(paramname, value);
+	((SingletonSystem *)sys)->int_params.insert(paramname, value);
 }
 
 void SYS_WriteCommandLineFloat(SYS_SystemHandle sys, const char *paramname, float value)
 {
-	((SYS_SingletonSystem *) sys)->SYS_WriteCommandLineFloat(paramname, value);
+	((SingletonSystem *)sys)->float_params.insert(paramname, value);
 }
 
 void SYS_WriteCommandLineString(SYS_SystemHandle sys, const char *paramname, const char *value)
 {
-	((SYS_SingletonSystem *) sys)->SYS_WriteCommandLineString(paramname, value);
+	((SingletonSystem *)sys)->string_params.insert(paramname, value);
 }
+
diff --git a/source/kernel/gen_system/SYS_System.h b/source/gameengine/BlenderRoutines/BL_System.h
similarity index 75%
rename from source/kernel/gen_system/SYS_System.h
rename to source/gameengine/BlenderRoutines/BL_System.h
index 34fed4a81a29d214bc54652bf1ca8aacee1a6bb9..d743ef5532af7f7cb3df68c28f2d3ed976968f77 100644
--- a/source/kernel/gen_system/SYS_System.h
+++ b/source/gameengine/BlenderRoutines/BL_System.h
@@ -29,31 +29,21 @@
  * Interface to the commandline arguments
  */
 
-/** \file kernel/gen_system/SYS_System.h
- *  \ingroup gensys
+/** \file gameengine/BlenderRoutines/BL_System.h
+ *  \ingroup blroutines
  */
 
-
-#ifndef __SYSTEM_INCLUDE
-#define __SYSTEM_INCLUDE
-
-#define SYS_DECLARE_HANDLE(name) typedef struct name##__ { int unused; } *name
-
-SYS_DECLARE_HANDLE(SYS_SystemHandle);
-
-/**
- System specific information / access.
- For now, only used for commandline parameters.
- One of the available implementations must be linked to the application
- that uses this system routines. 
- Please note that this protocol/interface is just for testing, 
- it needs discussion in the development group for a more final version.
-*/
+#ifndef BL_SYSTEM_H
+#define BL_SYSTEM_H
 
 #ifdef __cplusplus
 extern "C" {
 #endif
 
+/* Game Engine command line parameters */
+
+typedef void* SYS_SystemHandle;
+
 extern SYS_SystemHandle SYS_GetSystem(void);
 extern void SYS_DeleteSystem(SYS_SystemHandle sys);
 
@@ -65,9 +55,18 @@ extern void SYS_WriteCommandLineInt(SYS_SystemHandle sys, const char *paramname,
 extern void SYS_WriteCommandLineFloat(SYS_SystemHandle sys, const char *paramname, float value);
 extern void SYS_WriteCommandLineString(SYS_SystemHandle sys, const char *paramname, const char *value);
 
+/* Start game engine */
+
+struct bContext;
+struct ARegion;
+struct rcti;
+
+extern void StartKetsjiShell(struct bContext *C, struct ARegion *ar,
+	struct rcti *cam_frame, int always_use_expand_framing);
+
 #ifdef __cplusplus
 }
 #endif
 
-#endif //__SYSTEM_INCLUDE
+#endif /* BL_SYSTEM_H */
 
diff --git a/source/gameengine/BlenderRoutines/CMakeLists.txt b/source/gameengine/BlenderRoutines/CMakeLists.txt
index f510303431694847ae4828e2c524f4f4056f1087..6a17017f26191a1fe0bea485f81466a6b3c49668 100644
--- a/source/gameengine/BlenderRoutines/CMakeLists.txt
+++ b/source/gameengine/BlenderRoutines/CMakeLists.txt
@@ -1,8 +1,8 @@
 
 set(INC
 	.
-	../../../source/kernel/gen_system
 	../../../intern/string
+	../../../intern/container
 	../../../intern/guardedalloc
 	../../../intern/audaspace/intern
 	../../../source/gameengine/Rasterizer/RAS_OpenGLRasterizer 
@@ -34,6 +34,7 @@ set(INC
 
 set(SRC
 	BL_KetsjiEmbedStart.cpp
+	BL_System.cpp
 	KX_BlenderCanvas.cpp
 	KX_BlenderGL.cpp
 	KX_BlenderInputDevice.cpp
@@ -42,6 +43,7 @@ set(SRC
 	KX_BlenderRenderTools.cpp
 	KX_BlenderSystem.cpp
 
+	BL_System.h
 	KX_BlenderCanvas.h
 	KX_BlenderGL.h
 	KX_BlenderInputDevice.h
diff --git a/source/gameengine/BlenderRoutines/SConscript b/source/gameengine/BlenderRoutines/SConscript
index ff70ad3bf7bdfd7896ea41b6f2bc89489b0ef408..8f59ec0bf04883d638efc1a84f4e2b16c5bfce30 100644
--- a/source/gameengine/BlenderRoutines/SConscript
+++ b/source/gameengine/BlenderRoutines/SConscript
@@ -4,10 +4,10 @@ Import ('env')
 sources = env.Glob('*.cpp')
 defs = [ 'GLEW_STATIC' ]
 
-incs = '. #source/kernel/gen_system #intern/string #intern/guardedalloc'
+incs = '. #intern/string #intern/guardedalloc'
 incs += ' #source/gameengine/Rasterizer/RAS_OpenGLRasterizer'
 incs += ' #source/gameengine/Converter #source/blender/imbuf'
-incs += ' #intern/ghost/include'
+incs += ' #intern/ghost/include #intern/container'
 incs += ' #intern/audaspace/intern'
 incs += ' #intern/moto/include #source/gameengine/Ketsji #source/blender/blenlib'
 incs += ' #source/blender/blenkernel #source/blender'
diff --git a/source/gameengine/Converter/BL_ActionActuator.h b/source/gameengine/Converter/BL_ActionActuator.h
index c6e661f15492b13bf8b60616a7e5b620ad385c7d..ff4ca785a96143bc3f73938fcfb00fecb8f4deaf 100644
--- a/source/gameengine/Converter/BL_ActionActuator.h
+++ b/source/gameengine/Converter/BL_ActionActuator.h
@@ -34,7 +34,7 @@
 #ifndef BL_ACTIONACTUATOR
 #define BL_ACTIONACTUATOR
 
-#include "GEN_HashedPtr.h"
+#include "CTR_HashedPtr.h"
 #include "SCA_IActuator.h"
 #include "DNA_actuator_types.h"
 #include "MT_Point3.h"
diff --git a/source/gameengine/Converter/BL_ArmatureActuator.cpp b/source/gameengine/Converter/BL_ArmatureActuator.cpp
index efd1a73a44880471691923e5e2a3c1fa810be64b..a56fab31a262c78f3e135a30b37bf06600b4b925 100644
--- a/source/gameengine/Converter/BL_ArmatureActuator.cpp
+++ b/source/gameengine/Converter/BL_ArmatureActuator.cpp
@@ -115,7 +115,7 @@ bool BL_ArmatureActuator::UnlinkObject(SCA_IObject* clientobj)
 	return res;
 }
 
-void BL_ArmatureActuator::Relink(GEN_Map<GEN_HashedPtr, void*> *obj_map)
+void BL_ArmatureActuator::Relink(CTR_Map<CTR_HashedPtr, void*> *obj_map)
 {
 	void **h_obj = (*obj_map)[m_gametarget];
 	if (h_obj) {
diff --git a/source/gameengine/Converter/BL_ArmatureActuator.h b/source/gameengine/Converter/BL_ArmatureActuator.h
index 4615fb067140f8770274ca36f73e1024e5731ad9..70aa526d4d30d89ddc32fb63d70660020a8e1b7d 100644
--- a/source/gameengine/Converter/BL_ArmatureActuator.h
+++ b/source/gameengine/Converter/BL_ArmatureActuator.h
@@ -67,7 +67,7 @@ public:
 	};
 	virtual void ProcessReplica();
 	virtual bool UnlinkObject(SCA_IObject* clientobj);
-	virtual void Relink(GEN_Map<GEN_HashedPtr, void*> *obj_map);
+	virtual void Relink(CTR_Map<CTR_HashedPtr, void*> *obj_map);
 	virtual bool Update(double curtime, bool frame);
 	virtual void ReParent(SCA_IObject* parent);
 	
diff --git a/source/gameengine/Converter/BL_ArmatureChannel.h b/source/gameengine/Converter/BL_ArmatureChannel.h
index 0c2c27a7fabbfca0d8b801d0b1c7a5ba5666f864..0a66d0038a266a3f7157f570079b164b7b98eb45 100644
--- a/source/gameengine/Converter/BL_ArmatureChannel.h
+++ b/source/gameengine/Converter/BL_ArmatureChannel.h
@@ -35,8 +35,8 @@
 #define __BL_ARMATURECHANNEL
 
 #include "DNA_action_types.h"
-#include "GEN_HashedPtr.h"
-#include "GEN_Map.h"
+#include "CTR_HashedPtr.h"
+#include "CTR_Map.h"
 #include "PyObjectPlus.h"
 
 class SCA_IObject;
diff --git a/source/gameengine/Converter/BL_ArmatureConstraint.cpp b/source/gameengine/Converter/BL_ArmatureConstraint.cpp
index c07fe6b3b41b4427cde033c4c1a37e789a4d7e03..3f1a111517cb8753bcf7ba9ec87becc9e9bc13c4 100644
--- a/source/gameengine/Converter/BL_ArmatureConstraint.cpp
+++ b/source/gameengine/Converter/BL_ArmatureConstraint.cpp
@@ -147,7 +147,7 @@ void BL_ArmatureConstraint::ReParent(BL_ArmatureObject* armature)
 	}
 }
 
-void BL_ArmatureConstraint::Relink(GEN_Map<GEN_HashedPtr, void*> *obj_map)
+void BL_ArmatureConstraint::Relink(CTR_Map<CTR_HashedPtr, void*> *obj_map)
 {
 	void **h_obj = (*obj_map)[m_target];
 	if (h_obj) {
diff --git a/source/gameengine/Converter/BL_ArmatureConstraint.h b/source/gameengine/Converter/BL_ArmatureConstraint.h
index 1dd685b8cbad792294e3a742a9260af8c945295c..8e6ba1bc2d3e802b58ec0ee2d3305636c3bca0df 100644
--- a/source/gameengine/Converter/BL_ArmatureConstraint.h
+++ b/source/gameengine/Converter/BL_ArmatureConstraint.h
@@ -35,8 +35,8 @@
 #define __BL_ARMATURECONSTRAINT
 
 #include "DNA_constraint_types.h"
-#include "GEN_HashedPtr.h"
-#include "GEN_Map.h"
+#include "CTR_HashedPtr.h"
+#include "CTR_Map.h"
 #include "PyObjectPlus.h"
 
 class SCA_IObject;
@@ -80,7 +80,7 @@ public:
 
 	BL_ArmatureConstraint* GetReplica() const;
 	void ReParent(BL_ArmatureObject* armature);
-	void Relink(GEN_Map<GEN_HashedPtr, void*> *map);
+	void Relink(CTR_Map<CTR_HashedPtr, void*> *map);
 	bool UnlinkObject(SCA_IObject* clientobj);
 
 	void UpdateTarget();
diff --git a/source/gameengine/Converter/BL_ArmatureObject.cpp b/source/gameengine/Converter/BL_ArmatureObject.cpp
index 952af4db8bb9a64dbb0394b1feb66e254e1aaf24..c6c20a96482deae28c8084a7fd6956ebfb3e6496 100644
--- a/source/gameengine/Converter/BL_ArmatureObject.cpp
+++ b/source/gameengine/Converter/BL_ArmatureObject.cpp
@@ -45,8 +45,8 @@
 #include "BKE_armature.h"
 
 #include "BKE_constraint.h"
-#include "GEN_Map.h"
-#include "GEN_HashedPtr.h"
+#include "CTR_Map.h"
+#include "CTR_HashedPtr.h"
 #include "MEM_guardedalloc.h"
 #include "DNA_action_types.h"
 #include "DNA_armature_types.h"
@@ -439,7 +439,7 @@ void BL_ArmatureObject::ReParentLogic()
 	KX_GameObject::ReParentLogic();
 }
 
-void BL_ArmatureObject::Relink(GEN_Map<GEN_HashedPtr, void*> *obj_map)
+void BL_ArmatureObject::Relink(CTR_Map<CTR_HashedPtr, void*> *obj_map)
 {
 	SG_DList::iterator<BL_ArmatureConstraint> cit(m_controlledConstraints);
 	for (cit.begin(); !cit.end(); ++cit) {
diff --git a/source/gameengine/Converter/BL_ArmatureObject.h b/source/gameengine/Converter/BL_ArmatureObject.h
index 8490bfadac23a0ae01b2463e8724b948be651cb6..2c3ca7404b372e285c4b7f576d339dab77939cbd 100644
--- a/source/gameengine/Converter/BL_ArmatureObject.h
+++ b/source/gameengine/Converter/BL_ArmatureObject.h
@@ -60,7 +60,7 @@ public:
 	short GetActivePriority();
 	virtual void ProcessReplica();
 	virtual void ReParentLogic();
-	virtual void Relink(GEN_Map<GEN_HashedPtr, void*> *obj_map);
+	virtual void Relink(CTR_Map<CTR_HashedPtr, void*> *obj_map);
 	virtual bool UnlinkObject(SCA_IObject* clientobj);
 
 	class BL_ActionActuator * GetActiveAction();
diff --git a/source/gameengine/Converter/BL_BlenderDataConversion.cpp b/source/gameengine/Converter/BL_BlenderDataConversion.cpp
index 34b417238aeb32c65095ab89960c7dc3e951ea07..51ab4e4c3996f1cdca808bce632747186d8deecb 100644
--- a/source/gameengine/Converter/BL_BlenderDataConversion.cpp
+++ b/source/gameengine/Converter/BL_BlenderDataConversion.cpp
@@ -156,7 +156,7 @@ extern "C" {
 #include "KX_ScalarInterpolator.h"
 
 #include "KX_IpoConvert.h"
-#include "SYS_System.h"
+#include "BL_System.h"
 
 #include "SG_Node.h"
 #include "SG_BBox.h"
diff --git a/source/gameengine/Converter/BL_BlenderDataConversion.h b/source/gameengine/Converter/BL_BlenderDataConversion.h
index cea9f7f2a8b2b2d5736ce07d1f7bff6e157df267..0e8ea17fc389caefa1a3bd819ff9dd07576bd959 100644
--- a/source/gameengine/Converter/BL_BlenderDataConversion.h
+++ b/source/gameengine/Converter/BL_BlenderDataConversion.h
@@ -34,7 +34,7 @@
 #ifndef __BLENDER_CONVERT
 #define __BLENDER_CONVERT
 
-#include "GEN_HashedPtr.h"
+#include "CTR_HashedPtr.h"
 #include "STR_String.h"
 #include "KX_Python.h"
 #include "KX_PhysicsEngineEnums.h"
diff --git a/source/gameengine/Converter/BL_DeformableGameObject.h b/source/gameengine/Converter/BL_DeformableGameObject.h
index 6bcdaff10e3d2181e75148de25e6eccf675ff3ef..615bb84ac2b9b554e36dedb02c91b1438db5ac90 100644
--- a/source/gameengine/Converter/BL_DeformableGameObject.h
+++ b/source/gameengine/Converter/BL_DeformableGameObject.h
@@ -60,7 +60,7 @@ public:
 	{
 		return m_blendobj;
 	}
-	virtual void Relink(GEN_Map<GEN_HashedPtr, void*>*map)
+	virtual void Relink(CTR_Map<CTR_HashedPtr, void*>*map)
 	{
 		if (m_pDeformer)
 			m_pDeformer->Relink (map);
diff --git a/source/gameengine/Converter/BL_MeshDeformer.cpp b/source/gameengine/Converter/BL_MeshDeformer.cpp
index 2a54ea7d9aedf73743a288dff5855634ded2171c..63db91672738c77d83a5eb8baafe58548bb98e95 100644
--- a/source/gameengine/Converter/BL_MeshDeformer.cpp
+++ b/source/gameengine/Converter/BL_MeshDeformer.cpp
@@ -46,7 +46,7 @@
 #include "DNA_mesh_types.h"
 #include "DNA_meshdata_types.h"
 
-#include "GEN_Map.h"
+#include "CTR_Map.h"
 #include "STR_HashedString.h"
 #include "BLI_math.h"
 
@@ -101,7 +101,7 @@ void BL_MeshDeformer::ProcessReplica()
 	m_lastDeformUpdate = -1;
 }
 
-void BL_MeshDeformer::Relink(GEN_Map<class GEN_HashedPtr, void*>*map)
+void BL_MeshDeformer::Relink(CTR_Map<class CTR_HashedPtr, void*>*map)
 {
 	void **h_obj = (*map)[m_gameobj];
 
diff --git a/source/gameengine/Converter/BL_MeshDeformer.h b/source/gameengine/Converter/BL_MeshDeformer.h
index b62958c7fd1dbf5cbbbbf747494f405814c429e5..90466e930fb507cda0e5d13d224d9f6e662acd23 100644
--- a/source/gameengine/Converter/BL_MeshDeformer.h
+++ b/source/gameengine/Converter/BL_MeshDeformer.h
@@ -51,7 +51,7 @@ class BL_MeshDeformer : public RAS_Deformer
 public:
 	void VerifyStorage();
 	void RecalcNormals();
-	virtual void Relink(GEN_Map<class GEN_HashedPtr, void*>*map);
+	virtual void Relink(CTR_Map<class CTR_HashedPtr, void*>*map);
 	BL_MeshDeformer(BL_DeformableGameObject *gameobj,
 					struct Object* obj,
 					class RAS_MeshObject *meshobj ):
diff --git a/source/gameengine/Converter/BL_ModifierDeformer.cpp b/source/gameengine/Converter/BL_ModifierDeformer.cpp
index 95f362a2879b1227f900b9d450fdaabfbd715fb0..e504fa7e49d103d4a824c0f2a1ce06dd074d61dc 100644
--- a/source/gameengine/Converter/BL_ModifierDeformer.cpp
+++ b/source/gameengine/Converter/BL_ModifierDeformer.cpp
@@ -38,7 +38,7 @@
 
 #include "MEM_guardedalloc.h"
 #include "BL_ModifierDeformer.h"
-#include "GEN_Map.h"
+#include "CTR_Map.h"
 #include "STR_HashedString.h"
 #include "RAS_IPolygonMaterial.h"
 #include "RAS_MeshObject.h"
diff --git a/source/gameengine/Converter/BL_ShapeActionActuator.h b/source/gameengine/Converter/BL_ShapeActionActuator.h
index 229c59a34a4f0d3a80f8421a503934be35afd859..7a4523d45541e06e3198edd96394ed754c63c8e2 100644
--- a/source/gameengine/Converter/BL_ShapeActionActuator.h
+++ b/source/gameengine/Converter/BL_ShapeActionActuator.h
@@ -34,7 +34,7 @@
 #ifndef BL_SHAPEACTIONACTUATOR
 #define BL_SHAPEACTIONACTUATOR
 
-#include "GEN_HashedPtr.h"
+#include "CTR_HashedPtr.h"
 #include "SCA_IActuator.h"
 #include "BL_ActionActuator.h"
 #include "MT_Point3.h"
diff --git a/source/gameengine/Converter/BL_ShapeDeformer.cpp b/source/gameengine/Converter/BL_ShapeDeformer.cpp
index 40e7c6e1bde85b9440075f267b577deba9aa2dcc..8d8f149bb6c2ee90bf8dc25fd158361694ba8a9a 100644
--- a/source/gameengine/Converter/BL_ShapeDeformer.cpp
+++ b/source/gameengine/Converter/BL_ShapeDeformer.cpp
@@ -38,7 +38,7 @@
 
 #include "MEM_guardedalloc.h"
 #include "BL_ShapeDeformer.h"
-#include "GEN_Map.h"
+#include "CTR_Map.h"
 #include "STR_HashedString.h"
 #include "RAS_IPolygonMaterial.h"
 #include "RAS_MeshObject.h"
diff --git a/source/gameengine/Converter/BL_SkinDeformer.cpp b/source/gameengine/Converter/BL_SkinDeformer.cpp
index 4916ce53fc5cea3e0cbaa08be6063ecbff0fb745..34f9cb56c27232260436c8c666a87fa6bac19bc6 100644
--- a/source/gameengine/Converter/BL_SkinDeformer.cpp
+++ b/source/gameengine/Converter/BL_SkinDeformer.cpp
@@ -37,7 +37,7 @@
 #endif //WIN32
 
 #include "BL_SkinDeformer.h"
-#include "GEN_Map.h"
+#include "CTR_Map.h"
 #include "STR_HashedString.h"
 #include "RAS_IPolygonMaterial.h"
 #include "RAS_MeshObject.h"
@@ -108,7 +108,7 @@ BL_SkinDeformer::~BL_SkinDeformer()
 		m_armobj->Release();
 }
 
-void BL_SkinDeformer::Relink(GEN_Map<class GEN_HashedPtr, void*>*map)
+void BL_SkinDeformer::Relink(CTR_Map<class CTR_HashedPtr, void*>*map)
 {
 	if (m_armobj) {
 		void **h_obj = (*map)[m_armobj];
diff --git a/source/gameengine/Converter/BL_SkinDeformer.h b/source/gameengine/Converter/BL_SkinDeformer.h
index 69b8783ce2273e394f79d635676b5cbe333515c7..e53e21e946ff58df45ea73a4041b70f05580f4e0 100644
--- a/source/gameengine/Converter/BL_SkinDeformer.h
+++ b/source/gameengine/Converter/BL_SkinDeformer.h
@@ -38,7 +38,7 @@
 #pragma warning (disable:4786) // get rid of stupid stl-visual compiler debug warning
 #endif //WIN32
 
-#include "GEN_HashedPtr.h"
+#include "CTR_HashedPtr.h"
 #include "BL_MeshDeformer.h"
 #include "BL_ArmatureObject.h"
 
@@ -54,7 +54,7 @@ class BL_SkinDeformer : public BL_MeshDeformer
 {
 public:
 //	void SetArmatureController (BL_ArmatureController *cont);
-	virtual void Relink(GEN_Map<class GEN_HashedPtr, void*>*map);
+	virtual void Relink(CTR_Map<class CTR_HashedPtr, void*>*map);
 	void SetArmature (class BL_ArmatureObject *armobj);
 
 	BL_SkinDeformer(BL_DeformableGameObject *gameobj,
diff --git a/source/gameengine/Converter/CMakeLists.txt b/source/gameengine/Converter/CMakeLists.txt
index 147c8b791eedb201c70331a89a3fc98ccab3707e..bdd0769e0a38c3ff44693fd6b9055d9f8fc2d37a 100644
--- a/source/gameengine/Converter/CMakeLists.txt
+++ b/source/gameengine/Converter/CMakeLists.txt
@@ -26,9 +26,9 @@
 
 set(INC
 	.
-	../../../source/kernel/gen_system
 	../../../intern/string
 	../../../intern/guardedalloc
+	../../../intern/container
 	../../../source/gameengine/Rasterizer/RAS_OpenGLRasterizer
 	../../../intern/audaspace/intern
 	../../../source/gameengine/Converter
diff --git a/source/gameengine/Converter/KX_BlenderSceneConverter.cpp b/source/gameengine/Converter/KX_BlenderSceneConverter.cpp
index a0d58ece39670978ccac5088988cc0a4d05029bd..684ed0b06f9e7d2951fb723f3a87026f4bdd3688 100644
--- a/source/gameengine/Converter/KX_BlenderSceneConverter.cpp
+++ b/source/gameengine/Converter/KX_BlenderSceneConverter.cpp
@@ -50,7 +50,7 @@
 #include "KX_PolygonMaterial.h"
 
 
-#include "SYS_System.h"
+#include "BL_System.h"
 
 #include "DummyPhysicsEnvironment.h"
 
@@ -1126,7 +1126,7 @@ bool KX_BlenderSceneConverter::FreeBlendFile(struct Main *maggie)
 			
 			/* incase the mesh might be refered to later */
 			{
-				GEN_Map<STR_HashedString,void*> &mapStringToMeshes = scene->GetLogicManager()->GetMeshMap();
+				CTR_Map<STR_HashedString,void*> &mapStringToMeshes = scene->GetLogicManager()->GetMeshMap();
 				
 				for(int i=0; i<mapStringToMeshes.size(); i++)
 				{
@@ -1143,7 +1143,7 @@ bool KX_BlenderSceneConverter::FreeBlendFile(struct Main *maggie)
 
 			/* Now unregister actions */
 			{
-				GEN_Map<STR_HashedString,void*> &mapStringToActions = scene->GetLogicManager()->GetActionMap();
+				CTR_Map<STR_HashedString,void*> &mapStringToActions = scene->GetLogicManager()->GetActionMap();
 
 				for(int i=0; i<mapStringToActions.size(); i++)
 				{
diff --git a/source/gameengine/Converter/KX_BlenderSceneConverter.h b/source/gameengine/Converter/KX_BlenderSceneConverter.h
index 741b3ea8757ace3a380528991ca071dd5763e39c..2340e44d288198b2194fe113b015e2a979b4f0e4 100644
--- a/source/gameengine/Converter/KX_BlenderSceneConverter.h
+++ b/source/gameengine/Converter/KX_BlenderSceneConverter.h
@@ -35,7 +35,7 @@
 #define __KX_BLENDERSCENECONVERTER_H
 
 #include "KX_HashedPtr.h"
-#include "GEN_Map.h"
+#include "CTR_Map.h"
 #include <stdio.h>
 
 #include "KX_ISceneConverter.h"
@@ -61,12 +61,12 @@ class KX_BlenderSceneConverter : public KX_ISceneConverter
 	// Should also have a list of collision shapes. 
 	// For the time being this is held in KX_Scene::m_shapes
 
-	GEN_Map<CHashedPtr,KX_GameObject*>	m_map_blender_to_gameobject;		/* cleared after conversion */
-	GEN_Map<CHashedPtr,RAS_MeshObject*>	m_map_mesh_to_gamemesh;				/* cleared after conversion */
-	GEN_Map<CHashedPtr,SCA_IActuator*>	m_map_blender_to_gameactuator;		/* cleared after conversion */
-	GEN_Map<CHashedPtr,SCA_IController*>m_map_blender_to_gamecontroller;	/* cleared after conversion */
+	CTR_Map<CHashedPtr,KX_GameObject*>	m_map_blender_to_gameobject;		/* cleared after conversion */
+	CTR_Map<CHashedPtr,RAS_MeshObject*>	m_map_mesh_to_gamemesh;				/* cleared after conversion */
+	CTR_Map<CHashedPtr,SCA_IActuator*>	m_map_blender_to_gameactuator;		/* cleared after conversion */
+	CTR_Map<CHashedPtr,SCA_IController*>m_map_blender_to_gamecontroller;	/* cleared after conversion */
 	
-	GEN_Map<CHashedPtr,BL_InterpolatorList*> m_map_blender_to_gameAdtList;
+	CTR_Map<CHashedPtr,BL_InterpolatorList*> m_map_blender_to_gameAdtList;
 	
 	Main*					m_maggie;
 	vector<struct Main*>	m_DynamicMaggie;
diff --git a/source/gameengine/Converter/KX_SoftBodyDeformer.cpp b/source/gameengine/Converter/KX_SoftBodyDeformer.cpp
index d3d17bbe43357aeaa23b29854ef2057c170e50eb..02c259d793bd1d5d1d01a926078477c6b091d709 100644
--- a/source/gameengine/Converter/KX_SoftBodyDeformer.cpp
+++ b/source/gameengine/Converter/KX_SoftBodyDeformer.cpp
@@ -41,8 +41,8 @@
 #include "KX_ConvertPhysicsObject.h"
 #include "KX_SoftBodyDeformer.h"
 #include "RAS_MeshObject.h"
-#include "GEN_Map.h"
-#include "GEN_HashedPtr.h"
+#include "CTR_Map.h"
+#include "CTR_HashedPtr.h"
 
 #ifdef USE_BULLET
 
@@ -53,7 +53,7 @@
 #include "KX_BulletPhysicsController.h"
 #include "btBulletDynamicsCommon.h"
 
-void KX_SoftBodyDeformer::Relink(GEN_Map<class GEN_HashedPtr, void*>*map)
+void KX_SoftBodyDeformer::Relink(CTR_Map<class CTR_HashedPtr, void*>*map)
 {
 	void **h_obj = (*map)[m_gameobj];
 
diff --git a/source/gameengine/Converter/KX_SoftBodyDeformer.h b/source/gameengine/Converter/KX_SoftBodyDeformer.h
index aa4ff9d5e54a7471cb0ab40335c4521b86e234ee..67eb9d7b2859668cb413dc2e6b8f1222f1bd1417 100644
--- a/source/gameengine/Converter/KX_SoftBodyDeformer.h
+++ b/source/gameengine/Converter/KX_SoftBodyDeformer.h
@@ -60,7 +60,7 @@ public:
 	{
 		//printf("~KX_SoftBodyDeformer\n");
 	};
-	virtual void Relink(GEN_Map<class GEN_HashedPtr, void*>*map);
+	virtual void Relink(CTR_Map<class CTR_HashedPtr, void*>*map);
 	virtual bool Apply(class RAS_IPolyMaterial *polymat);
 	virtual bool Update(void)
 	{
diff --git a/source/gameengine/Converter/SConscript b/source/gameengine/Converter/SConscript
index 9d88018d805ac3466377ea4f9ac8b120fc0d295b..9cfc341074866166be7dec7752e307fb31a1b450 100644
--- a/source/gameengine/Converter/SConscript
+++ b/source/gameengine/Converter/SConscript
@@ -4,7 +4,7 @@ Import ('env')
 sources = env.Glob('*.cpp')
 defs = []
 
-incs = '. #source/kernel/gen_system #intern/string #intern/guardedalloc'
+incs = '. #intern/string #intern/guardedalloc #intern/container'
 incs += ' #source/gameengine/Rasterizer/RAS_OpenGLRasterizer'
 incs += ' #intern/audaspace/intern #source/gameengine/Converter'
 incs += ' #source/gameengine/BlenderRoutines #source/blender/imbuf'
diff --git a/source/gameengine/Expressions/CMakeLists.txt b/source/gameengine/Expressions/CMakeLists.txt
index c593c69061407d95d69a89e77acd7bb2254b1f58..8cda0e2dc77ace6e5b2364a42a7e1f04cac6d634 100644
--- a/source/gameengine/Expressions/CMakeLists.txt
+++ b/source/gameengine/Expressions/CMakeLists.txt
@@ -26,7 +26,6 @@
 
 set(INC
 	.
-	../../../source/kernel/gen_system
 	../../../intern/string
 	../../../intern/guardedalloc
 	../../../intern/moto/include
diff --git a/source/gameengine/Expressions/SConscript b/source/gameengine/Expressions/SConscript
index b1e34aa358bb4a7f66677e8910b135604e21deba..4dc165a7696f3b8bdf22a9a57cdfc4ca21e70dc3 100644
--- a/source/gameengine/Expressions/SConscript
+++ b/source/gameengine/Expressions/SConscript
@@ -3,7 +3,7 @@ Import ('env')
 
 sources = env.Glob('*.cpp')
 
-incs ='. #source/kernel/gen_system #intern/guardedalloc #intern/string #intern/moto/include #source/gameengine/SceneGraph #source/blender/blenloader'
+incs ='. #intern/guardedalloc #intern/string #intern/moto/include #source/gameengine/SceneGraph #source/blender/blenloader'
 
 defs = []
 
diff --git a/source/gameengine/GameLogic/CMakeLists.txt b/source/gameengine/GameLogic/CMakeLists.txt
index 793b8e7eed84f466f4c659d6de26cb644a41b828..2acf07584b174b1e2e395b186d31aa7b91c5855f 100644
--- a/source/gameengine/GameLogic/CMakeLists.txt
+++ b/source/gameengine/GameLogic/CMakeLists.txt
@@ -26,8 +26,8 @@
 
 set(INC
 	. 
-	../../../source/kernel/gen_system 
 	../../../intern/string
+	../../../intern/container
 	../../../source/gameengine/Expressions 
 	../../../source/gameengine/SceneGraph
 	../../../intern/moto/include
diff --git a/source/gameengine/GameLogic/SCA_ILogicBrick.cpp b/source/gameengine/GameLogic/SCA_ILogicBrick.cpp
index 2d0cb16b63c93e6ed21e0ab2654e247fec9116bc..596118855d201fbc7339eb5ddaf64c9a79db138e 100644
--- a/source/gameengine/GameLogic/SCA_ILogicBrick.cpp
+++ b/source/gameengine/GameLogic/SCA_ILogicBrick.cpp
@@ -78,7 +78,7 @@ void SCA_ILogicBrick::ReParent(SCA_IObject* parent)
 	m_gameobj = parent;
 }
 
-void SCA_ILogicBrick::Relink(GEN_Map<GEN_HashedPtr, void*> *obj_map)
+void SCA_ILogicBrick::Relink(CTR_Map<CTR_HashedPtr, void*> *obj_map)
 {
 	// nothing to do
 }
diff --git a/source/gameengine/GameLogic/SCA_ILogicBrick.h b/source/gameengine/GameLogic/SCA_ILogicBrick.h
index e74cd601b6ba6fca7ece54b982f394721a238496..4de0562339e79cc180fb25784f060e14bd93e887 100644
--- a/source/gameengine/GameLogic/SCA_ILogicBrick.h
+++ b/source/gameengine/GameLogic/SCA_ILogicBrick.h
@@ -37,8 +37,8 @@
 #include "Value.h"
 #include "SCA_IObject.h"
 #include "BoolValue.h"
-#include "GEN_Map.h"
-#include "GEN_HashedPtr.h"
+#include "CTR_Map.h"
+#include "CTR_HashedPtr.h"
 
 class NG_NetworkScene;
 class SCA_IScene;
@@ -70,7 +70,7 @@ public:
 	SCA_IObject*	GetParent() { return m_gameobj; }
 
 	virtual void	ReParent(SCA_IObject* parent);
-	virtual void	Relink(GEN_Map<GEN_HashedPtr, void*> *obj_map);
+	virtual void	Relink(CTR_Map<CTR_HashedPtr, void*> *obj_map);
 	virtual void Delete() { Release(); }
 
 	// act as a BoolValue (with value IsPositiveTrigger)
diff --git a/source/gameengine/GameLogic/SCA_LogicManager.h b/source/gameengine/GameLogic/SCA_LogicManager.h
index 44dc12a8fd45f290eeac151034011fe8009a99ba..c4735d1c146cc49678cd9a72fb62a655afba8cc9 100644
--- a/source/gameengine/GameLogic/SCA_LogicManager.h
+++ b/source/gameengine/GameLogic/SCA_LogicManager.h
@@ -38,12 +38,12 @@
 #endif 
 
 #include <vector>
-//#include "GEN_Map.h"
+//#include "CTR_Map.h"
 #include <set>
 #include <map>
 #include <list>
 
-#include "GEN_Map.h"
+#include "CTR_Map.h"
 #include "STR_HashedString.h"
 #include "Value.h"
 #include "SG_QList.h"
@@ -85,12 +85,12 @@ class SCA_LogicManager
 
 	// need to find better way for this
 	// also known as FactoryManager...
-	GEN_Map<STR_HashedString,CValue*>	m_mapStringToGameObjects;
-	GEN_Map<STR_HashedString,void*>		m_mapStringToMeshes;
-	GEN_Map<STR_HashedString,void*>		m_mapStringToActions;
+	CTR_Map<STR_HashedString,CValue*>	m_mapStringToGameObjects;
+	CTR_Map<STR_HashedString,void*>		m_mapStringToMeshes;
+	CTR_Map<STR_HashedString,void*>		m_mapStringToActions;
 
-	GEN_Map<STR_HashedString,void*>		m_map_gamemeshname_to_blendobj;
-	GEN_Map<CHashedPtr,void*>			m_map_blendobj_to_gameobj;
+	CTR_Map<STR_HashedString,void*>		m_map_gamemeshname_to_blendobj;
+	CTR_Map<CHashedPtr,void*>			m_map_blendobj_to_gameobj;
 public:
 	SCA_LogicManager();
 	virtual ~SCA_LogicManager();
@@ -129,8 +129,8 @@ public:
 	// for the scripting... needs a FactoryManager later (if we would have time... ;)
 	void	RegisterMeshName(const STR_String& meshname,void* mesh);
 	void	UnregisterMeshName(const STR_String& meshname,void* mesh);
-	GEN_Map<STR_HashedString,void*>&	GetMeshMap() { return m_mapStringToMeshes; };
-	GEN_Map<STR_HashedString,void*>&	GetActionMap() { return m_mapStringToActions; };
+	CTR_Map<STR_HashedString,void*>&	GetMeshMap() { return m_mapStringToMeshes; };
+	CTR_Map<STR_HashedString,void*>&	GetActionMap() { return m_mapStringToActions; };
 	
 	void	RegisterActionName(const STR_String& actname,void* action);
 
diff --git a/source/gameengine/GameLogic/SCA_PropertyActuator.cpp b/source/gameengine/GameLogic/SCA_PropertyActuator.cpp
index 008e109384c9382b2a2b2277c433641c56892546..a4af1c3565214f6ad362f3124921bd47e93e780c 100644
--- a/source/gameengine/GameLogic/SCA_PropertyActuator.cpp
+++ b/source/gameengine/GameLogic/SCA_PropertyActuator.cpp
@@ -213,7 +213,7 @@ bool SCA_PropertyActuator::UnlinkObject(SCA_IObject* clientobj)
 	return false;
 }
 
-void SCA_PropertyActuator::Relink(GEN_Map<GEN_HashedPtr, void*> *obj_map)
+void SCA_PropertyActuator::Relink(CTR_Map<CTR_HashedPtr, void*> *obj_map)
 {
 	void **h_obj = (*obj_map)[m_sourceObj];
 	if (h_obj) {
diff --git a/source/gameengine/GameLogic/SCA_PropertyActuator.h b/source/gameengine/GameLogic/SCA_PropertyActuator.h
index 1ca7b1c4e1e03a87ab50f32d73d2f11c56e9181f..35660710679c95ef1200a2cf98a3f6bad67219fd 100644
--- a/source/gameengine/GameLogic/SCA_PropertyActuator.h
+++ b/source/gameengine/GameLogic/SCA_PropertyActuator.h
@@ -77,7 +77,7 @@ public:
 
 	virtual void ProcessReplica();
 	virtual bool UnlinkObject(SCA_IObject* clientobj);
-	virtual void Relink(GEN_Map<GEN_HashedPtr, void*> *obj_map);
+	virtual void Relink(CTR_Map<CTR_HashedPtr, void*> *obj_map);
 
 	virtual bool 
 	Update();
diff --git a/source/gameengine/GameLogic/SConscript b/source/gameengine/GameLogic/SConscript
index a8d3ee65f4c9df409838009240cd0e955dff706d..d63238822679f5bd709fa72d27f5a8469f538734 100644
--- a/source/gameengine/GameLogic/SConscript
+++ b/source/gameengine/GameLogic/SConscript
@@ -3,7 +3,7 @@ Import ('env')
 
 sources = env.Glob('*.cpp') + env.Glob('Joystick/*.cpp')
 
-incs = '. #/source/kernel/gen_system #/intern/string'
+incs = '. #/intern/string #intern/container'
 incs += ' #/source/gameengine/Expressions #/intern/moto/include'
 incs += ' #/source/gameengine/Rasterizer #/source/gameengine/SceneGraph'
 
diff --git a/source/gameengine/GamePlayer/common/CMakeLists.txt b/source/gameengine/GamePlayer/common/CMakeLists.txt
index 604dd9296a142a2cf1141c941337e8f3fad13631..afbc49ea38d9b0010c9d4128f72d3ada1c6d7a6f 100644
--- a/source/gameengine/GamePlayer/common/CMakeLists.txt
+++ b/source/gameengine/GamePlayer/common/CMakeLists.txt
@@ -29,11 +29,11 @@ set(INC
 	../../../../intern/string
 	../../../../intern/ghost
 	../../../../intern/guardedalloc
+	../../../../intern/container
 	../../../../intern/moto/include
 	../../../../source/gameengine/Rasterizer/RAS_OpenGLRasterizer
-	../../../../source/kernel/gen_system
-	../../../../source/kernel/gen_messaging
 	../../../../source/gameengine/Converter
+	../../../../source/gameengine/BlenderRoutines
 	../../../../source/blender/imbuf
 	../../../../source/gameengine/Ketsji
 	../../../../source/blender/blenlib
diff --git a/source/gameengine/GamePlayer/common/GPC_Engine.cpp b/source/gameengine/GamePlayer/common/GPC_Engine.cpp
index 48ebfcaadf221d7c5496cd45820f6edd35eecac3..fc007d8d29583d7fd13804f691cf99dfa6ca2dfb 100644
--- a/source/gameengine/GamePlayer/common/GPC_Engine.cpp
+++ b/source/gameengine/GamePlayer/common/GPC_Engine.cpp
@@ -50,7 +50,7 @@
 
 // include files needed by "KX_BlenderSceneConverter.h"
 
-#include "GEN_Map.h"
+#include "CTR_Map.h"
 #include "SCA_IActuator.h"
 #include "RAS_MeshObject.h"
 
diff --git a/source/gameengine/GamePlayer/common/SConscript b/source/gameengine/GamePlayer/common/SConscript
index f7a423f4588dafb2babb0d94a6b92fef01f10876..d5e1f081d21dc82c3e0f02bd4abd1728bca454db 100644
--- a/source/gameengine/GamePlayer/common/SConscript
+++ b/source/gameengine/GamePlayer/common/SConscript
@@ -19,10 +19,10 @@ incs = ['.',
         '#intern/ghost',
         '#intern/guardedalloc',
         '#intern/moto/include',
+        '#intern/container',
         '#source/gameengine/Rasterizer/RAS_OpenGLRasterizer',
-        '#source/kernel/gen_system',
-        '#source/kernel/gen_messaging',
         '#source/gameengine/Converter',
+        '#source/gameengine/BlenderRoutines',
         '#source/blender/imbuf',
         '#source/gameengine/Ketsji',
         '#source/blender/blenlib',
diff --git a/source/gameengine/GamePlayer/ghost/CMakeLists.txt b/source/gameengine/GamePlayer/ghost/CMakeLists.txt
index a88de69b272913b81a320f62c17e54de951e4151..edf0839f74786ef36b9792d56b3d53c7a2c0d197 100644
--- a/source/gameengine/GamePlayer/ghost/CMakeLists.txt
+++ b/source/gameengine/GamePlayer/ghost/CMakeLists.txt
@@ -29,10 +29,10 @@ set(INC
 	../../../../intern/string
 	../../../../intern/ghost
 	../../../../intern/guardedalloc
+	../../../../intern/container
 	../../../../intern/moto/include
 	../../../../source/gameengine/Rasterizer/RAS_OpenGLRasterizer
-	../../../../source/kernel/gen_system
-	../../../../source/kernel/gen_messaging
+	../../../../source/gameengine/BlenderRoutines
 	../../../../source/gameengine/Converter
 	../../../../source/blender/imbuf
 	../../../../source/gameengine/Ketsji
diff --git a/source/gameengine/GamePlayer/ghost/GPG_Application.cpp b/source/gameengine/GamePlayer/ghost/GPG_Application.cpp
index 6ea98e0e8cc114ae4980229c29fa8e26fd8a98f5..6487d0298c7518e7add7df295851e04b12c6e7e9 100644
--- a/source/gameengine/GamePlayer/ghost/GPG_Application.cpp
+++ b/source/gameengine/GamePlayer/ghost/GPG_Application.cpp
@@ -69,11 +69,11 @@ extern "C"
  **********************************/
 
 
-#include "SYS_System.h"
+#include "BL_System.h"
 #include "KX_KetsjiEngine.h"
 
 // include files needed by "KX_BlenderSceneConverter.h"
-#include "GEN_Map.h"
+#include "CTR_Map.h"
 #include "SCA_IActuator.h"
 #include "RAS_MeshObject.h"
 #include "RAS_OpenGLRasterizer.h"
diff --git a/source/gameengine/GamePlayer/ghost/GPG_ghost.cpp b/source/gameengine/GamePlayer/ghost/GPG_ghost.cpp
index 0ab6da240ce43f2d91b49e8745f9c13abeeff6a3..a4f1391b1b0bae61d8648d36ec100eb901c7ffec 100644
--- a/source/gameengine/GamePlayer/ghost/GPG_ghost.cpp
+++ b/source/gameengine/GamePlayer/ghost/GPG_ghost.cpp
@@ -47,7 +47,6 @@
 //#include <Carbon/Carbon.h>
 //#include <CFBundle.h>
 #endif // __APPLE__
-#include "GEN_messaging.h"
 #include "KX_KetsjiEngine.h"
 #include "KX_PythonInit.h"
 
@@ -92,7 +91,7 @@ extern char datatoc_bfont_ttf[];
 * End Blender include block
 **********************************/
 
-#include "SYS_System.h"
+#include "BL_System.h"
 #include "GPG_Application.h"
 
 #include "GHOST_ISystem.h"
@@ -403,8 +402,6 @@ int main(int argc, char** argv)
 	
 	initglobals();
 
-	GEN_init_messaging_system();
-
 	IMB_init();
 
 	// Setup builtin font for BLF (mostly copied from creator.c, wm_init_exit.c and interface_style.c)
diff --git a/source/gameengine/GamePlayer/ghost/SConscript b/source/gameengine/GamePlayer/ghost/SConscript
index 7c8f1c6f4f0763be6010facd02d63fb383c002be..65bd55f95d7ddf2152ce443bfceb31fadd311880 100644
--- a/source/gameengine/GamePlayer/ghost/SConscript
+++ b/source/gameengine/GamePlayer/ghost/SConscript
@@ -13,9 +13,9 @@ incs = ['.',
         '#intern/ghost',
         '#intern/guardedalloc',
         '#intern/moto/include',
+        '#intern/container',
         '#source/gameengine/Rasterizer/RAS_OpenGLRasterizer',
-        '#source/kernel/gen_system',
-        '#source/kernel/gen_messaging',
+        '#source/gameengine/BlenderRoutines',
         '#source/gameengine/Converter',
         '#source/blender/imbuf',
         '#source/gameengine/Ketsji',
diff --git a/source/gameengine/Ketsji/CMakeLists.txt b/source/gameengine/Ketsji/CMakeLists.txt
index d5ea39f5b35f414c5dd1a62612de5f8a043b2cc5..0bfe1fd0266c7e1d1f41e256df9be53afb7ff0bb 100644
--- a/source/gameengine/Ketsji/CMakeLists.txt
+++ b/source/gameengine/Ketsji/CMakeLists.txt
@@ -26,11 +26,12 @@
 
 set(INC
 	.
-	../../../source/kernel/gen_system
 	../../../intern/string
 	../../../intern/guardedalloc
+	../../../intern/container
 	../../../source/gameengine/Rasterizer/RAS_OpenGLRasterizer 
 	../../../source/gameengine/Converter
+	../../../source/gameengine/BlenderRoutines
 	../../../source/blender/imbuf
 	../../../intern/moto/include
 	../../../source/gameengine/Ketsji 
diff --git a/source/gameengine/Ketsji/KXNetwork/CMakeLists.txt b/source/gameengine/Ketsji/KXNetwork/CMakeLists.txt
index 5f251c832eefbd8352e829ddb2896bf66481bb71..17a5929420db292a8751ce5de9063c53c3f4570a 100644
--- a/source/gameengine/Ketsji/KXNetwork/CMakeLists.txt
+++ b/source/gameengine/Ketsji/KXNetwork/CMakeLists.txt
@@ -26,8 +26,8 @@
 
 set(INC
 	.
-	../../../../source/kernel/gen_system
 	../../../../intern/string
+	../../../../intern/container
 	../../../../intern/moto/include
 	../../../../source/gameengine/Ketsji
 	../../../../source/gameengine/GameLogic
diff --git a/source/gameengine/Ketsji/KXNetwork/SConscript b/source/gameengine/Ketsji/KXNetwork/SConscript
index 78cdc8df9afda37ee38fa092d006921d2466f818..3d6965012038f77b3d38b7e78f79dfda83f3ec2c 100644
--- a/source/gameengine/Ketsji/KXNetwork/SConscript
+++ b/source/gameengine/Ketsji/KXNetwork/SConscript
@@ -3,7 +3,8 @@ Import ('env')
 
 sources = env.Glob('*.cpp')
 
-incs = '. #source/kernel/gen_system #intern/string #intern/moto/include #source/gameengine/Ketsji'
+incs = '. #intern/string #intern/moto/include'
+incs += ' #source/gameengine/Ketsji #intern/container'
 incs += ' #source/gameengine/GameLogic #source/gameengine/Expressions'
 incs += ' #source/gameengine/Network #source/gameengine/SceneGraph'
 
diff --git a/source/gameengine/Ketsji/KX_CameraActuator.cpp b/source/gameengine/Ketsji/KX_CameraActuator.cpp
index 17dfe9474a8f26dad191b11431711822367e54d8..d68cb453fe8427f2613dfb9332f9e5aa1f5377dd 100644
--- a/source/gameengine/Ketsji/KX_CameraActuator.cpp
+++ b/source/gameengine/Ketsji/KX_CameraActuator.cpp
@@ -101,7 +101,7 @@ bool KX_CameraActuator::UnlinkObject(SCA_IObject* clientobj)
 }
 
 
-void KX_CameraActuator::Relink(GEN_Map<GEN_HashedPtr, void*> *obj_map)
+void KX_CameraActuator::Relink(CTR_Map<CTR_HashedPtr, void*> *obj_map)
 {
 	void **h_obj = (*obj_map)[m_ob];
 	if (h_obj) {
diff --git a/source/gameengine/Ketsji/KX_CameraActuator.h b/source/gameengine/Ketsji/KX_CameraActuator.h
index 135a9cad9d8e9d2bac71009b90ae684362feb478..d59fcff9370075347815d50e19550a2ddddc70c5 100644
--- a/source/gameengine/Ketsji/KX_CameraActuator.h
+++ b/source/gameengine/Ketsji/KX_CameraActuator.h
@@ -116,7 +116,7 @@ private :
 	virtual bool	UnlinkObject(SCA_IObject* clientobj);
 
 	/** Methods inherited from SCA_ILogicBrick */
-	virtual void	Relink(GEN_Map<GEN_HashedPtr, void*> *obj_map);
+	virtual void	Relink(CTR_Map<CTR_HashedPtr, void*> *obj_map);
 
 #ifdef WITH_PYTHON
 
diff --git a/source/gameengine/Ketsji/KX_ConvertPhysicsObjects.cpp b/source/gameengine/Ketsji/KX_ConvertPhysicsObjects.cpp
index b7cc98bd53979a065d3734615eb8109cf9d205c9..7bd8c44584926f6834bc0bf34c640623ab97caea 100644
--- a/source/gameengine/Ketsji/KX_ConvertPhysicsObjects.cpp
+++ b/source/gameengine/Ketsji/KX_ConvertPhysicsObjects.cpp
@@ -42,13 +42,13 @@
 #include "BL_DeformableGameObject.h"
 #include "RAS_MeshObject.h"
 #include "KX_Scene.h"
-#include "SYS_System.h"
+#include "BL_System.h"
 
 #include "PHY_Pro.h" //todo cleanup
 #include "KX_ClientObjectInfo.h"
 
-#include "GEN_Map.h"
-#include "GEN_HashedPtr.h"
+#include "CTR_Map.h"
+#include "CTR_HashedPtr.h"
 
 #include "KX_PhysicsEngineEnums.h"
 #include "PHY_Pro.h"
diff --git a/source/gameengine/Ketsji/KX_GameObject.cpp b/source/gameengine/Ketsji/KX_GameObject.cpp
index d8bc7510c7b647552a0716407d8fc7aaf924e705..47d83c16659b255bf291c9f116366b201ddff83b 100644
--- a/source/gameengine/Ketsji/KX_GameObject.cpp
+++ b/source/gameengine/Ketsji/KX_GameObject.cpp
@@ -1224,7 +1224,7 @@ CListValue* KX_GameObject::GetChildrenRecursive()
 /* ---------------------------------------------------------------------
  * Some stuff taken from the header
  * --------------------------------------------------------------------- */
-void KX_GameObject::Relink(GEN_Map<GEN_HashedPtr, void*> *map_parameter)
+void KX_GameObject::Relink(CTR_Map<CTR_HashedPtr, void*> *map_parameter)
 {
 	// we will relink the sensors and actuators that use object references
 	// if the object is part of the replicated hierarchy, use the new
diff --git a/source/gameengine/Ketsji/KX_GameObject.h b/source/gameengine/Ketsji/KX_GameObject.h
index b54fb6b068e39cdca8de0d54d2c27fc1711a3105..50fbebe1341d86b66d215ae330bbebe98b0b9c5b 100644
--- a/source/gameengine/Ketsji/KX_GameObject.h
+++ b/source/gameengine/Ketsji/KX_GameObject.h
@@ -47,8 +47,8 @@
 #include "SG_Node.h"
 #include "MT_Transform.h"
 #include "MT_CmMatrix4x4.h"
-#include "GEN_Map.h"
-#include "GEN_HashedPtr.h"
+#include "CTR_Map.h"
+#include "CTR_HashedPtr.h"
 #include "KX_Scene.h"
 #include "KX_KetsjiEngine.h" /* for m_anim_framerate */
 #include "KX_IPhysicsController.h" /* for suspend/resume */
@@ -142,7 +142,7 @@ public:
 
 	virtual void	/* This function should be virtual - derived classed override it */
 	Relink(
-		GEN_Map<GEN_HashedPtr, void*> *map
+		CTR_Map<CTR_HashedPtr, void*> *map
 	);
 
 	/**
diff --git a/source/gameengine/Ketsji/KX_ObjectActuator.cpp b/source/gameengine/Ketsji/KX_ObjectActuator.cpp
index 8c3e25cf3e28f1af69684f2487037be612ef1b88..7289ffc6e29206fbde0792d9c447d00017cb1023 100644
--- a/source/gameengine/Ketsji/KX_ObjectActuator.cpp
+++ b/source/gameengine/Ketsji/KX_ObjectActuator.cpp
@@ -299,7 +299,7 @@ bool KX_ObjectActuator::UnlinkObject(SCA_IObject* clientobj)
 	return false;
 }
 
-void KX_ObjectActuator::Relink(GEN_Map<GEN_HashedPtr, void*> *obj_map)
+void KX_ObjectActuator::Relink(CTR_Map<CTR_HashedPtr, void*> *obj_map)
 {
 	void **h_obj = (*obj_map)[m_reference];
 	if (h_obj) {
diff --git a/source/gameengine/Ketsji/KX_ObjectActuator.h b/source/gameengine/Ketsji/KX_ObjectActuator.h
index e45ce899bfc8fd4940126fe306bd9faf6d55fa3c..0737535b84cc1b37756e5efea548319ee104cb29 100644
--- a/source/gameengine/Ketsji/KX_ObjectActuator.h
+++ b/source/gameengine/Ketsji/KX_ObjectActuator.h
@@ -144,7 +144,7 @@ public:
 	CValue* GetReplica();
 	void ProcessReplica();
 	bool UnlinkObject(SCA_IObject* clientobj);
-	void Relink(GEN_Map<GEN_HashedPtr, void*> *obj_map);
+	void Relink(CTR_Map<CTR_HashedPtr, void*> *obj_map);
 
 	void SetForceLoc(const double force[3])	{ /*m_force=force;*/ }
 	void UpdateFuzzyFlags()
diff --git a/source/gameengine/Ketsji/KX_ParentActuator.cpp b/source/gameengine/Ketsji/KX_ParentActuator.cpp
index 6ff1c05b99419c3d95653d59d93d10ad19d64b78..a73f4c3862795b118eec5ce0bae33ad1564c6b4f 100644
--- a/source/gameengine/Ketsji/KX_ParentActuator.cpp
+++ b/source/gameengine/Ketsji/KX_ParentActuator.cpp
@@ -99,7 +99,7 @@ bool KX_ParentActuator::UnlinkObject(SCA_IObject* clientobj)
 	return false;
 }
 
-void KX_ParentActuator::Relink(GEN_Map<GEN_HashedPtr, void*> *obj_map)
+void KX_ParentActuator::Relink(CTR_Map<CTR_HashedPtr, void*> *obj_map)
 {
 	void **h_obj = (*obj_map)[m_ob];
 	if (h_obj) {
diff --git a/source/gameengine/Ketsji/KX_ParentActuator.h b/source/gameengine/Ketsji/KX_ParentActuator.h
index 8723f83920e6b47174e0e07c000b500d63ad9c75..a850cc72eb91f902f0b236717c30f443dc9e86d2 100644
--- a/source/gameengine/Ketsji/KX_ParentActuator.h
+++ b/source/gameengine/Ketsji/KX_ParentActuator.h
@@ -76,7 +76,7 @@ class KX_ParentActuator : public SCA_IActuator
 	
 	virtual CValue* GetReplica();
 	virtual void ProcessReplica();
-	virtual void Relink(GEN_Map<GEN_HashedPtr, void*> *obj_map);
+	virtual void Relink(CTR_Map<CTR_HashedPtr, void*> *obj_map);
 	virtual bool UnlinkObject(SCA_IObject* clientobj);
 	
 #ifdef WITH_PYTHON
diff --git a/source/gameengine/Ketsji/KX_SCA_AddObjectActuator.cpp b/source/gameengine/Ketsji/KX_SCA_AddObjectActuator.cpp
index 521c0038f270d0a9f726efcdf2fd9dbcc53fe8ae..62a51fb4efccdc116c1bf2c27f5baa3a39cfae32 100644
--- a/source/gameengine/Ketsji/KX_SCA_AddObjectActuator.cpp
+++ b/source/gameengine/Ketsji/KX_SCA_AddObjectActuator.cpp
@@ -151,7 +151,7 @@ bool KX_SCA_AddObjectActuator::UnlinkObject(SCA_IObject* clientobj)
 	return false;
 }
 
-void KX_SCA_AddObjectActuator::Relink(GEN_Map<GEN_HashedPtr, void*> *obj_map)
+void KX_SCA_AddObjectActuator::Relink(CTR_Map<CTR_HashedPtr, void*> *obj_map)
 {
 	void **h_obj = (*obj_map)[m_OriginalObject];
 	if (h_obj) {
diff --git a/source/gameengine/Ketsji/KX_SCA_AddObjectActuator.h b/source/gameengine/Ketsji/KX_SCA_AddObjectActuator.h
index 11f210ad7b5b8a4e12dab07ce67e93c7339ad865..a8304667b6647b41e0c8d20896511b454f3d4778 100644
--- a/source/gameengine/Ketsji/KX_SCA_AddObjectActuator.h
+++ b/source/gameengine/Ketsji/KX_SCA_AddObjectActuator.h
@@ -108,7 +108,7 @@ public:
 	UnlinkObject(SCA_IObject* clientobj);
 
 	virtual void 
-	Relink(GEN_Map<GEN_HashedPtr, void*> *obj_map);
+	Relink(CTR_Map<CTR_HashedPtr, void*> *obj_map);
 
 	virtual bool 
 	Update();
diff --git a/source/gameengine/Ketsji/KX_Scene.cpp b/source/gameengine/Ketsji/KX_Scene.cpp
index 080765c78468779ba41d9c812f3edc59a2405a75..28dc660037c5046cc04ba5a5399d18d56393035f 100644
--- a/source/gameengine/Ketsji/KX_Scene.cpp
+++ b/source/gameengine/Ketsji/KX_Scene.cpp
@@ -67,7 +67,7 @@
 #include "SCA_IController.h"
 #include "SCA_IActuator.h"
 #include "SG_Node.h"
-#include "SYS_System.h"
+#include "BL_System.h"
 #include "SG_Controller.h"
 #include "SG_IObject.h"
 #include "SG_Tree.h"
diff --git a/source/gameengine/Ketsji/KX_Scene.h b/source/gameengine/Ketsji/KX_Scene.h
index af6a31e786cc4af9f7bbe2326d82076dd9850d4a..367bf0b82da21e0a08a8b8390fd782a25d48d04c 100644
--- a/source/gameengine/Ketsji/KX_Scene.h
+++ b/source/gameengine/Ketsji/KX_Scene.h
@@ -41,8 +41,8 @@
 #include <set>
 #include <list>
 
-#include "GEN_Map.h"
-#include "GEN_HashedPtr.h"
+#include "CTR_Map.h"
+#include "CTR_HashedPtr.h"
 #include "SG_IObject.h"
 #include "SCA_IScene.h"
 #include "MT_Transform.h"
@@ -61,7 +61,7 @@ struct SM_MaterialProps;
 struct SM_ShapeProps;
 struct Scene;
 
-class GEN_HashedPtr;
+class CTR_HashedPtr;
 class CListValue;
 class CValue;
 class SCA_LogicManager;
@@ -207,7 +207,7 @@ protected:
 	 * used in AddReplicaObject to map game objects to their
 	 * replicas so pointers can be updated.
 	 */
-	GEN_Map	<GEN_HashedPtr, void*> m_map_gameobject_to_replica;
+	CTR_Map	<CTR_HashedPtr, void*> m_map_gameobject_to_replica;
 
 	/**
 	 * Another temporary variable outstaying its welcome
diff --git a/source/gameengine/Ketsji/KX_SceneActuator.cpp b/source/gameengine/Ketsji/KX_SceneActuator.cpp
index 8312a14ebfb1ef4367f06b0325e1300ab7c2de62..f572f8eb36d65f3d5ebf940343d0cc9059da4592 100644
--- a/source/gameengine/Ketsji/KX_SceneActuator.cpp
+++ b/source/gameengine/Ketsji/KX_SceneActuator.cpp
@@ -97,7 +97,7 @@ bool KX_SceneActuator::UnlinkObject(SCA_IObject* clientobj)
 	return false;
 }
 
-void KX_SceneActuator::Relink(GEN_Map<GEN_HashedPtr, void*> *obj_map)
+void KX_SceneActuator::Relink(CTR_Map<CTR_HashedPtr, void*> *obj_map)
 {
 	void **h_obj = (*obj_map)[m_camera];
 	if (h_obj) {
diff --git a/source/gameengine/Ketsji/KX_SceneActuator.h b/source/gameengine/Ketsji/KX_SceneActuator.h
index 563255d1560a53b112b9e677e2ad479008930d7f..288f4acc280b5d1ee60507291de875a73663e2f7 100644
--- a/source/gameengine/Ketsji/KX_SceneActuator.h
+++ b/source/gameengine/Ketsji/KX_SceneActuator.h
@@ -85,7 +85,7 @@ class KX_SceneActuator : public SCA_IActuator
 	virtual CValue* GetReplica();
 	virtual void ProcessReplica();
 	virtual bool UnlinkObject(SCA_IObject* clientobj);
-	virtual void Relink(GEN_Map<GEN_HashedPtr, void*> *obj_map);
+	virtual void Relink(CTR_Map<CTR_HashedPtr, void*> *obj_map);
 
 	virtual bool Update();
 	
diff --git a/source/gameengine/Ketsji/KX_TrackToActuator.cpp b/source/gameengine/Ketsji/KX_TrackToActuator.cpp
index 5530fa286cff017f747d2b9eee84fc160bfd81b8..edcba969811561a589b35dcc0382755ec58117f0 100644
--- a/source/gameengine/Ketsji/KX_TrackToActuator.cpp
+++ b/source/gameengine/Ketsji/KX_TrackToActuator.cpp
@@ -219,7 +219,7 @@ bool KX_TrackToActuator::UnlinkObject(SCA_IObject* clientobj)
 	return false;
 }
 
-void KX_TrackToActuator::Relink(GEN_Map<GEN_HashedPtr, void*> *obj_map)
+void KX_TrackToActuator::Relink(CTR_Map<CTR_HashedPtr, void*> *obj_map)
 {
 	void **h_obj = (*obj_map)[m_object];
 	if (h_obj) {
diff --git a/source/gameengine/Ketsji/KX_TrackToActuator.h b/source/gameengine/Ketsji/KX_TrackToActuator.h
index 33780bf53e4aae51be014f839a4c1c7568bf66a8..c5e96bd74542da43cf54f6c0e2cae06028843dd8 100644
--- a/source/gameengine/Ketsji/KX_TrackToActuator.h
+++ b/source/gameengine/Ketsji/KX_TrackToActuator.h
@@ -67,7 +67,7 @@ class KX_TrackToActuator : public SCA_IActuator
 
 	virtual void ProcessReplica();
 	virtual bool UnlinkObject(SCA_IObject* clientobj);
-	virtual void Relink(GEN_Map<GEN_HashedPtr, void*> *obj_map);
+	virtual void Relink(CTR_Map<CTR_HashedPtr, void*> *obj_map);
 	virtual bool Update(double curtime, bool frame);
 
 #ifdef WITH_PYTHON
diff --git a/source/gameengine/Ketsji/SConscript b/source/gameengine/Ketsji/SConscript
index 56e0db0cc203e1f26971999b49ca85866439e350..086422627247e1c6735bf20aeea98339f8810169 100644
--- a/source/gameengine/Ketsji/SConscript
+++ b/source/gameengine/Ketsji/SConscript
@@ -8,7 +8,7 @@ defs = [ 'GLEW_STATIC' ]
 
 incs = '. #source/blender/python/generic' # Only for Mathutils! and bpy_internal_import.h, be very careful
 
-incs += ' #source/kernel/gen_system #intern/string #intern/guardedalloc'
+incs += ' #intern/string #intern/guardedalloc #intern/container'
 incs += ' #source/gameengine/Rasterizer/RAS_OpenGLRasterizer'
 incs += ' #intern/audaspace/intern #source/gameengine/Converter'
 incs += ' #source/gameengine/BlenderRoutines #source/blender/imbuf #intern/moto/include'
diff --git a/source/gameengine/Network/CMakeLists.txt b/source/gameengine/Network/CMakeLists.txt
index 6a2b5fe841e319a2fd1acc1e2ee2d4659465e226..7f4c7c357da478491150588c7127130ff8542ec4 100644
--- a/source/gameengine/Network/CMakeLists.txt
+++ b/source/gameengine/Network/CMakeLists.txt
@@ -26,8 +26,8 @@
 
 set(INC
 	.
-	../../../source/kernel/gen_system
 	../../../intern/string
+	../../../intern/container
 	../../../intern/moto/include
 )
 
diff --git a/source/gameengine/Network/LoopBackNetwork/CMakeLists.txt b/source/gameengine/Network/LoopBackNetwork/CMakeLists.txt
index 4cf43a1fc936260348e78a755054f0147f977330..d7b88304474b4c561e4c1a1efb4fb78c3078eb93 100644
--- a/source/gameengine/Network/LoopBackNetwork/CMakeLists.txt
+++ b/source/gameengine/Network/LoopBackNetwork/CMakeLists.txt
@@ -26,8 +26,8 @@
 
 set(INC
 	.
-	../../../../source/kernel/gen_system
 	../../../../intern/string
+	../../../../intern/container
 	../../../../source/gameengine/Network
 )
 
diff --git a/source/gameengine/Network/LoopBackNetwork/SConscript b/source/gameengine/Network/LoopBackNetwork/SConscript
index af76065cc945c0c3d348c40386ef1a7d0c13fa23..7ca0a64f7743ad428c05d5e0dd75ca8132774b16 100644
--- a/source/gameengine/Network/LoopBackNetwork/SConscript
+++ b/source/gameengine/Network/LoopBackNetwork/SConscript
@@ -3,6 +3,6 @@ Import ('env')
 
 sources = 'NG_LoopBackNetworkDeviceInterface.cpp'
 
-incs = '. #source/kernel/gen_system #intern/string #source/gameengine/Network'
+incs = '. #intern/string #intern/container #source/gameengine/Network'
 
 env.BlenderLib ( 'ge_logic_loopbacknetwork', Split(sources), Split(incs), defines=[],libtype=['core','player'], priority=[400,135] )
diff --git a/source/gameengine/Network/NG_NetworkScene.h b/source/gameengine/Network/NG_NetworkScene.h
index d390eabc46546709d9c1ed589374ceffa6dded50..ebe50d36b462878333aae9249965498697aaad03 100644
--- a/source/gameengine/Network/NG_NetworkScene.h
+++ b/source/gameengine/Network/NG_NetworkScene.h
@@ -34,7 +34,7 @@
 #ifndef __NG_NETWORKSCENE_H
 #define __NG_NETWORKSCENE_H
 
-#include "GEN_Map.h"
+#include "CTR_Map.h"
 #include "STR_HashedString.h"
 #include <vector>
 
@@ -52,10 +52,10 @@ class NG_NetworkDeviceInterface;
 class NG_NetworkScene
 {
 	class NG_NetworkDeviceInterface *m_networkdevice;	
-	GEN_Map<STR_HashedString, class NG_NetworkObject *> m_networkObjects;
+	CTR_Map<STR_HashedString, class NG_NetworkObject *> m_networkObjects;
 
-	// GEN_Maps used as a 'Bloom' filter
-	typedef GEN_Map<STR_HashedString, std::vector<class NG_NetworkMessage*>* > TMessageMap;
+	// CTR_Maps used as a 'Bloom' filter
+	typedef CTR_Map<STR_HashedString, std::vector<class NG_NetworkMessage*>* > TMessageMap;
 	TMessageMap m_messagesByDestinationName;
 	TMessageMap m_messagesBySenderName;
 	TMessageMap m_messagesBySubject;
diff --git a/source/gameengine/Network/SConscript b/source/gameengine/Network/SConscript
index 1b63592d0a43bd5553a77f71c76ccd92d7e9aabf..bbf714383b7a4736c6a61bc6bda10ae74a5e0a24 100644
--- a/source/gameengine/Network/SConscript
+++ b/source/gameengine/Network/SConscript
@@ -3,7 +3,7 @@ Import ('env')
 
 sources = env.Glob('*.cpp') #'NG_NetworkMessage.cpp NG_NetworkObject.cpp NG_NetworkScene.cpp'
 
-incs = '. #source/kernel/gen_system #intern/string #intern/moto/include'
+incs = '. #intern/string #intern/moto/include #intern/container'
 
 defs = []
 
diff --git a/source/gameengine/Physics/Bullet/CMakeLists.txt b/source/gameengine/Physics/Bullet/CMakeLists.txt
index cc469c3772a51aa8a20b0a1a48ec1390b626783f..a984d0436f0deb73d4f7d12cb96bca0d33801fb1 100644
--- a/source/gameengine/Physics/Bullet/CMakeLists.txt
+++ b/source/gameengine/Physics/Bullet/CMakeLists.txt
@@ -33,7 +33,7 @@ set(INC
 	../../../../extern/bullet2/src
 	../../../../intern/moto/include
 	../../../../intern/guardedalloc
-	../../../kernel/gen_system
+	../../../../intern/container
 	../../../../intern/string
 	../../Rasterizer
 	../../Ketsji
diff --git a/source/gameengine/Physics/Bullet/SConscript b/source/gameengine/Physics/Bullet/SConscript
index f8f0f8afaea9fef8adb80879034af7e2f4e4dfb8..ba4db0015330fd213c507c9bb13eadd6270a7b95 100644
--- a/source/gameengine/Physics/Bullet/SConscript
+++ b/source/gameengine/Physics/Bullet/SConscript
@@ -4,7 +4,6 @@ Import ('env')
 sources = 'CcdPhysicsEnvironment.cpp CcdPhysicsController.cpp CcdGraphicController.cpp'
 
 incs = '. ../common'
-incs += ' #source/kernel/gen_system'
 incs += ' #intern/string'
 incs += ' #intern/moto/include'
 incs += ' #extern/glew/include'
@@ -17,6 +16,7 @@ incs += ' #source/blender/makesdna'
 incs += ' #source/blender/blenkernel'
 incs += ' #source/blender/blenlib'
 incs += ' #intern/guardedalloc'
+incs += ' #intern/container'
 
 incs += ' ' + env['BF_BULLET_INC']
 
diff --git a/source/gameengine/Rasterizer/CMakeLists.txt b/source/gameengine/Rasterizer/CMakeLists.txt
index 7e2fda177d759c2cba70f81763e5ac8350a7f22f..2bfb3f8f328628e926b4e5cac850ef9821961630 100644
--- a/source/gameengine/Rasterizer/CMakeLists.txt
+++ b/source/gameengine/Rasterizer/CMakeLists.txt
@@ -26,11 +26,11 @@
 
 set(INC
 	.
-	../../../source/kernel/gen_system
 	../../../source/blender/makesdna
 	../../../source/gameengine/SceneGraph
 	../../../source/gameengine/Ketsji
 	../../../intern/string
+	../../../intern/container
 	../../../intern/moto/include
 	../../../intern/guardedalloc
 	../Expressions
diff --git a/source/gameengine/Rasterizer/RAS_BucketManager.cpp b/source/gameengine/Rasterizer/RAS_BucketManager.cpp
index 8c9f5e9786b0932abbc67a60910ed3017fc347a1..6316b1195889ac380579d54c3c1330f06d94b3ae 100644
--- a/source/gameengine/Rasterizer/RAS_BucketManager.cpp
+++ b/source/gameengine/Rasterizer/RAS_BucketManager.cpp
@@ -36,7 +36,7 @@
 #pragma warning (disable:4786)
 #endif
 
-#include "GEN_Map.h"
+#include "CTR_Map.h"
 #include "RAS_MaterialBucket.h"
 #include "STR_HashedString.h"
 #include "RAS_MeshObject.h"
diff --git a/source/gameengine/Rasterizer/RAS_BucketManager.h b/source/gameengine/Rasterizer/RAS_BucketManager.h
index 297782bd4feba2d8fc3bdd9a8e2589a45e7ee96f..8a9f21d5db7289bb9dc72294e7fd501343d61d6c 100644
--- a/source/gameengine/Rasterizer/RAS_BucketManager.h
+++ b/source/gameengine/Rasterizer/RAS_BucketManager.h
@@ -36,7 +36,7 @@
 
 #include "MT_Transform.h"
 #include "RAS_MaterialBucket.h"
-#include "GEN_Map.h"
+#include "CTR_Map.h"
 
 #include <vector>
 
diff --git a/source/gameengine/Rasterizer/RAS_Deformer.h b/source/gameengine/Rasterizer/RAS_Deformer.h
index 8678830f6a24150a4bcf3f196e36ef8a066df977..c7a32b38e0472c1b1bd0b89ad3462b011ec4f3ad 100644
--- a/source/gameengine/Rasterizer/RAS_Deformer.h
+++ b/source/gameengine/Rasterizer/RAS_Deformer.h
@@ -39,7 +39,7 @@
 #endif //WIN32
 
 #include <stdlib.h>
-#include "GEN_Map.h"
+#include "CTR_Map.h"
 
 #ifdef WITH_CXX_GUARDEDALLOC
 #include "MEM_guardedalloc.h"
@@ -53,7 +53,7 @@ class RAS_Deformer
 public:
 	RAS_Deformer() : m_pMesh(NULL), m_bDynamic(false) {};
 	virtual ~RAS_Deformer(){};
-	virtual void Relink(GEN_Map<class GEN_HashedPtr, void*>*map)=0;
+	virtual void Relink(CTR_Map<class CTR_HashedPtr, void*>*map)=0;
 	virtual bool Apply(class RAS_IPolyMaterial *polymat)=0;
 	virtual bool Update(void)=0;
 	virtual bool UpdateBuckets(void)=0;
diff --git a/source/gameengine/Rasterizer/RAS_MaterialBucket.h b/source/gameengine/Rasterizer/RAS_MaterialBucket.h
index c46a36768ee27c936466d6ccd1f25fe882853955..51c430dd57b42029c19c7639a22ce6c8166e0e4c 100644
--- a/source/gameengine/Rasterizer/RAS_MaterialBucket.h
+++ b/source/gameengine/Rasterizer/RAS_MaterialBucket.h
@@ -35,7 +35,7 @@
 #define __RAS_MATERIALBUCKET
 
 #include "RAS_TexVert.h"
-#include "GEN_Map.h"
+#include "CTR_Map.h"
 #include "STR_HashedString.h"
 #include "SG_QList.h"
 
@@ -193,7 +193,7 @@ class RAS_MeshMaterial
 public:
 	RAS_MeshSlot *m_baseslot;
 	class RAS_MaterialBucket *m_bucket;
-	GEN_Map<GEN_HashedPtr,RAS_MeshSlot*> m_slots;
+	CTR_Map<CTR_HashedPtr,RAS_MeshSlot*> m_slots;
 
 
 #ifdef WITH_CXX_GUARDEDALLOC
diff --git a/source/gameengine/Rasterizer/RAS_MeshObject.h b/source/gameengine/Rasterizer/RAS_MeshObject.h
index 0b35b212e1daf72ea41f1b1ed5b0a17e750ea265..555a290ba6f250b1ec4ec181f4a8dd6352a914ac 100644
--- a/source/gameengine/Rasterizer/RAS_MeshObject.h
+++ b/source/gameengine/Rasterizer/RAS_MeshObject.h
@@ -47,7 +47,7 @@
 #include "RAS_MaterialBucket.h"
 #include "MT_Transform.h"
 
-#include "GEN_HashedPtr.h"
+#include "CTR_HashedPtr.h"
 
 struct Mesh;
 class RAS_Deformer;
diff --git a/source/gameengine/Rasterizer/RAS_OpenGLRasterizer/CMakeLists.txt b/source/gameengine/Rasterizer/RAS_OpenGLRasterizer/CMakeLists.txt
index 7c1dd8a2de8566cce35b2996b994563c3cf0db4f..99068aa1bb8936784fbf3c9e5b513efad1118b99 100644
--- a/source/gameengine/Rasterizer/RAS_OpenGLRasterizer/CMakeLists.txt
+++ b/source/gameengine/Rasterizer/RAS_OpenGLRasterizer/CMakeLists.txt
@@ -25,12 +25,13 @@
 # ***** END GPL LICENSE BLOCK *****
 
 set(INC
-	../../../../source/kernel/gen_system
 	../../../../intern/string
+	../../../../intern/container
 	../../../../intern/moto/include
 	../../../../source/gameengine/Rasterizer
 	../../../../source/gameengine/Ketsji
 	../../../../source/gameengine/SceneGraph
+	../../../../source/gameengine/BlenderRoutines
 	../../../../source/blender/gpu
 	../../../../source/blender/makesdna
 	../../../../source/blender/blenkernel
diff --git a/source/gameengine/Rasterizer/RAS_OpenGLRasterizer/SConscript b/source/gameengine/Rasterizer/RAS_OpenGLRasterizer/SConscript
index 890d1efb85090e6e960d77de46a06b7f9f66b368..5f3af7360ff41f66aefba58c263c1d8d342052ad 100644
--- a/source/gameengine/Rasterizer/RAS_OpenGLRasterizer/SConscript
+++ b/source/gameengine/Rasterizer/RAS_OpenGLRasterizer/SConscript
@@ -5,10 +5,10 @@ sources = env.Glob('*.cpp')
 
 defs = [ 'GLEW_STATIC' ]
 
-incs = '. #source/kernel/gen_system #intern/string #intern/moto/include #source/gameengine/Rasterizer #source/gameengine/BlenderRoutines '
-incs += ' #source/blender/gpu #extern/glew/include ' + env['BF_OPENGL_INC']
+incs = '. #intern/string #intern/moto/include #source/gameengine/Rasterizer #source/gameengine/BlenderRoutines '
+incs += ' #intern/container #source/blender/gpu #extern/glew/include ' + env['BF_OPENGL_INC']
 incs += ' #source/blender/gameengine/Ketsji #source/gameengine/SceneGraph #source/blender/makesdna #source/blender/blenkernel'
-incs += ' #intern/guardedalloc #source/blender/blenlib'
+incs += ' #intern/guardedalloc #source/blender/blenlib #source/gameengine/BlenderRoutines'
 
 if env['WITH_BF_CXX_GUARDEDALLOC']:
     defs.append('WITH_CXX_GUARDEDALLOC')
diff --git a/source/gameengine/Rasterizer/SConscript b/source/gameengine/Rasterizer/SConscript
index bff2a7e2084fe95296d319be3551418801b75865..4164271ba9b87c2dcadf2fd33df0d7cfda156d1e 100644
--- a/source/gameengine/Rasterizer/SConscript
+++ b/source/gameengine/Rasterizer/SConscript
@@ -4,7 +4,7 @@ Import ('env')
 sources = env.Glob('*.cpp')
 
 
-incs = '. #intern/guardedalloc #source/kernel/gen_system #intern/string #intern/moto/include #source/gameengine/BlenderRoutines #extern/glew/include #source/gameengine/Expressions #source/gameengine/SceneGraph #source/blender/blenkernel #source/blender/makesdna'
+incs = '. #intern/guardedalloc #intern/string #intern/moto/include #intern/container #source/gameengine/BlenderRoutines #extern/glew/include #source/gameengine/Expressions #source/gameengine/SceneGraph #source/blender/blenkernel #source/blender/makesdna'
 
 defs = [ 'GLEW_STATIC' ]
 
diff --git a/source/gameengine/VideoTexture/CMakeLists.txt b/source/gameengine/VideoTexture/CMakeLists.txt
index aae57fce679019a91463280023769c0037badb41..fb10b619f178e2a412fbfc5ecab03db0c7634cdc 100644
--- a/source/gameengine/VideoTexture/CMakeLists.txt
+++ b/source/gameengine/VideoTexture/CMakeLists.txt
@@ -41,7 +41,7 @@ set(INC
 	../../../source/blender/python
 	../../../source/blender/python/generic
 	../../../source/blender/gpu
-	../../../source/kernel/gen_system
+	../../../intern/container
 	../../../intern/string
 	../../../intern/moto/include
 	../../../intern/guardedalloc
diff --git a/source/gameengine/VideoTexture/SConscript b/source/gameengine/VideoTexture/SConscript
index 2cd143d2deb1630cbbf61cddcd68393573db543b..5091082e87a988947bbf2a0881a640e33df972b9 100644
--- a/source/gameengine/VideoTexture/SConscript
+++ b/source/gameengine/VideoTexture/SConscript
@@ -11,8 +11,8 @@ incs += ' #source/gameengine/Rasterizer/RAS_OpenGLRasterizer'
 incs += ' #source/gameengine/BlenderRoutines'
 incs += ' #source/blender/editors/include #source/blender/blenlib #source/blender/blenkernel'
 incs += ' #source/blender/makesdna #source/blender/imbuf #source/blender/python #source/blender/python/generic'
-incs += ' #source/blender/gpu #source/kernel/gen_system #intern/string #intern/moto/include'
-incs += ' #intern/guardedalloc #extern/glew/include'
+incs += ' #source/blender/gpu #intern/string #intern/moto/include'
+incs += ' #intern/guardedalloc #intern/container #extern/glew/include'
 
 defs = [] 
 if env['OURPLATFORM'] in ('win32-vc', 'win64-vc','win32-mingw'):
diff --git a/source/kernel/CMakeLists.txt b/source/kernel/CMakeLists.txt
deleted file mode 100644
index bcf967cff122b4d770575bdae96d8c3c4fbcdd85..0000000000000000000000000000000000000000
--- a/source/kernel/CMakeLists.txt
+++ /dev/null
@@ -1,48 +0,0 @@
-# $Id$
-# ***** BEGIN GPL LICENSE BLOCK *****
-#
-# This program is free software; you can redistribute it and/or
-# modify it under the terms of the GNU General Public License
-# as published by the Free Software Foundation; either version 2
-# of the License, or (at your option) any later version.
-#
-# This program is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
-# GNU General Public License for more details.
-#
-# You should have received a copy of the GNU General Public License
-# along with this program; if not, write to the Free Software Foundation,
-# Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
-#
-# The Original Code is Copyright (C) 2006, Blender Foundation
-# All rights reserved.
-#
-# The Original Code is: all of this file.
-#
-# Contributor(s): Jacques Beaurain.
-#
-# ***** END GPL LICENSE BLOCK *****
-
-set(INC
-	gen_messaging
-	gen_system
-	../../intern/string
-	../../intern/moto/include
-	../../source/blender/blenloader
-)
-
-set(SRC
-	gen_messaging/intern/messaging.c
-	gen_system/GEN_HashedPtr.cpp
-	gen_system/SYS_SingletonSystem.cpp
-	gen_system/SYS_System.cpp
-
-	gen_messaging/GEN_messaging.h
-	gen_system/GEN_HashedPtr.h
-	gen_system/GEN_Map.h
-	gen_system/SYS_SingletonSystem.h
-	gen_system/SYS_System.h
-)
-
-blender_add_lib(bf_gen_system "${SRC}" "${INC}")
diff --git a/source/kernel/SConscript b/source/kernel/SConscript
deleted file mode 100644
index 8dd0fd36e8a8b55e3b484f3c4b10ec232df77eda..0000000000000000000000000000000000000000
--- a/source/kernel/SConscript
+++ /dev/null
@@ -1,10 +0,0 @@
-#!/usr/bin/python
-Import ('env')
-
-sources = 'gen_messaging/intern/messaging.c gen_system/GEN_HashedPtr.cpp'
-sources += ' gen_system/SYS_SingletonSystem.cpp'
-sources += ' gen_system/SYS_System.cpp'
-
-incs = 'gen_messaging gen_system #/intern/string #/intern/moto/include #/source/blender/blenloader '
-
-env.BlenderLib ( 'bf_gen_system', Split(sources), Split(incs), [], libtype = ['core','player'], priority = [400,100] )
diff --git a/source/kernel/gen_messaging/GEN_messaging.h b/source/kernel/gen_messaging/GEN_messaging.h
deleted file mode 100644
index 866716f391444690ae6997618ab51edf49fba9a4..0000000000000000000000000000000000000000
--- a/source/kernel/gen_messaging/GEN_messaging.h
+++ /dev/null
@@ -1,63 +0,0 @@
-/*
- * $Id$
- *
- * ***** BEGIN GPL LICENSE BLOCK *****
- *
- * This program is free software; you can redistribute it and/or
- * modify it under the terms of the GNU General Public License
- * as published by the Free Software Foundation; either version 2
- * of the License, or (at your option) any later version.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
- *
- * The Original Code is Copyright (C) 2001-2002 by NaN Holding BV.
- * All rights reserved.
- *
- * The Original Code is: all of this file.
- *
- * Contributor(s): none yet.
- *
- * ***** END GPL LICENSE BLOCK *****
- */
-
-/** \file kernel/gen_messaging/GEN_messaging.h
- *  \ingroup genmess
- */
-
-#ifndef GEN_MESSAGING_H
-#define GEN_MESSAGING_H
-
-#include <stdio.h>
-
-#ifdef __cplusplus
-extern "C" {
-#endif
-
-	/**
-	 * Stream for error messages.
-	 */
-	extern FILE* GEN_errorstream;
-
-	/**
-	 * Stream for notices to the user.
-	 */
-	extern FILE* GEN_userstream;
-
-	/**
-	 * Initialise the messaging system. If the system is not
-	 * initialised, the streams cannot be used. */
-	void GEN_init_messaging_system(void);
-	
-#ifdef __cplusplus
-}
-#endif
-
-#endif /* GEN_MESSAGING_H */
-
diff --git a/source/kernel/gen_messaging/intern/messaging.c b/source/kernel/gen_messaging/intern/messaging.c
deleted file mode 100644
index 93e6deac089c6d6377797747cd827ea91f9dda36..0000000000000000000000000000000000000000
--- a/source/kernel/gen_messaging/intern/messaging.c
+++ /dev/null
@@ -1,46 +0,0 @@
-/*
- * $Id$
- *
- * ***** BEGIN GPL LICENSE BLOCK *****
- *
- * This program is free software; you can redistribute it and/or
- * modify it under the terms of the GNU General Public License
- * as published by the Free Software Foundation; either version 2
- * of the License, or (at your option) any later version.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
- *
- * The Original Code is Copyright (C) 2001-2002 by NaN Holding BV.
- * All rights reserved.
- *
- * The Original Code is: all of this file.
- *
- * Contributor(s): none yet.
- *
- * ***** END GPL LICENSE BLOCK *****
- * A message and error sink for c and c++
- */
-
-/** \file kernel/gen_messaging/intern/messaging.c
- *  \ingroup genmess
- */
-
-
-
-#include "GEN_messaging.h"
-
-FILE* GEN_errorstream = NULL;
-FILE* GEN_userstream  = NULL;
-
-void GEN_init_messaging_system(void)
-{
-	GEN_errorstream = stderr;
-	GEN_userstream  = stdout;
-}
diff --git a/source/kernel/gen_system/GEN_HashedPtr.cpp b/source/kernel/gen_system/GEN_HashedPtr.cpp
deleted file mode 100644
index f065d27bee23be390414876306b68886ecc4f3d2..0000000000000000000000000000000000000000
--- a/source/kernel/gen_system/GEN_HashedPtr.cpp
+++ /dev/null
@@ -1,62 +0,0 @@
-/*
- * $Id$
- *
- * ***** BEGIN GPL LICENSE BLOCK *****
- *
- * This program is free software; you can redistribute it and/or
- * modify it under the terms of the GNU General Public License
- * as published by the Free Software Foundation; either version 2
- * of the License, or (at your option) any later version.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
- *
- * The Original Code is Copyright (C) 2001-2002 by NaN Holding BV.
- * All rights reserved.
- *
- * The Original Code is: all of this file.
- *
- * Contributor(s): none yet.
- *
- * ***** END GPL LICENSE BLOCK *****
- *
- */
-
-/** \file kernel/gen_system/GEN_HashedPtr.cpp
- *  \ingroup gensys
- */
-
-#include "GEN_HashedPtr.h"
-
-#include "BLO_sys_types.h" // for intptr_t support
-
-//
-// Build hash index from pointer.  Even though the final result
-// is a 32-bit integer, use all the bits of the pointer as long
-// as possible.
-//
-#if 1
-unsigned int GEN_Hash(void * inDWord)
-{
-	uintptr_t key = (uintptr_t)inDWord;
-#if 0
-	// this is way too complicated
-	key += ~(key << 16);
-	key ^=  (key >>  5);
-	key +=  (key <<  3);
-	key ^=  (key >> 13);
-	key += ~(key <<  9);
-	key ^=  (key >> 17);
-
-  	return (unsigned int)(key & 0xffffffff);
-#else
-	return (unsigned int)(key ^ (key>>4));
-#endif
-}
-#endif
diff --git a/source/kernel/gen_system/GEN_Map.h b/source/kernel/gen_system/GEN_Map.h
deleted file mode 100644
index 4ac5a10c4c6b4cc76388594645e82c24bd56344d..0000000000000000000000000000000000000000
--- a/source/kernel/gen_system/GEN_Map.h
+++ /dev/null
@@ -1,183 +0,0 @@
-/*
- * $Id$
- *
- * ***** BEGIN GPL LICENSE BLOCK *****
- *
- * This program is free software; you can redistribute it and/or
- * modify it under the terms of the GNU General Public License
- * as published by the Free Software Foundation; either version 2
- * of the License, or (at your option) any later version.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
- *
- * The Original Code is Copyright (C) 2001-2002 by NaN Holding BV.
- * All rights reserved.
- *
- * The Original Code is: all of this file.
- *
- * Contributor(s): none yet.
- *
- * ***** END GPL LICENSE BLOCK *****
- */
-
-/** \file kernel/gen_system/GEN_Map.h
- *  \ingroup gensys
- */
-
-#ifndef GEN_MAP_H
-#define GEN_MAP_H
-
-template <class Key, class Value>
-class GEN_Map {
-private:
-    struct Entry {
-        Entry (Entry *next, Key key, Value value) :
-            m_next(next),
-            m_key(key),
-            m_value(value) {}
-
-        Entry *m_next;
-        Key    m_key;
-        Value  m_value;
-    };
- 
-public:
-    GEN_Map(int num_buckets = 100) : m_num_buckets(num_buckets) {
-        m_buckets = new Entry *[num_buckets];
-        for (int i = 0; i < num_buckets; ++i) {
-            m_buckets[i] = 0;
-        }
-    }
-
-	GEN_Map(const GEN_Map& map)
-	{
-		m_num_buckets = map.m_num_buckets;
-		m_buckets = new Entry *[m_num_buckets];
-
-		for (int i = 0; i < m_num_buckets; ++i) {
-			m_buckets[i] = 0;
-
-			for(Entry *entry = map.m_buckets[i]; entry; entry=entry->m_next)
-				insert(entry->m_key, entry->m_value);
-		}
-	}
-    
-    int size() { 
-        int count=0;
-        for (int i=0;i<m_num_buckets;i++)
-        {
-            Entry* bucket = m_buckets[i];
-            while(bucket)
-            {
-                bucket = bucket->m_next;
-                count++;
-            }
-        }
-        return count;
-    }
-    
-    Value* at(int index) {
-        int count=0;
-        for (int i=0;i<m_num_buckets;i++)
-        {
-            Entry* bucket = m_buckets[i];
-            while(bucket)
-            {
-                if (count==index)
-                {
-                    return &bucket->m_value;
-                }
-                bucket = bucket->m_next;
-                count++;
-            }
-        }
-        return 0;
-    }
-
-    Key* getKey(int index) {
-        int count=0;
-        for (int i=0;i<m_num_buckets;i++)
-        {
-            Entry* bucket = m_buckets[i];
-            while(bucket)
-            {
-                if (count==index)
-                {
-                    return &bucket->m_key;
-                }
-                bucket = bucket->m_next;
-                count++;
-            }
-        }
-        return 0;
-    }
-    
-    void clear() {
-        for (int i = 0; i < m_num_buckets; ++i) {
-            Entry *entry_ptr = m_buckets[i];
-            
-            while (entry_ptr != 0) {
-                Entry *tmp_ptr = entry_ptr->m_next;
-                delete entry_ptr;
-                entry_ptr = tmp_ptr;
-            }
-            m_buckets[i] = 0;
-        }
-    }
-    
-    ~GEN_Map() {
-        clear();
-        delete [] m_buckets;
-    }
-    
-    void insert(const Key& key, const Value& value) {
-        Entry *entry_ptr = m_buckets[key.hash() % m_num_buckets];
-        while ((entry_ptr != 0) && !(key == entry_ptr->m_key)) {
-            entry_ptr = entry_ptr->m_next;
-        }
-        
-        if (entry_ptr != 0) {
-            entry_ptr->m_value = value;
-        }
-        else {
-            Entry **bucket = &m_buckets[key.hash() % m_num_buckets];
-            *bucket = new Entry(*bucket, key, value);
-        }
-    }
-
-    void remove(const Key& key) {
-        Entry **entry_ptr = &m_buckets[key.hash() % m_num_buckets];
-        while ((*entry_ptr != 0) && !(key == (*entry_ptr)->m_key)) {
-            entry_ptr = &(*entry_ptr)->m_next;
-        }
-        
-        if (*entry_ptr != 0) {
-            Entry *tmp_ptr = (*entry_ptr)->m_next;
-            delete *entry_ptr;
-            *entry_ptr = tmp_ptr;
-        }
-    }
-
-    Value *operator[](Key key) {
-        Entry *bucket = m_buckets[key.hash() % m_num_buckets];
-        while ((bucket != 0) && !(key == bucket->m_key)) {
-            bucket = bucket->m_next;
-        }
-        return bucket != 0 ? &bucket->m_value : 0;
-    }
-    
-private:
-    int     m_num_buckets;
-    Entry **m_buckets;
-};
-
-#endif
-
-
diff --git a/source/kernel/gen_system/SYS_SingletonSystem.cpp b/source/kernel/gen_system/SYS_SingletonSystem.cpp
deleted file mode 100644
index 08ee186c7238cb1558d830ddb701c1a9b12de0a4..0000000000000000000000000000000000000000
--- a/source/kernel/gen_system/SYS_SingletonSystem.cpp
+++ /dev/null
@@ -1,101 +0,0 @@
-/*
- * $Id$
- *
- * ***** BEGIN GPL LICENSE BLOCK *****
- *
- * This program is free software; you can redistribute it and/or
- * modify it under the terms of the GNU General Public License
- * as published by the Free Software Foundation; either version 2
- * of the License, or (at your option) any later version.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
- *
- * The Original Code is Copyright (C) 2001-2002 by NaN Holding BV.
- * All rights reserved.
- *
- * The Original Code is: all of this file.
- *
- * Contributor(s): none yet.
- *
- * ***** END GPL LICENSE BLOCK *****
- * Unique instance of system class for system specific information / access
- * Used by SYS_System
- */
-
-/** \file kernel/gen_system/SYS_SingletonSystem.cpp
- *  \ingroup gensys
- */
-
-#include "SYS_SingletonSystem.h"
-// #include "GEN_DataCache.h"
-
-SYS_SingletonSystem*	SYS_SingletonSystem::_instance = 0;
-
-void SYS_SingletonSystem::Destruct()
-{
-	if (_instance) {
-		delete _instance;
-		_instance = NULL;
-	}
-}
-
-SYS_SingletonSystem *SYS_SingletonSystem::Instance()
-{
-	if (!_instance) {
-		_instance = new SYS_SingletonSystem();
-	}
-	return _instance;
-}
-
-int SYS_SingletonSystem::SYS_GetCommandLineInt(const char *paramname, int defaultvalue)
-{
-	int *result = m_int_commandlineparms[paramname];
-	if (result)
-		return *result;
-
-	return defaultvalue;
-}
-
-float SYS_SingletonSystem::SYS_GetCommandLineFloat(const char *paramname, float defaultvalue)
-{
-	float *result = m_float_commandlineparms[paramname];
-	if (result)
-		return *result;
-
-	return defaultvalue;
-}
-
-const char *SYS_SingletonSystem::SYS_GetCommandLineString(const char *paramname, const char *defaultvalue)
-{
-	STR_String *result = m_string_commandlineparms[paramname];
-	if (result)
-		return *result;
-
-	return defaultvalue;
-}
-
-void SYS_SingletonSystem::SYS_WriteCommandLineInt(const char *paramname, int value)
-{
-	m_int_commandlineparms.insert(paramname, value);
-}
-
-void SYS_SingletonSystem::SYS_WriteCommandLineFloat(const char *paramname, float value)
-{
-	m_float_commandlineparms.insert(paramname, value);
-}
-
-void SYS_SingletonSystem::SYS_WriteCommandLineString(const char *paramname, const char *value)
-{
-	m_string_commandlineparms.insert(paramname, value);
-}
-
-SYS_SingletonSystem::SYS_SingletonSystem()
-{
-}
diff --git a/source/kernel/gen_system/SYS_SingletonSystem.h b/source/kernel/gen_system/SYS_SingletonSystem.h
deleted file mode 100644
index d8628558618aa56a7f66a02eee971b96b0e5e6b6..0000000000000000000000000000000000000000
--- a/source/kernel/gen_system/SYS_SingletonSystem.h
+++ /dev/null
@@ -1,66 +0,0 @@
-/*
- * $Id$
- *
- * ***** BEGIN GPL LICENSE BLOCK *****
- *
- * This program is free software; you can redistribute it and/or
- * modify it under the terms of the GNU General Public License
- * as published by the Free Software Foundation; either version 2
- * of the License, or (at your option) any later version.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
- *
- * The Original Code is Copyright (C) 2001-2002 by NaN Holding BV.
- * All rights reserved.
- *
- * The Original Code is: all of this file.
- *
- * Contributor(s): none yet.
- *
- * ***** END GPL LICENSE BLOCK *****
- * Unique instance of system class for system specific information / access
- * Used by SYS_System
- */
-
-/** \file kernel/gen_system/SYS_SingletonSystem.h
- *  \ingroup gensys
- */
-
-#ifndef __SINGLETONSYSTEM_H
-#define __SINGLETONSYSTEM_H
-
-#include "GEN_Map.h"
-#include "STR_HashedString.h"
-
-class SYS_SingletonSystem
-{
-public:
-	static		SYS_SingletonSystem*	Instance();
-	static		void	Destruct();
-
-	int		SYS_GetCommandLineInt(const char* paramname,int defaultvalue);
-	float		SYS_GetCommandLineFloat(const char* paramname,float defaultvalue);
-	const char*	SYS_GetCommandLineString(const char* paramname,const char* defaultvalue);
-
-	void		SYS_WriteCommandLineInt(const char* paramname,int value);
-	void		SYS_WriteCommandLineFloat(const char* paramname,float value);
-	void		SYS_WriteCommandLineString(const char* paramname,const char* value);
-
-	SYS_SingletonSystem();
-
-private:
-	static SYS_SingletonSystem*	_instance;
-	GEN_Map<STR_HashedString,int>	m_int_commandlineparms;
-	GEN_Map<STR_HashedString,float>	m_float_commandlineparms;
-	GEN_Map<STR_HashedString,STR_String>	m_string_commandlineparms;
-};
-
-#endif //__SINGLETONSYSTEM_H
-