diff --git a/etk/archive/Archive.cpp b/archive/etk-archive/Archive.cpp similarity index 100% rename from etk/archive/Archive.cpp rename to archive/etk-archive/Archive.cpp diff --git a/etk/archive/Archive.h b/archive/etk-archive/Archive.h similarity index 100% rename from etk/archive/Archive.h rename to archive/etk-archive/Archive.h diff --git a/etk/archive/Zip.cpp b/archive/etk-archive/Zip.cpp similarity index 100% rename from etk/archive/Zip.cpp rename to archive/etk-archive/Zip.cpp diff --git a/etk/archive/Zip.h b/archive/etk-archive/Zip.h similarity index 100% rename from etk/archive/Zip.h rename to archive/etk-archive/Zip.h diff --git a/archive/lutin_etk-archive.py b/archive/lutin_etk-archive.py new file mode 100644 index 0000000..9347d92 --- /dev/null +++ b/archive/lutin_etk-archive.py @@ -0,0 +1,27 @@ +#!/usr/bin/python +import lutin.module as module +import lutin.tools as tools + +def get_desc(): + return "Zip file access" + +def get_license(): + return "APACHE v2.0" + + +def create(target): + # module name is 'edn' and type binary. + myModule = module.Module(__file__, 'etk-archive', 'LIBRARY') + # add extra compilation flags : + myModule.add_extra_compile_flags() + # add the file to compile: + myModule.add_src_file([ + 'etk-archive/Archive.cpp', + 'etk-archive/Zip.cpp' + ]) + myModule.add_module_depend(["etk-base"]) + myModule.add_optionnal_module_depend('minizip', ["c++", "-DETK_BUILD_MINIZIP"]) + myModule.add_export_path(tools.get_current_path(__file__)) + return myModule + + diff --git a/etk/os/Fifo.h b/base/etk/Fifo.h similarity index 100% rename from etk/os/Fifo.h rename to base/etk/Fifo.h diff --git a/etk/Hash.h b/base/etk/Hash.h similarity index 100% rename from etk/Hash.h rename to base/etk/Hash.h diff --git a/etk/Noise.cpp b/base/etk/Noise.cpp similarity index 100% rename from etk/Noise.cpp rename to base/etk/Noise.cpp diff --git a/etk/Noise.h b/base/etk/Noise.h similarity index 100% rename from etk/Noise.h rename to base/etk/Noise.h diff --git a/etk/debug.cpp b/base/etk/debug.cpp similarity index 100% rename from etk/debug.cpp rename to base/etk/debug.cpp diff --git a/etk/debug.h b/base/etk/debug.h similarity index 100% rename from etk/debug.h rename to base/etk/debug.h diff --git a/etk/stdTools.cpp b/base/etk/stdTools.cpp similarity index 100% rename from etk/stdTools.cpp rename to base/etk/stdTools.cpp diff --git a/etk/stdTools.h b/base/etk/stdTools.h similarity index 100% rename from etk/stdTools.h rename to base/etk/stdTools.h diff --git a/etk/thread/tools.cpp b/base/etk/thread/tools.cpp similarity index 100% rename from etk/thread/tools.cpp rename to base/etk/thread/tools.cpp diff --git a/etk/thread/tools.h b/base/etk/thread/tools.h similarity index 100% rename from etk/thread/tools.h rename to base/etk/thread/tools.h diff --git a/etk/tool.cpp b/base/etk/tool.cpp similarity index 100% rename from etk/tool.cpp rename to base/etk/tool.cpp diff --git a/etk/tool.h b/base/etk/tool.h similarity index 100% rename from etk/tool.h rename to base/etk/tool.h diff --git a/etk/types.h b/base/etk/types.h similarity index 100% rename from etk/types.h rename to base/etk/types.h diff --git a/base/lutin_etk-base.py b/base/lutin_etk-base.py new file mode 100644 index 0000000..4f38034 --- /dev/null +++ b/base/lutin_etk-base.py @@ -0,0 +1,56 @@ +#!/usr/bin/python +import lutin.module as module +import lutin.tools as tools + +def get_desc(): + return "etk basis" + +def get_license(): + return "APACHE v2.0" + + +def create(target): + myModule = module.Module(__file__, 'etk-base', 'LIBRARY') + myModule.add_extra_compile_flags() + myModule.add_src_file([ + 'etk/debug.cpp', + 'etk/stdTools.cpp', + 'etk/tool.cpp', + 'etk/Noise.cpp', + 'etk/thread/tools.cpp' + ]) + + myModule.add_module_depend(["etk-log"]) + + if target.config["mode"] == "release": + myModule.compile_flags('c', "-DMODE_RELEASE") + else: + myModule.add_export_flag('c', "-DDEBUG_LEVEL=3") + myModule.add_export_flag('c', "-DDEBUG=1") + # Bor backtrace display : + if target.name != "Windows": + myModule.add_export_flag('link', "-ldl -rdynamic") + + # for ald C++ compatibility (old GCC) just link with boost ... + if target.config["compilator"] == "gcc" \ + and target.xx_version < 4007000: + # note : this framework depend on C++ 11, but a simple port of Boost for old compatibility has been done ... + myModule.compile_version_XX(1999) + myModule.add_optionnal_module_depend('boost', ["c++", "-DETK_BUILD_BOOST"], export=True) + myModule.add_export_path(tools.get_current_path(__file__) + "/binding_boost") + else: + myModule.compile_version_XX(2011) + # name of the dependency + myModule.add_export_path(tools.get_current_path(__file__) + "/binding_X11") + + if target.name=="Windows": + pass + elif target.name=="Android": + pass + else: + myModule.add_export_flag('link', "-lpthread") + + myModule.add_export_path(tools.get_current_path(__file__)) + return myModule + + diff --git a/color/lutin_etk-color.py b/color/lutin_etk-color.py new file mode 100644 index 0000000..f36d4bb --- /dev/null +++ b/color/lutin_etk-color.py @@ -0,0 +1,23 @@ +#!/usr/bin/python +import lutin.module as module +import lutin.tools as tools + +def get_desc(): + return "etk color interface" + +def get_license(): + return "APACHE v2.0" + + +def create(target): + myModule = module.Module(__file__, 'etk-color', 'LIBRARY') + myModule.add_extra_compile_flags() + myModule.add_src_file([ + "etk-color/Color.cpp" + ]) + + myModule.add_module_depend(["etk-base"]) + myModule.add_export_path(tools.get_current_path(__file__)) + return myModule + + diff --git a/file/etk-file/FSNode.cpp b/file/etk-file/Node.cpp similarity index 100% rename from file/etk-file/FSNode.cpp rename to file/etk-file/Node.cpp diff --git a/file/etk-file/FSNode.h b/file/etk-file/Node.h similarity index 100% rename from file/etk-file/FSNode.h rename to file/etk-file/Node.h diff --git a/file/etk-file/FSNodeRight.cpp b/file/etk-file/Right.cpp similarity index 100% rename from file/etk-file/FSNodeRight.cpp rename to file/etk-file/Right.cpp diff --git a/file/etk-file/FSNodeRight.h b/file/etk-file/Right.h similarity index 100% rename from file/etk-file/FSNodeRight.h rename to file/etk-file/Right.h diff --git a/file/lutin_etk-file.py b/file/lutin_etk-file.py index e69de29..eb8767f 100644 --- a/file/lutin_etk-file.py +++ b/file/lutin_etk-file.py @@ -0,0 +1,24 @@ +#!/usr/bin/python +import lutin.module as module +import lutin.tools as tools + +def get_desc(): + return "etk file interface" + +def get_license(): + return "APACHE v2.0" + + +def create(target): + myModule = module.Module(__file__, 'etk-file', 'LIBRARY') + myModule.add_extra_compile_flags() + myModule.add_src_file([ + "etk-file/Node.cpp", + "etk-file/Right.cpp" + ]) + + myModule.add_module_depend(["etk-base", "etk-archive"]) + myModule.add_export_path(tools.get_current_path(__file__)) + return myModule + + diff --git a/log/etk-log/log.cpp b/log/etk/log.cpp similarity index 100% rename from log/etk-log/log.cpp rename to log/etk/log.cpp diff --git a/log/etk-log/log.h b/log/etk/log.h similarity index 100% rename from log/etk-log/log.h rename to log/etk/log.h diff --git a/log/etk-log/logIOs.h b/log/etk/logIOs.h similarity index 100% rename from log/etk-log/logIOs.h rename to log/etk/logIOs.h diff --git a/log/etk-log/logIOs.m b/log/etk/logIOs.m similarity index 100% rename from log/etk-log/logIOs.m rename to log/etk/logIOs.m diff --git a/log/lutin_etk-log.py b/log/lutin_etk-log.py index e69de29..e2d7eac 100644 --- a/log/lutin_etk-log.py +++ b/log/lutin_etk-log.py @@ -0,0 +1,21 @@ +#!/usr/bin/python +import lutin.module as module +import lutin.tools as tools + +def get_desc(): + return "etk Log interface" + +def get_license(): + return "APACHE v2.0" + +def create(target): + myModule = module.Module(__file__, 'etk-log', 'LIBRARY') + myModule.add_extra_compile_flags() + myModule.add_src_file([ + "etk/log.cpp" + ]) + if target.name=="IOs": + myModule.add_src_file('etk/logIOs.m') + #myModule.add_module_depend(["etk-base"]) + myModule.add_export_path(tools.get_current_path(__file__)) + return myModule diff --git a/lutin_etk-test.py b/lutin_etk-test.py index 5102825..ae7cb9a 100644 --- a/lutin_etk-test.py +++ b/lutin_etk-test.py @@ -6,19 +6,13 @@ import datetime def get_desc(): return "e-tk test software" +def get_license(): + return "APACHE v2.0" def create(target): - # module name is 'edn' and type binary. myModule = module.Module(__file__, 'etk-test', 'BINARY') - - # add the file to compile: myModule.add_src_file([ 'test/main.cpp']) - myModule.add_module_depend(['etk', 'gtest']) - - #myModule.compile_flags_XX(["-nostdinc++"]); - - # add the currrent module at the system return myModule diff --git a/lutin_etk.py b/lutin_etk.py index 83543ab..ede7888 100644 --- a/lutin_etk.py +++ b/lutin_etk.py @@ -7,68 +7,20 @@ def get_desc(): def create(target): - # module name is 'edn' and type binary. myModule = module.Module(__file__, 'etk', 'LIBRARY') - # add extra compilation flags : myModule.add_extra_compile_flags() - # add the file to compile: myModule.add_src_file([ - 'etk/debug.cpp', - 'etk/etk.cpp', - 'etk/stdTools.cpp', - 'etk/log.cpp', - 'etk/tool.cpp', - 'etk/Noise.cpp', - 'etk/Color.cpp', - 'etk/thread/tools.cpp', - 'etk/math/Matrix4.cpp', - 'etk/math/Vector2D.cpp', - 'etk/math/Vector3D.cpp', - 'etk/math/Vector4D.cpp', - 'etk/os/FSNode.cpp', - 'etk/os/FSNodeRight.cpp', - 'etk/archive/Archive.cpp', - 'etk/archive/Zip.cpp']) - - if target.name=="IOs": - myModule.add_src_file('etk/logIOs.m') - - - if target.config["mode"] == "release": - # TODO : The other way is to remove this ... - # TODO : Fore release mode : the etk folder are absolutly not at the same position in the tree ... - myModule.compile_flags('c', "-DMODE_RELEASE") - else: - myModule.add_export_flag('c', "-DDEBUG_LEVEL=3") - myModule.add_export_flag('c', "-DDEBUG=1") - # Bor backtrace display : - if target.name != "Windows": - myModule.add_export_flag('link', "-ldl -rdynamic") - - # for ald C++ compatibility (old GCC) just link with boost ... - if target.config["compilator"] == "gcc" \ - and target.xx_version < 4007000: - # note : this framework depend on C++ 11, but a simple port of Boost for old compatibility has been done ... - myModule.compile_version_XX(1999) - myModule.add_optionnal_module_depend('boost', ["c++", "-DETK_BUILD_BOOST"], export=True) - myModule.add_export_path(tools.get_current_path(__file__) + "/binding_boost") - else: - myModule.compile_version_XX(2011) - # name of the dependency - myModule.add_optionnal_module_depend('minizip', ["c++", "-DETK_BUILD_MINIZIP"]) - myModule.add_optionnal_module_depend('linearmath', ["c", "-DETK_BUILD_LINEARMATH"], export=True) - myModule.add_export_path(tools.get_current_path(__file__) + "/binding_X11") - - if target.name=="Windows": - pass - elif target.name=="Android": - pass - else: - myModule.add_export_flag('link', "-lpthread") - + 'etk/etk.cpp' + ]) + myModule.add_module_depend([ + 'etk-archive', + 'etk-base', + 'etk-color', + 'etk-file', + 'etk-log', + 'etk-math', + 'etk-time']) myModule.add_export_path(tools.get_current_path(__file__)) - - # add the currrent module at the return myModule diff --git a/math/lutin_etk-math.py b/math/lutin_etk-math.py index b4345c3..2b5296f 100644 --- a/math/lutin_etk-math.py +++ b/math/lutin_etk-math.py @@ -5,22 +5,22 @@ import lutin.tools as tools def get_desc(): return "e-tk : Ewol tool kit" +def get_license(): + return "APACHE v2.0" def create(target): - # module name is 'edn' and type binary. myModule = module.Module(__file__, 'etk-math', 'LIBRARY') - # add extra compilation flags : myModule.add_extra_compile_flags() - # add the file to compile: myModule.add_src_file([ 'etk-math/Matrix4.cpp', 'etk-math/Vector2D.cpp', 'etk-math/Vector3D.cpp', 'etk-math/Vector4D.cpp' ]) + myModule.add_module_depend(["etk-base"]) + # atomaticly wrap on the bullet lib interface (simplify interface) + myModule.add_optionnal_module_depend('linearmath', ["c", "-DETK_BUILD_LINEARMATH"], export=True) myModule.add_export_path(tools.get_current_path(__file__)) - - # add the currrent module at the return myModule diff --git a/time/lutin_etk-time.py b/time/lutin_etk-time.py index e69de29..33d0469 100644 --- a/time/lutin_etk-time.py +++ b/time/lutin_etk-time.py @@ -0,0 +1,21 @@ +#!/usr/bin/python +import lutin.module as module +import lutin.tools as tools + +def get_desc(): + return "etk time interface" + +def get_license(): + return "APACHE v2.0" + +def create(target): + myModule = module.Module(__file__, 'etk-time', 'LIBRARY') + myModule.add_extra_compile_flags() + """ + myModule.add_src_file([ + "etk-log/log.cpp" + ]) + """ + myModule.add_module_depend(["etk-base"]) + myModule.add_export_path(tools.get_current_path(__file__)) + return myModule