I'm too tired to elaborate on this now, and am posting here mostly for Ism.
Key directories for swappable systems and otherwise (All under ENIGMAsystem/SHELL/): /Universal_System/ Contains things that should work on any OS (Cross platform and C standard wrappers and functions). /Platforms/ Contains directories for each available windowing/OS-dependent system. (windows [TO BE RENAMED to win32], xlib, [SOON?]cocoa, [SOON]wii) /Graphics_Systems/ Contains directories for any available drawing systems. (OpenGL,[SOME DAY]DirectX,[SOON]GX)
Something to fix: the cases don't match between Platforms and Graphics_Systems, which is annoying-ish.
Anyway, of the system-specific folders, I have it currently set up so that each has a makefile. Right now, all the makefiles are the same. That will soon change.
From the scope of each directory, ENIGMA of course calls the makefile. LGM does not need to even acknowledge said file's existence. What LGM and ENIGMA will both need, however, is a settings/config file. For now, the file has not been named; I was considering "info" for the name. This file will be a simple one, similar to LGM's *.properties files (perhaps "properties" is a good name for this file). It reads something like this:
Name="OpenGL" Description="An open source graphics library." Platforms="windows, xlib" Link-windows="-lopengl32" Link-xlib="-lGL" Notice that Link- is always proceeded by the name of an element in `Platforms', each of which is the same as a directory name.
If need be, the Platforms property can apply as a special case to folders under Platforms/ (for cases such as, just for example, using xlib in both Linux and in Mac OS X). This will probably be unnecessary, but consider that part of the purpose of the file until such is actually needed. What may be needed is a special variable for those called `Compiler', so developers can specify (especially in cases such as the Wii) that a different version of make will need to be called. This can get really messy, really fast (such as when conflicting binaries are specified by the Path variable; one for MinGW because it make ENIGMA easy, and one for Devkit's GCC, because it makes calling that easy), and so will need proper attention down the road.
Until then, this is the plan.
|