6000e4e2a813 — Leonard Ritter 1 year, 6 months ago
* updated dependencies to use eo
58 files changed, 455 insertions(+), 751 deletions(-)

M .hgignore
M __env.sc
A => build.sh
R externals/build_blendish_oui.py => 
R externals/build_bullet.py => 
R externals/build_chipmunk.py => 
R externals/build_cimgui.py => 
R externals/build_imgui.py => 
R externals/build_lmdb.py => 
R externals/build_nanovg.py => 
R externals/build_nativefiledialog.py => 
R externals/build_ode.py => 
R externals/build_portmidi.py => 
R externals/build_sdl2.py => 
R externals/nativefiledialog/SConstruct => 
M genie.lua
M lib/tukan/imgui/cimgui.sc
A => recipes/all.eo
A => recipes/blendish_oui.eo
A => recipes/bullet.eo
A => recipes/chipmunk2d.eo
A => recipes/genie.eo
A => recipes/imgui.eo
M externals/include/GL/gl.h => recipes/include/GL/gl.h
M externals/include/GL/glu.h => recipes/include/GL/glu.h
M externals/include/GL/glx.h => recipes/include/GL/glx.h
M externals/include/OpenGL/OpenGL.h => recipes/include/OpenGL/OpenGL.h
M externals/include/Windows.h => recipes/include/Windows.h
M externals/include/X11/Xatom.h => recipes/include/X11/Xatom.h
M externals/include/X11/Xlib.h => recipes/include/X11/Xlib.h
M externals/include/alloca.h => recipes/include/alloca.h
M externals/include/float.h => recipes/include/float.h
M externals/include/iconv.h => recipes/include/iconv.h
M externals/include/inttypes.h => recipes/include/inttypes.h
M externals/include/limits.h => recipes/include/limits.h
M externals/include/malloc.h => recipes/include/malloc.h
M externals/include/math.h => recipes/include/math.h
M externals/include/pthread.h => recipes/include/pthread.h
M externals/include/setjmp.h => recipes/include/setjmp.h
M externals/include/stdarg.h => recipes/include/stdarg.h
M externals/include/stdbool.h => recipes/include/stdbool.h
M externals/include/stddef.h => recipes/include/stddef.h
M externals/include/stdint.h => recipes/include/stdint.h
M externals/include/stdio.h => recipes/include/stdio.h
M externals/include/stdlib.h => recipes/include/stdlib.h
M externals/include/string.h => recipes/include/string.h
M externals/include/sys/types.h => recipes/include/sys/types.h
M externals/include/time.h => recipes/include/time.h
M externals/include/ucontext.h => recipes/include/ucontext.h
M externals/include/unistd.h => recipes/include/unistd.h
A => recipes/lmdb.eo
A => recipes/nanovg.eo
A => recipes/nativefiledialog.eo
A => recipes/ode.eo
M externals/ode/ode_osx_bootstrap.patch => recipes/ode/ode_osx_bootstrap.patch
A => recipes/portmidi.eo
A => recipes/sdl2.eo
M externals/stk/premake4.lua => recipes/stk/premake4.lua
M .hgignore +14 -1
@@ 30,7 30,7 @@ testing/*.png
 
 syntax: regexp
 
-^cdefs
+^attic
 ^build
 ^externals/archives
 ^externals/downloads

          
@@ 39,3 39,16 @@ syntax: regexp
 ^dist
 ^llvm
 ^.vscode/
+^.eo/
+^include/SDL2/
+^include/bullet/
+^include/chipmunk/
+^include/imgui/
+^include/lmdb/
+^include/nfd/
+^include/nanovg/
+^include/ode/
+^include/portmidi/
+^include/blendish/
+^include/oui/
+^bin/genie

          
M __env.sc +2 -0
@@ 1,6 1,8 @@ 
 if console?
     print "console launched"
 
+# uncomment to start off core module environment rather than the project one
+#let __env = core-module-env
 'bind-symbols __env
     module-search-path =
         cons

          
A => build.sh +4 -0
@@ 0,0 1,4 @@ 
+eo install -y all \
+ && eo sync \
+ && genie gmake \
+ && make -C build config=release -j$(nproc)

          
R externals/build_blendish_oui.py =>  +0 -41
@@ 1,41 0,0 @@ 
-# SDL downloader & builder
-
-import os
-from build_common import BuilderBase
-
-class Builder(BuilderBase):
-    NAME = 'blendish'
-    HG_URL = "https://bitbucket.org/duangle/oui-blendish"
-    # always use latest revision
-
-    def run_any_build(self):
-        self.copy2(os.path.join(self.TARGETDIR, 'blendish.h'),
-            self.INCLUDEDIR)
-        self.copy2(os.path.join(self.TARGETDIR, 'blendish.h'),
-            self.CDEFDIR)
-        self.copy2(os.path.join(self.TARGETDIR, 'oui.h'),
-            self.INCLUDEDIR)
-
-    def run_linux2_build(self):
-        self.run_any_build()
-
-    def run_darwin_build(self):
-        self.run_any_build()
-
-    def run_win32_build(self):
-        self.run_any_build()
-
-    def gen_cdef(self):
-        # not in use yet
-        return
-        result = self.cpp("""
-        #define OUI_USE_UNION_VECTORS 0
-        #include "blendish.h"
-        #include "oui.h"
-        #pragma MCPP put_defines
-        """)
-        result = self.filter_cdef_defines(result)
-        self.write_cdef(result)
-
-if __name__ == '__main__':
-    Builder().run()

          
R externals/build_bullet.py =>  +0 -67
@@ 1,67 0,0 @@ 
-# SDL downloader & builder
-
-import os
-from build_common import BuilderBase
-
-class Builder(BuilderBase):
-    NAME = 'bullet'
-    GIT_URL = "https://github.com/bulletphysics/bullet3"
-    GIT_REVISION = "2.89"
-    GIT_ARCHIVE = "archive"
-
-    def run_win32_build(self):
-        self.run_any_build()
-
-    def run_darwin_build(self):
-        self.run_any_build()
-
-    def run_linux2_build(self):
-        builddir = os.path.join(self.TARGETDIR, "build_cmake")
-        self.makedirs(builddir)
-        self.chdir(builddir)
-        cmd = "cmake -DBUILD_SHARED_LIBS=ON -DUSE_DOUBLE_PRECISION=ON -DBT_USE_EGL=ON -DCMAKE_BUILD_TYPE=Release .."
-        self.shell(cmd)
-        self.shell("make -j8")
-
-        version = "2.89"
-        basedir = "build_cmake"
-        libfiles = [
-            ("Extras/BulletRobotics", "libBulletRobotics.so"),
-            ("Extras/InverseDynamics", "libBulletInverseDynamicsUtils.so"),
-            ("Extras/Serialize/BulletWorldImporter", "libBulletWorldImporter.so"),
-            ("Extras/Serialize/BulletFileLoader", "libBulletFileLoader.so"),
-            ("src/BulletSoftBody", "libBulletSoftBody.so"),
-            ("src/BulletDynamics", "libBulletDynamics.so"),
-            ("src/BulletCollision", "libBulletCollision.so"),
-            ("src/BulletInverseDynamics", "libBulletInverseDynamics.so"),
-            ("src/LinearMath", "libLinearMath.so"),
-            ("src/Bullet3Common", "libBullet3Common.so"),
-        ]
-        for libdir,targetname in libfiles:
-            targetname = targetname + "." + version
-            self.copy2(os.path.join(self.TARGETDIR, basedir, libdir, targetname),
-                os.path.join(self.BINDIR, targetname))
-
-        includesrcdir = os.path.join(self.TARGETDIR, 'examples', 'SharedMemory')
-        includedir = os.path.join(self.CDEFDIR, 'bullet')
-        self.rmtree(includedir)
-        self.makedirs(includedir)
-        headerfiles = [
-            'PhysicsClientC_API.h',
-            'SharedMemoryPublic.h',
-            'PhysicsClientSharedMemory_C_API.h',
-            'PhysicsClientSharedMemory2_C_API.h',
-            'PhysicsDirectC_API.h',
-        ]
-        for header in headerfiles:
-            self.copy2(os.path.join(includesrcdir, header), includedir)
-        self.run_any_build()
-
-    def run_any_build(self):
-        pass
-
-    def gen_cdef(self):
-        pass
-
-if __name__ == '__main__':
-    Builder().run()

          
R externals/build_chipmunk.py =>  +0 -39
@@ 1,39 0,0 @@ 
-# SDL downloader & builder
-
-import os
-from build_common import BuilderBase
-
-class Builder(BuilderBase):
-    NAME = 'chipmunk'
-    GIT_URL = "https://github.com/slembcke/Chipmunk2D"
-    GIT_REVISION = "87340c216bf97554dc552371bbdecf283f7c540e"
-
-    def run_any_build(self):
-        includedir = os.path.join(self.CDEFDIR, 'chipmunk')
-        self.rmtree(includedir)
-        self.copytree(os.path.join(self.TARGETDIR, 'include', 'chipmunk'),
-            includedir)
-
-    def run_linux2_build(self):
-        os.environ['CFLAGS'] = '-DCP_USE_DOUBLES=0'
-        self.shell("cmake .")
-
-        #os.environ['CXXFLAGS'] = '-fPIC'
-        #os.environ['CPPFLAGS'] = '-fPIC'
-        self.shell('make -j 4')
-        self.copy2(
-            os.path.join(self.TARGETDIR, 'src', 'libchipmunk.so.7.0.3'),
-            os.path.join(self.BINDIR, 'libchipmunk.so'))
-        self.run_any_build()
-
-    def run_darwin_build(self):
-        self.run_any_build()
-
-    def run_win32_build(self):
-        self.run_any_build()
-
-    def gen_cdef(self):
-        pass
-
-if __name__ == '__main__':
-    Builder().run()

          
R externals/build_cimgui.py =>  +0 -47
@@ 1,47 0,0 @@ 
-# SDL downloader & builder
-
-import os
-from build_common import BuilderBase
-
-class Builder(BuilderBase):
-    NAME = 'cimgui'
-    GIT_URL = "https://github.com/Extrawurst/cimgui"
-    # 1.53
-    #GIT_REVISION = "1a5e261a8e97d58b32a474779774eca9314c10d0"
-    # 1.69
-    #GIT_REVISION = "4be0522d9f1513e9f14dd3510c396325007f58ad"
-    # 1.75+ docking branch
-    #GIT_REVISION = "1d32b3804d834da4d05f02d6d81e2f6b4b94138e"
-    # jun 30, 2020, master
-    GIT_REVISION = "c1f0030b20488a940f0813f413d84313652bb0b2"
-    # april 7, 2021, master
-    #GIT_REVISION = "6a98f4bbedec967d02f3395f319feceec311ecb2"
-
-    def run_any_build(self):
-        self.copy2(os.path.join(self.TARGETDIR, '..', 'imgui', 'imgui.h'),
-            os.path.join(self.TARGETDIR, 'imgui'))
-        self.copy2(os.path.join(self.TARGETDIR, '..', 'imgui', 'imgui_internal.h'),
-            os.path.join(self.TARGETDIR, 'imgui'))
-        self.copy2(os.path.join(self.TARGETDIR, '..', 'imgui', 'imconfig.h'),
-            os.path.join(self.TARGETDIR, 'imgui'))
-        self.chdir(os.path.join(self.TARGETDIR, 'generator'))
-        self.shell("luajit ./generator.lua gcc")
-        self.copy2(os.path.join(self.TARGETDIR, 'generator', 'output', 'cimgui.h'), self.TARGETDIR)
-        self.copy2(os.path.join(self.TARGETDIR, 'generator', 'output', 'cimgui.cpp'), self.TARGETDIR)
-        self.copy2(os.path.join(self.TARGETDIR, 'cimgui.h'),
-            self.CDEFDIR)
-
-    def run_linux2_build(self):
-        self.run_any_build()
-
-    def run_darwin_build(self):
-        self.run_any_build()
-
-    def run_win32_build(self):
-        self.run_any_build()
-
-    def gen_cdef(self):
-        pass
-
-if __name__ == '__main__':
-    Builder().run()

          
R externals/build_imgui.py =>  +0 -51
@@ 1,51 0,0 @@ 
-# SDL downloader & builder
-
-import os
-from build_common import BuilderBase
-
-class Builder(BuilderBase):
-    NAME = 'imgui'
-    GIT_URL = "https://github.com/ocornut/imgui"
-    # 1.53
-    #GIT_REVISION = "e916310b2e1f9cacbb2b9ce192a3dfb359e4b509"
-    # 1.69
-    #GIT_REVISION = "ebe79bbed00a13fd4455f04131b63d49c28ebd5d"
-    # 1.75+ docking branch
-    #GIT_REVISION = "103c5edaaa832ccded2523ea328dc4398ba7b456"
-    # 1.77+ docking branch
-    #GIT_REVISION = "4f5aac319e3561284833db90f35d218de8b282c1"
-    # 1.80+ docking branch
-    GIT_REVISION = "80b5fb51edba2fd3dea76ec3e88153e2492243d1"
-
-    def run_any_build(self):
-        self.copy2(os.path.join(self.TARGETDIR, 'imgui.h'),
-            self.CDEFDIR)
-
-    def run_linux2_build(self):
-        """
-        cmd = 'premake4 gmake'
-        self.shell(cmd)
-
-        os.chdir(os.path.join(self.TARGETDIR, 'build'))
-        self.shell("make clean")
-
-        os.environ['CFLAGS'] = '-fPIC'
-        os.environ['CXXFLAGS'] = '-fPIC'
-        os.environ['CPPFLAGS'] = '-fPIC'
-        cmd = 'make -j 4 nanovg config=release'
-        self.shell(cmd)
-        self.run_any_build()
-        """
-        self.run_any_build()
-
-    def run_darwin_build(self):
-        self.run_any_build()
-
-    def run_win32_build(self):
-        self.run_any_build()
-
-    def gen_cdef(self):
-        pass
-
-if __name__ == '__main__':
-    Builder().run()

          
R externals/build_lmdb.py =>  +0 -34
@@ 1,34 0,0 @@ 
-# SDL downloader & builder
-
-import os
-from build_common import BuilderBase
-
-class Builder(BuilderBase):
-    NAME = 'lmdb'
-    GIT_URL = "https://github.com/LMDB/lmdb"
-    # aug 26, 2019
-    GIT_REVISION = "5c012bbe033f9bbb273078b07dded59f080d348d"
-
-    def run_any_build(self):
-        pass
-
-    def run_linux2_build(self):
-        srcdir = os.path.join(self.TARGETDIR, 'libraries', 'liblmdb')
-        os.chdir(srcdir)
-        self.shell("make -j4")
-        self.copy2(os.path.join(srcdir, 'liblmdb.so'), self.BINDIR)
-        self.copy2(os.path.join(srcdir, 'lmdb.h'), self.CDEFDIR)
-        self.copy2(os.path.join(srcdir, 'midl.h'), self.CDEFDIR)
-        self.run_any_build()
-
-    def run_darwin_build(self):
-        self.run_any_build()
-
-    def run_win32_build(self):
-        self.run_any_build()
-
-    def gen_cdef(self):
-        pass
-
-if __name__ == '__main__':
-    Builder().run()

          
R externals/build_nanovg.py =>  +0 -84
@@ 1,84 0,0 @@ 
-# SDL downloader & builder
-
-import os
-from build_common import BuilderBase
-
-class Builder(BuilderBase):
-    NAME = 'nanovg'
-    GIT_URL = "https://github.com/memononen/nanovg"
-    # oct 25, 2015
-    GIT_REVISION = "cb6fd9100d1f316fc14a5b49df40d3defefd799d"
-    # dec 25, 2020
-    GIT_REVISION = "077b65e0cf3e22ee4f588783e319b19b0a608065"
-
-    def run_any_build(self):
-        self.copy2(os.path.join(self.TARGETDIR, 'src', 'nanovg.h'),
-            self.INCLUDEDIR)
-        self.copy2(os.path.join(self.TARGETDIR, 'src', 'nanovg_gl.h'),
-            self.INCLUDEDIR)
-        self.copy2(os.path.join(self.TARGETDIR, 'src', 'nanovg_gl_utils.h'),
-            self.INCLUDEDIR)
-        self.copy2(os.path.join(self.TARGETDIR, 'src', 'stb_image.h'),
-            self.INCLUDEDIR)
-
-        self.copy2(os.path.join(self.TARGETDIR, 'src', 'nanovg.h'),
-            self.CDEFDIR)
-        self.copy2(os.path.join(self.TARGETDIR, 'src', 'nanovg_gl.h'),
-            self.CDEFDIR)
-        self.copy2(os.path.join(self.TARGETDIR, 'src', 'stb_image.h'),
-            self.CDEFDIR)
-
-    def run_linux2_build(self):
-        cmd = 'genie gmake'
-        self.shell(cmd)
-
-        builddir = os.path.join(self.TARGETDIR, 'build')
-        os.chdir(builddir)
-        self.shell("make clean")
-
-        os.environ['CFLAGS'] = '-fPIC'
-        os.environ['CXXFLAGS'] = '-fPIC'
-        os.environ['CPPFLAGS'] = '-fPIC'
-        cmd = 'make -j 4 nanovg config=release TARGETDIR=' + builddir
-        self.shell(cmd)
-        self.run_any_build()
-
-    def run_darwin_build(self):
-        cmd = 'genie gmake'
-        self.shell(cmd)
-
-        builddir = os.path.join(self.TARGETDIR, 'build')
-        os.chdir(builddir)
-        self.shell("make clean")
-
-        os.environ['CFLAGS'] = '-fPIC'
-        os.environ['CXXFLAGS'] = '-fPIC'
-        os.environ['CPPFLAGS'] = '-fPIC'
-        cmd = 'make -j 4 nanovg config=release TARGETDIR=' + builddir
-        self.shell(cmd)
-        self.run_any_build()
-
-    def run_win32_build(self):
-        cmd = 'genie gmake'
-        self.shell(cmd)
-
-        builddir = os.path.join(self.TARGETDIR, 'build')
-        os.chdir(builddir)
-        self.shell("make clean")
-
-        cmd = 'make -j 4 nanovg config=release TARGETDIR=' + builddir
-        self.shell(cmd)
-        self.run_any_build()
-
-    def gen_cdef(self):
-        # not in use yet
-        return
-        result = self.cpp("""
-        #include "nanovg.h"
-        #pragma MCPP put_defines
-        """)
-        result = self.filter_cdef_defines(result)
-        self.write_cdef(result)
-
-if __name__ == '__main__':
-    Builder().run()

          
R externals/build_nativefiledialog.py =>  +0 -39
@@ 1,39 0,0 @@ 
-import os
-from build_common import BuilderBase
-
-class Builder(BuilderBase):
-    NAME = 'nativefiledialog'
-
-    GIT_URL = "https://github.com/mlabbe/nativefiledialog"
-    #GIT_REVISION = "45c2a71a1113e135fdc52c9d0e8f92080546cf2a"
-    #GIT_REVISION = "5cfe5002eb0fac1e49777a17dec70134147931e2"
-    # sep 30, 2019
-    GIT_REVISION = "67345b80ebb429ecc2aeda94c478b3bcc5f7888e"
-
-
-    def run_win32_build(self):
-        self.chdir(self.TARGETDIR)
-        cmd = 'make -C build/gmake_windows config=release_x64'
-        self.shell(cmd)
-
-        self.copy2(os.path.join(self.TARGETDIR, 'src', 'include', 'nfd.h'),
-            self.INCLUDEDIR)
-        self.copy2(os.path.join(self.TARGETDIR, 'src', 'include', 'nfd.h'),
-            self.CDEFDIR)
-
-    def run_linux2_build(self):
-        #os.environ['CFLAGS'] = '-fPIC'
-        self.copy2(os.path.join(self.EXTERNALDIR, 'nativefiledialog', 'SConstruct'),
-            os.path.join(self.TARGETDIR, 'src'))
-        self.chdir(os.path.join(self.TARGETDIR, 'src'))
-        cmd = 'scons'
-        self.shell(cmd)
-
-        self.copy2(os.path.join(self.TARGETDIR, 'src', 'include', 'nfd.h'),
-            self.INCLUDEDIR)
-        self.copy2(os.path.join(self.TARGETDIR, 'src', 'include', 'nfd.h'),
-            self.CDEFDIR)
-
-
-if __name__ == '__main__':
-    Builder().run()

          
R externals/build_ode.py =>  +0 -103
@@ 1,103 0,0 @@ 
-# SDL downloader & builder
-
-import os
-from build_common import BuilderBase
-
-class Builder(BuilderBase):
-    NAME = 'ode'
-    SVN_URL = "svn://svn.code.sf.net/p/opende/code/trunk"
-    SVN_REVISION = "1970"
-
-    def run_win32_build(self):
-        cwd = os.getcwd()
-        builddir = os.path.join(self.TARGETDIR, 'build')
-        os.chdir(builddir)
-        premakearch = 'x64' if self.IS_X64 else 'x32'
-        self.shell('premake4 --platform={} vs2008'.format(premakearch))
-        os.chdir(cwd)
-        slnfile = os.path.join(builddir, 'vs2008', 'ode.sln')
-
-        archstr = ' /p:Platform=x64' if self.IS_X64 else ''
-        target = ' /p:Configuration=ReleaseSingleDLL'
-        useenv = ' /p:"VCBuildAdditionalOptions= /useenv"'
-        cmd = 'msbuild {} /nologo{}{}{}'.format(slnfile, useenv, target, archstr)
-        self.shell(cmd)
-
-        self.copy2(os.path.join(self.TARGETDIR, 'lib',
-                                'ReleaseSingleDLL', 'ode_single.dll'),
-                                os.path.join(self.BINDIR, 'ode.dll'))
-        includedir = os.path.join(self.INCLUDEDIR, 'ode')
-        self.rmtree(includedir)
-        self.copytree(os.path.join(self.TARGETDIR, 'include', 'ode'),
-                      includedir)
-
-    def run_darwin_build(self):
-        PATCH_ODE_OSX = os.path.join(self.EXTERNALDIR, self.NAME, 'ode_osx_bootstrap.patch')
-        self.apply_patch(PATCH_ODE_OSX)
-
-        cmd = './bootstrap'
-        self.shell(cmd)
-
-        cmd = './configure --with-pic --prefix {0}'.format(self.TARGETDIR)
-        self.shell(cmd)
-
-        cmd = 'make -j 4'
-        self.shell(cmd)
-
-        cmd = 'make install'
-        self.shell(cmd)
-
-        self.copy2(os.path.join(self.TARGETDIR, 'lib',
-            'libode.a'),
-            os.path.join(self.BINDIR, 'libode.a'))
-        includedir = os.path.join(self.INCLUDEDIR, 'ode')
-        self.rmtree(includedir)
-        self.copytree(os.path.join(self.TARGETDIR, 'include', 'ode'),
-            includedir)
-
-    def run_linux2_build(self):
-        os.chdir(os.path.join(self.TARGETDIR, 'build'))
-
-        cmd = 'premake4 gmake'
-        self.shell(cmd)
-
-        os.chdir(os.path.join(self.TARGETDIR, 'build', 'gmake'))
-
-        if 1:
-            cmd = 'make -j 4 config=releasesingledll'
-            self.shell(cmd)
-
-            # copy over
-            self.copy2(os.path.join(self.TARGETDIR, 'lib',
-                'ReleaseSingleDLL', 'libode_single.so'),
-                os.path.join(self.BINDIR, 'libode.so'))
-        else:
-            cmd = 'make -j 4 config=releasedoubledll'
-            self.shell(cmd)
-
-            # copy over
-            self.copy2(os.path.join(self.TARGETDIR, 'lib',
-                'ReleaseDoubleDLL', 'libode_double.so'),
-                os.path.join(self.BINDIR, 'libode.so'))
-        #includedir = os.path.join(self.INCLUDEDIR, 'ode')
-        includedir = os.path.join(self.CDEFDIR, 'ode')
-        self.rmtree(includedir)
-        self.copytree(os.path.join(self.TARGETDIR, 'include', 'ode'),
-            includedir)
-
-    def gen_cdef(self):
-        result = self.cpp("""
-        //#define dSINGLE
-        #define FILE void
-        #define time_t int64_t
-
-        #include "ode/ode.h"
-        #pragma MCPP put_defines
-        """)
-        result = self.filter_cdef_defines(result, blacklist=[
-            'X86_64_SYSTEM',
-        ])
-        self.write_cdef(result)
-
-if __name__ == '__main__':
-    Builder().run()

          
R externals/build_portmidi.py =>  +0 -46
@@ 1,46 0,0 @@ 
-# SDL downloader & builder
-
-import os
-from build_common import BuilderBase
-
-class Builder(BuilderBase):
-    NAME = 'portmidi'
-    HG_URL = "https://bitbucket.org/duangle/portmidi"
-    # GIT_REVISION = "7fced5def3b44145369bc1bef3311d6dedf98747"
-    
-    def run_any_build(self):
-        # copy include files
-        self.copy2(
-            os.path.join(self.TARGETDIR, 'pm_common', 'portmidi.h'), 
-            self.CDEFDIR)
-        self.copy2(
-            os.path.join(self.TARGETDIR, 'porttime', 'porttime.h'), 
-            self.CDEFDIR)
-        
-    def run_linux2_build(self):
-        builddir = os.path.join(self.TARGETDIR, 'build')
-        os.makedirs(builddir)
-        os.chdir(builddir)
-        cmd = 'cmake -DCMAKE_INSTALL_PREFIX:PATH={builddir} -DINSTALL_NAME_DIR={builddir} ..'.format(
-            builddir = self.BUILDDIR)
-        self.shell(cmd)
-        
-        cmd = 'make -j 4'
-        self.shell(cmd)
-        
-        self.copy2(
-            os.path.join(self.TARGETDIR, 'build', 'pm_dylib', 'libportmidi.so'), 
-            self.BINDIR)
-        self.run_any_build()
-        
-    def run_darwin_build(self):
-        self.run_any_build()
-        
-    def run_win32_build(self):
-        self.run_any_build()
-        
-    def gen_cdef(self):
-        pass
-
-if __name__ == '__main__':
-    Builder().run()

          
R externals/build_sdl2.py =>  +0 -116
@@ 1,116 0,0 @@ 
-# SDL downloader & builder
-
-import os
-from build_common import BuilderBase
-
-class Builder(BuilderBase):
-    NAME = 'SDL2'
-    if BuilderBase.IS_WIN32:
-        URL = "http://libsdl.org/release/"
-        ARCHIVE = "SDL2-devel-2.0.10-mingw.tar.gz"
-    else:
-        HG_URL = "http://hg.libsdl.org/SDL"
-        #HG_REVISION = "a0d15db7bd09"
-        #HG_REVISION = "235c5929651c"
-        HG_REVISION = "bc90ce38f1e2" # 2.0.10
-        HG_ARCHIVE = "archive"
-
-    def run_linux2_build(self):
-        os.chdir(self.TARGETDIR)
-        builddir = os.path.join(self.TARGETDIR, 'build')
-        self.makedirs(builddir)
-
-        os.environ['CFLAGS'] = '-fPIC'
-        os.environ['CXXFLAGS'] = '-fPIC'
-        os.chdir(builddir)
-        cmd = '../configure --with-pic --enable-video-vulkan --enable-video-opengl --disable-video-wayland --prefix {0}'.format(self.BUILDDIR)
-        self.shell(cmd)
-
-        cmd = 'make -j 4'
-        self.shell(cmd)
-
-        cmd = 'make install'
-        self.shell(cmd)
-
-        # copy over
-        self.copy2(os.path.join(self.LIBDIR, 'libSDL2-2.0.so.0.10.0'),
-            os.path.join(self.BINDIR, 'libSDL2-2.0.so.0'))
-        # copy include files
-        includedir = os.path.join(self.CDEFDIR, 'SDL2')
-        self.rmtree(includedir)
-        self.copytree(
-            os.path.join(self.TARGETDIR, 'include'),
-            includedir)
-
-    def run_darwin_build(self):
-        PATCH_SDL_OSX_GL32 = os.path.join(self.EXTERNALDIR, 'sdl-osx-gl3.2.patch')
-        self.apply_patch(PATCH_SDL_OSX_GL32)
-        builddir = os.path.join(self.TARGETDIR, 'build')
-        self.makedirs(builddir)
-
-        os.environ['CFLAGS'] = '-fPIC'
-        os.environ['CXXFLAGS'] = '-fPIC'
-        os.chdir(builddir)
-        cmd = '../configure --with-pic --prefix {0}'.format(self.BUILDDIR)
-        self.shell(cmd)
-
-        cmd = 'make -j 4'
-        self.shell(cmd)
-
-        cmd = 'make install'
-        self.shell(cmd)
-
-        # copy over
-        self.copy2(os.path.join(self.LIBDIR, 'libSDL2-2.0.0.dylib'),
-            os.path.join(self.BINDIR, 'libSDL2.dylib'))
-
-    def run_win32_build(self):
-        srcdir = os.path.join(self.TARGETDIR, 'x86_64-w64-mingw32')
-        includedir = os.path.join(self.CDEFDIR, 'SDL2')
-        self.rmtree(includedir)
-        self.copytree(os.path.join(srcdir, 'include', 'SDL2'), includedir)
-        includedir = os.path.join(self.INCLUDEDIR, 'SDL2')
-        self.rmtree(includedir)
-        self.copytree(os.path.join(srcdir, 'include', 'SDL2'), includedir)
-        libdir = os.path.join(srcdir, 'lib')
-        self.copy2(os.path.join(libdir, 'libSDL2.a'), self.LIBDIR)
-        self.copy2(os.path.join(libdir, 'libSDL2.dll.a'), self.LIBDIR)
-        self.copy2(os.path.join(libdir, 'libSDL2.la'), self.LIBDIR)
-        self.copy2(os.path.join(libdir, 'libSDL2main.a'), self.LIBDIR)
-        self.copy2(os.path.join(libdir, 'libSDL2main.la'), self.LIBDIR)
-        self.copy2(os.path.join(srcdir, 'bin', 'SDL2.dll'), self.BINDIR)
-
-    def run_win32_build_vs(self):
-        """not in use - just for future reference"""
-        if self.IS_X64:
-            builddir = os.path.join(self.TARGETDIR, 'VisualC', 'SDL', 'x64', 'Release')
-        else:
-            builddir = os.path.join(self.TARGETDIR, 'VisualC', 'SDL', 'Release')
-        slnfile = os.path.join(self.TARGETDIR, 'VisualC', 'SDL_VS2008.sln')
-
-        DXSDK_DIR = os.environ['DXSDK_DIR']
-
-        os.environ['INCLUDE'] = os.path.join(DXSDK_DIR, 'Include') + os.pathsep + os.environ.get('INCLUDE', '')
-        DX_ARCH = 'x64' if self.IS_X64 else 'x86'
-        os.environ['LIB'] = os.path.join(DXSDK_DIR, 'Lib', DX_ARCH) + os.pathsep + os.environ.get('LIB', '')
-
-        archstr = ' /p:Platform=x64' if self.IS_X64 else ''
-        useenv = ' /p:"VCBuildAdditionalOptions= /useenv"'
-        cmd = 'msbuild {} /nologo /p:Configuration=Release{}{}'.format(
-            slnfile, archstr, useenv)
-        self.shell(cmd)
-        assert os.path.isdir(builddir)
-        includedir = os.path.join(self.INCLUDEDIR, 'SDL2')
-        self.rmtree(includedir)
-        self.copytree(
-            os.path.join(self.TARGETDIR, 'include'),
-            includedir)
-        self.copy2(
-            os.path.join(builddir, 'SDL2.lib'),
-            self.LIBDIR)
-        self.copy2(
-            os.path.join(builddir, 'SDL2.dll'),
-            self.BINDIR)
-
-if __name__ == '__main__':
-    Builder().run()

          
R externals/nativefiledialog/SConstruct =>  +0 -74
@@ 1,74 0,0 @@ 
-# 
-# Native File Dialog
-#
-# Scons build script -- GCC, Clang, Visual Studio
-# Does not build test
-
-
-# target arch is build arch -- extend here for cross compiling
-target_arch=str(Platform())
-debug = int(ARGUMENTS.get( 'debug', 0 ))
-
-nfd_files = ['nfd_common.c']
-
-nfd_env = Environment()
-
-# Windows runtime library types
-win_rtl = {'debug': '/MDd',     
-           'release': '/MD'}   
-
-def set_debug(env):
-    if target_arch == 'win32':
-        env.Append( CCFLAGS=['/Z7',       # obj contains full symbols
-                            win_rtl['debug']
-                        ])
-    else:
-        env.Append( CFLAGS=['-g'] )
-
-
-def set_release(env):
-    if target_arch == 'win32':
-        env.Append( CCFLAGS=[win_rtl['release'],  
-                            '/O2'] )
-    else:
-        env.Append( CFLAGS=['-O3','-fPIC'] )
-                    
-
-def set_warnings(env):
-    if target_arch == 'win32':
-        env.Append( CCFLAGS=['/W3'],
-                    CPPDEFINES=['_CRT_SECURE_NO_WARNINGS'] )
-    else:
-        env.Append( CFLAGS=['-Wall', '-pedantic'] )
-
-
-def get_lib_name(base, is_debug):
-    if is_debug:
-        return base + '_d'
-    else:
-        return base
-
-
-# Cocoa OS X builds - clang
-if target_arch == 'darwin':
-    nfd_files.append('nfd_cocoa.m')
-    nfd_env.CC='clang -fcolor-diagnostics'
-
-# Linux GTK+ 3 builds - GCC
-elif target_arch == 'posix':
-    nfd_files.append('nfd_gtk.c')
-    nfd_env.ParseConfig( 'pkg-config --cflags gtk+-3.0' )
-
-# Windows builds - Visual Studio
-elif target_arch == 'win32':
-    nfd_files.append('nfd_win.cpp')
-
-if debug:
-    set_debug(nfd_env)
-else:
-    set_release(nfd_env)
-
-set_warnings(nfd_env)
-
-nfd_env.Append( CPPPATH=['.','./include'] )
-nfd_env.StaticLibrary( get_lib_name('nfd', debug), nfd_files )

          
M genie.lua +15 -8
@@ 73,11 73,11 @@ solution "Tukan"
 
             --"src/coro/*.c",
 
-            "build/src/imgui/imgui.cpp",
-            "build/src/imgui/imgui_draw.cpp",
-            "build/src/imgui/imgui_demo.cpp",
-            "build/src/imgui/imgui_tables.cpp",
-            "build/src/imgui/imgui_widgets.cpp",
+            "build/src/cimgui/imgui/imgui.cpp",
+            "build/src/cimgui/imgui/imgui_draw.cpp",
+            "build/src/cimgui/imgui/imgui_demo.cpp",
+            "build/src/cimgui/imgui/imgui_tables.cpp",
+            "build/src/cimgui/imgui/imgui_widgets.cpp",
 
             "build/src/cimgui/*.cpp",
         }

          
@@ 86,12 86,19 @@ solution "Tukan"
             "include/libbf",
             "include/glad",
             "build/include",
-            "build/include/SDL2",
+            "include/SDL2",
+            "include/nanovg",
+            "include/nanovg",
+            "include/blendish",
+            "include/oui",
+            "include/nfd",
+            "include/imgui",
             "src",
-            "build/src/imgui",
+            "build/src/cimgui/imgui",
         }
         libdirs {
             "lib",
+            "build/lib",
             "build/src/nanovg/build",
             "build/src/tess2/Build",
         }

          
@@ 126,7 133,7 @@ solution "Tukan"
             links {
                 "pthread",
                 "nanovg",
-                "tess2",
+                --"tess2",
                 "gtk-3", -- for nativefiledialog
             }
             linkoptions {

          
M lib/tukan/imgui/cimgui.sc +1 -1
@@ 9,7 9,7 @@ include
     """"
         //#include "imgui.h"
         #define CIMGUI_DEFINE_ENUMS_AND_STRUCTS
-        #include "cimgui.h"
+        #include "imgui/cimgui.h"
         #define IMGUI_IMPL_API
         #define LM_EXPORT
         #include "tukan/imgui_impl_opengl3.h"

          
A => recipes/all.eo +17 -0
@@ 0,0 1,17 @@ 
+# a meta-recipe that installs all the other ones
+package all
+    summary "all project dependencies"
+    version "3"
+    depends
+        bullet
+        chipmunk2d
+        imgui
+        lmdb
+        nanovg
+        nfd
+        ode
+        portmidi
+        sdl2
+        blendish
+        oui
+        genie

          
A => recipes/blendish_oui.eo +14 -0
@@ 0,0 1,14 @@ 
+revision := "e48d5d4ce16e"
+archive :=
+    download "https://hg.sr.ht/~duangle/oui-blendish/archive/{revision}.tar.gz"
+base-dir := (commonpath (extract archive))
+package blendish
+    summary "Blendish"
+    version revision
+
+    in "/include/blendish" "{base-dir}/blendish.h"
+package oui
+    summary "OUI"
+    version revision
+
+    in "/include/oui" "{base-dir}/oui.h"

          
A => recipes/bullet.eo +36 -0
@@ 0,0 1,36 @@ 
+version := "2.89"
+archive :=
+    download
+        "https://github.com/bulletphysics/bullet3/archive/refs/tags/{version}.tar.gz"
+build-path := (commonpath (extract archive))
+base-dir := (mkdir "{build-path}/build_cmake")
+build-command :=
+    shell base-dir (dict)
+base-dir :=
+    then
+        build-command "cmake -DBUILD_SHARED_LIBS=ON -DUSE_DOUBLE_PRECISION=ON \
+            -DBT_USE_EGL=ON -DCMAKE_BUILD_TYPE=Release .."
+        build-command "make -j {cpu-core-count}"
+        base-dir
+include-src-dir := "{build-path}/examples/SharedMemory"
+package bullet
+    summary "Bullet Physics SDK (C API)"
+    platform linux unknown
+    version version
+    alias "/lib/libBulletRobotics.so" "{base-dir}/Extras/BulletRobotics/libBulletRobotics.so.{version}"
+    alias "/lib/libBulletInverseDynamicsUtils.so" "{base-dir}/Extras/InverseDynamics/libBulletInverseDynamicsUtils.so.{version}"
+    alias "/lib/libBulletWorldImporter.so" "{base-dir}/Extras/Serialize/BulletWorldImporter/libBulletWorldImporter.so.{version}"
+    alias "/lib/libBulletFileLoader.so" "{base-dir}/Extras/Serialize/BulletFileLoader/libBulletFileLoader.so.{version}"
+    alias "/lib/libBulletSoftBody.so" "{base-dir}/src/BulletSoftBody/libBulletSoftBody.so.{version}"
+    alias "/lib/libBulletDynamics.so" "{base-dir}/src/BulletDynamics/libBulletDynamics.so.{version}"
+    alias "/lib/libBulletCollision.so" "{base-dir}/src/BulletCollision/libBulletCollision.so.{version}"
+    alias "/lib/libBulletInverseDynamics.so" "{base-dir}/src/BulletInverseDynamics/libBulletInverseDynamics.so.{version}"
+    alias "/lib/libLinearMath.so" "{base-dir}/src/LinearMath/libLinearMath.so.{version}"
+    alias "/lib/libBullet3Common.so" "{base-dir}/src/Bullet3Common/libBullet3Common.so.{version}"
+
+    in "/include/bullet"
+        "{include-src-dir}/PhysicsClientC_API.h"
+        "{include-src-dir}/SharedMemoryPublic.h"
+        "{include-src-dir}/PhysicsClientSharedMemory_C_API.h"
+        "{include-src-dir}/PhysicsClientSharedMemory2_C_API.h"
+        "{include-src-dir}/PhysicsDirectC_API.h"

          
A => recipes/chipmunk2d.eo +22 -0
@@ 0,0 1,22 @@ 
+revision := "87340c216bf97554dc552371bbdecf283f7c540e"
+archive :=
+    download "https://github.com/slembcke/Chipmunk2D/archive/{revision}.tar.gz"
+build-path := (commonpath (extract archive))
+base-dir := build-path
+cmd :=
+    shell base-dir
+        dict
+            CFLAGS = "-DCP_USE_DOUBLES=0"
+base-dir :=
+    then
+        cmd "cmake ."
+        cmd "make -j {cpu-core-count}"
+        base-dir
+package chipmunk2d
+    summary "Chipmunk2D Game Dynamics"
+    platform linux unknown
+    version revision
+
+    alias "/lib/libchipmunk.so" "{base-dir}/src/libchipmunk.so.7.0.3"
+
+    in "/include" "{base-dir}/include/chipmunk"

          
A => recipes/genie.eo +23 -0
@@ 0,0 1,23 @@ 
+VERSION := "1160"
+SUMMARY := "GENie - Project generator tool"
+package genie
+    summary SUMMARY
+    version VERSION
+    platform linux unknown
+
+    url := "https://github.com/bkaradzic/bx/raw/master/tools/bin/linux/genie"
+    binary := (download url)
+    binary :=
+        then
+            cmd := (shell "." (dict))
+            cmd "chmod a+x {binary}"
+            binary
+    alias "/bin/genie" binary
+package genie
+    summary SUMMARY
+    version VERSION
+    platform windows windows-mingw
+
+    url := "https://github.com/bkaradzic/bx/raw/master/tools/bin/windows/genie.exe"
+    binary := (download url)
+    alias "/bin/genie.exe" binary

          
A => recipes/imgui.eo +50 -0
@@ 0,0 1,50 @@ 
+imgui-revision :=
+    # 1.53
+    #"e916310b2e1f9cacbb2b9ce192a3dfb359e4b509"
+    # 1.69
+    #"ebe79bbed00a13fd4455f04131b63d49c28ebd5d"
+    # 1.75+ docking branch
+    #"103c5edaaa832ccded2523ea328dc4398ba7b456"
+    # 1.77+ docking branch
+    #"4f5aac319e3561284833db90f35d218de8b282c1"
+    # 1.80+ docking branch
+    "80b5fb51edba2fd3dea76ec3e88153e2492243d1"
+cimgui-revision :=
+    # 1.53
+    #"1a5e261a8e97d58b32a474779774eca9314c10d0"
+    # 1.69
+    #"4be0522d9f1513e9f14dd3510c396325007f58ad"
+    # 1.75+ docking branch
+    #"1d32b3804d834da4d05f02d6d81e2f6b4b94138e"
+    # jun 30, 2020, master
+    "c1f0030b20488a940f0813f413d84313652bb0b2"
+    # april 7, 2021, master
+    #"6a98f4bbedec967d02f3395f319feceec311ecb2"
+imgui-archive :=
+    download "https://github.com/ocornut/imgui/archive/{imgui-revision}.tar.gz"
+imgui-build-path := (commonpath (extract imgui-archive))
+cimgui-archive :=
+    download "https://github.com/Extrawurst/cimgui/archive/{cimgui-revision}.tar.gz"
+cimgui-build-path := (commonpath (extract cimgui-archive))
+cmd := (shell cimgui-build-path (dict))
+imgui-subdir := "{cimgui-build-path}/imgui"
+gen-cmd := (shell "{cimgui-build-path}/generator" (dict))
+cimgui-build-path :=
+    then
+        cmd "cp {imgui-build-path}/imgui.h {imgui-subdir}/"
+        cmd "cp {imgui-build-path}/imgui_internal.h {imgui-subdir}/"
+        cmd "cp {imgui-build-path}/imconfig.h {imgui-subdir}/"
+        gen-cmd "luajit ./generator.lua gcc"
+        cimgui-build-path
+package imgui
+    summary "Dear ImGui Sources (+ C API)"
+    platform linux unknown
+    version imgui-revision
+
+    in "/include/imgui"
+        "{cimgui-build-path}/generator/output/cimgui.h"
+    in "/build/src/cimgui"
+        "{cimgui-build-path}/generator/output/cimgui.cpp"
+    alias "/build/src/cimgui/imgui" imgui-build-path
+
+

          
M externals/include/GL/gl.h => recipes/include/GL/gl.h +0 -0

M externals/include/GL/glu.h => recipes/include/GL/glu.h +0 -0

M externals/include/GL/glx.h => recipes/include/GL/glx.h +0 -0

M externals/include/OpenGL/OpenGL.h => recipes/include/OpenGL/OpenGL.h +0 -0

M externals/include/Windows.h => recipes/include/Windows.h +0 -0

M externals/include/X11/Xatom.h => recipes/include/X11/Xatom.h +0 -0

M externals/include/X11/Xlib.h => recipes/include/X11/Xlib.h +0 -0

M externals/include/alloca.h => recipes/include/alloca.h +0 -0

M externals/include/float.h => recipes/include/float.h +0 -0

M externals/include/iconv.h => recipes/include/iconv.h +0 -0

M externals/include/inttypes.h => recipes/include/inttypes.h +0 -0

M externals/include/limits.h => recipes/include/limits.h +0 -0

M externals/include/malloc.h => recipes/include/malloc.h +0 -0

M externals/include/math.h => recipes/include/math.h +0 -0

M externals/include/pthread.h => recipes/include/pthread.h +0 -0

M externals/include/setjmp.h => recipes/include/setjmp.h +0 -0

M externals/include/stdarg.h => recipes/include/stdarg.h +0 -0

M externals/include/stdbool.h => recipes/include/stdbool.h +0 -0

M externals/include/stddef.h => recipes/include/stddef.h +0 -0

M externals/include/stdint.h => recipes/include/stdint.h +0 -0

M externals/include/stdio.h => recipes/include/stdio.h +0 -0

M externals/include/stdlib.h => recipes/include/stdlib.h +0 -0

M externals/include/string.h => recipes/include/string.h +0 -0

M externals/include/sys/types.h => recipes/include/sys/types.h +0 -0

M externals/include/time.h => recipes/include/time.h +0 -0

M externals/include/ucontext.h => recipes/include/ucontext.h +0 -0

M externals/include/unistd.h => recipes/include/unistd.h +0 -0

A => recipes/lmdb.eo +22 -0
@@ 0,0 1,22 @@ 
+revision :=
+    # aug 26, 2019
+    "5c012bbe033f9bbb273078b07dded59f080d348d"
+archive :=
+    download "https://github.com/LMDB/lmdb/archive/{revision}.tar.gz"
+build-path := (commonpath (extract archive))
+base-dir := "{build-path}/libraries/liblmdb"
+cmd :=
+    shell base-dir (dict)
+base-dir :=
+    then
+        cmd "make -j {cpu-core-count}"
+        base-dir
+package lmdb
+    summary "Lightning Memory-Mapped Database"
+    platform linux unknown
+    version revision
+
+    in "/lib" "{base-dir}/liblmdb.so"
+    in "/include/lmdb"
+        "{base-dir}/lmdb.h"
+        "{base-dir}/midl.h"

          
A => recipes/nanovg.eo +32 -0
@@ 0,0 1,32 @@ 
+revision :=
+    # oct 25, 2015
+    #"cb6fd9100d1f316fc14a5b49df40d3defefd799d"
+    # dec 25, 2020
+    "077b65e0cf3e22ee4f588783e319b19b0a608065"
+archive :=
+    download "https://github.com/memononen/nanovg/archive/{revision}.tar.gz"
+build-path := (commonpath (extract archive))
+cmd := (shell build-path (dict))
+base-dir := "{build-path}/build"
+build-cmd :=
+    shell base-dir
+        dict
+            CFLAGS = "-fPIC"
+            CXXFLAGS = "-fPIC"
+            CPPFLAGS = "-fPIC"
+base-dir :=
+    then
+        cmd "genie gmake"
+        build-cmd "make -j {cpu-core-count} nanovg config=release TARGETDIR={base-dir}"
+        base-dir
+package nanovg
+    summary "NanoVG (Static)"
+    platform linux unknown
+    version revision
+
+    in "/build/lib" "{base-dir}/libnanovg.a"
+    in "/include/nanovg"
+        "{build-path}/src/nanovg.h"
+        "{build-path}/src/nanovg_gl.h"
+        "{build-path}/src/nanovg_gl_utils.h"
+        "{build-path}/src/stb_image.h"

          
A => recipes/nativefiledialog.eo +112 -0
@@ 0,0 1,112 @@ 
+revision :=
+    #"45c2a71a1113e135fdc52c9d0e8f92080546cf2a"
+    #"5cfe5002eb0fac1e49777a17dec70134147931e2"
+    # sep 30, 2019
+    "67345b80ebb429ecc2aeda94c478b3bcc5f7888e"
+archive :=
+    download "https://github.com/mlabbe/nativefiledialog/archive/{revision}.tar.gz"
+build-path := (commonpath (extract archive))
+base-dir := build-path
+SConstruct :=
+    """"#
+        # Native File Dialog
+        #
+        # Scons build script -- GCC, Clang, Visual Studio
+        # Does not build test
+
+        # target arch is build arch -- extend here for cross compiling
+        target_arch=str(Platform())
+        debug = int(ARGUMENTS.get( 'debug', 0 ))
+
+        nfd_files = ['nfd_common.c']
+
+        nfd_env = Environment()
+
+        # Windows runtime library types
+        win_rtl = {'debug': '/MDd',
+                'release': '/MD'}
+
+        def set_debug(env):
+            if target_arch == 'win32':
+                env.Append( CCFLAGS=['/Z7',       # obj contains full symbols
+                                    win_rtl['debug']
+                                ])
+            else:
+                env.Append( CFLAGS=['-g'] )
+
+
+        def set_release(env):
+            if target_arch == 'win32':
+                env.Append( CCFLAGS=[win_rtl['release'],
+                                    '/O2'] )
+            else:
+                env.Append( CFLAGS=['-O3','-fPIC'] )
+
+
+        def set_warnings(env):
+            if target_arch == 'win32':
+                env.Append( CCFLAGS=['/W3'],
+                            CPPDEFINES=['_CRT_SECURE_NO_WARNINGS'] )
+            else:
+                env.Append( CFLAGS=['-Wall', '-pedantic'] )
+
+
+        def get_lib_name(base, is_debug):
+            if is_debug:
+                return base + '_d'
+            else:
+                return base
+
+
+        # Cocoa OS X builds - clang
+        if target_arch == 'darwin':
+            nfd_files.append('nfd_cocoa.m')
+            nfd_env.CC='clang -fcolor-diagnostics'
+
+        # Linux GTK+ 3 builds - GCC
+        elif target_arch == 'posix':
+            nfd_files.append('nfd_gtk.c')
+            nfd_env.ParseConfig( 'pkg-config --cflags gtk+-3.0' )
+
+        # Windows builds - Visual Studio
+        elif target_arch == 'win32':
+            nfd_files.append('nfd_win.cpp')
+
+        if debug:
+            set_debug(nfd_env)
+        else:
+            set_release(nfd_env)
+
+        set_warnings(nfd_env)
+
+        nfd_env.Append( CPPPATH=['.','./include'] )
+        nfd_env.StaticLibrary( get_lib_name('nfd', debug), nfd_files )
+SConstruct := (tempfile SConstruct)
+summary := "Native File Dialog (Static)"
+package nfd
+    summary summary
+    platform windows
+    version revision
+    cmd :=
+        shell base-dir (dict)
+    base-dir :=
+        then
+            cmd "make -j {cpu-core-count} -C build/gmake_windows config=release_x64"
+            base-dir
+    in "/include" "{base-dir}/src/include/nfd.h"
+    in "/build/lib" "{base-dir}/build/lib/Release/x64/nfd.lib"
+package nfd
+    summary summary
+    platform linux unknown
+    version revision
+    cmd :=
+        shell "{base-dir}/src"
+            dict;
+                #CFLAGS = "-fPIC"
+    base-dir :=
+        then
+            cmd "cp {SConstruct} ./SConstruct"
+            cmd "scons -j {cpu-core-count}"
+            base-dir
+    in "/build/lib" "{base-dir}/src/libnfd.a"
+    in "/include/nfd" "{base-dir}/src/include/nfd.h"

          
A => recipes/ode.eo +24 -0
@@ 0,0 1,24 @@ 
+revision := "1970"
+repo :=
+    commonpath
+        extract
+            download-svn "svn://svn.code.sf.net/p/opende/code/trunk" revision
+build-path := repo
+cmd := (shell "{build-path}/build" (dict))
+base-dir := "{build-path}/build/gmake"
+build-cmd := (shell base-dir (dict))
+repo :=
+    then
+        cmd "premake4 gmake"
+        build-cmd "make -j {cpu-core-count} config=releasesingledll"
+        #build-cmd "make -j {cpu-core-count} config=releasedoubledll"
+        repo
+package ode
+    summary "Open Dynamics Engine"
+    platform linux unknown
+    version "r{revision}"
+
+    alias "/lib/libode.so" "{repo}/lib/ReleaseSingleDLL/libode_single.so"
+    #alias "/lib/libode.so" "{repo}/lib/ReleaseDoubleDLL/libode_double.so"
+
+    in "/include" "{repo}/include/ode"

          
M externals/ode/ode_osx_bootstrap.patch => recipes/ode/ode_osx_bootstrap.patch +0 -0

A => recipes/portmidi.eo +29 -0
@@ 0,0 1,29 @@ 
+version := "v2.0.1"
+archive :=
+    download
+        #"https://github.com/PortMidi/portmidi/archive/{revision}.tar.gz"
+        "https://github.com/PortMidi/portmidi/archive/refs/tags/{version}.tar.gz"
+build-path := (commonpath (extract archive))
+base-dir := (mkdir "{build-path}/build")
+cmd := (shell build-path)
+build-cmd :=
+    shell base-dir
+        dict
+            CFLAGS = "-fPIC"
+            CXXFLAGS = "-fPIC"
+            CPPFLAGS = "-fPIC"
+build-path :=
+    then
+        build-cmd "cmake -DCMAKE_INSTALL_PREFIX:PATH={base-dir} -DINSTALL_NAME_DIR={base-dir} .."
+        build-cmd "make -j {cpu-core-count}"
+        cmd "find"
+        build-path
+package portmidi
+    summary "PortMidi"
+    platform linux unknown
+    version version
+
+    in "/lib" "{build-path}/build/libportmidi.so"
+    in "/include/portmidi"
+        "{build-path}/pm_common/portmidi.h"
+        "{build-path}/porttime/porttime.h"

          
A => recipes/sdl2.eo +38 -0
@@ 0,0 1,38 @@ 
+revision := # binding an expression-scoped name
+    #"a0d15db7bd09"
+    #"235c5929651c"
+    "bc90ce38f1e2" # 2.0.10
+archive := # `name := value ...` binds a name to one or multiple values
+    download # will be downloaded lazily
+        # string substitution is supported implicitly and defines proper
+            dependencies.
+        "http://hg.libsdl.org/SDL/archive/{revision}.tar.gz"
+preinstall-dir :=
+    then # `then` brings an arbitrary number of operations in order
+        build-path :=
+            commonpath # get the common directory of a list of files
+                extract archive # evaluate to a list of files
+        build-command := # build a shell environment from a current working
+                           directory and pairs of keys and values
+            shell
+                mkdir "{build-path}/build" # `mkdir` ensures the dir exists
+                dict
+                    CFLAGS = "-fPIC"
+                    CXXFLAGS = "-fPIC"
+        install-tmp-dir := (tempdir) # every expression has its own scope
+                                       so this alias is only available here
+        build-command "../configure --with-pic --enable-video-vulkan \
+            --enable-video-opengl --disable-video-wayland \
+            --prefix {install-tmp-dir}"
+        build-command "make -j {cpu-core-count}"
+        build-command "make install"
+        install-tmp-dir
+# root entry point for our package
+     multiple packages can be defined
+package sdl2
+    summary "Simple DirectMedia Layer"
+    platform linux unknown
+    version revision
+    sopath := "{preinstall-dir}/lib/libSDL2-2.0.so.0.10.0"
+    alias "/lib/libSDL2-2.0.so.0" sopath
+    in "/include" "{preinstall-dir}/include/SDL2"

          
M externals/stk/premake4.lua => recipes/stk/premake4.lua +0 -0