Stopped hardcoding the debug flag setting.
New makefile structure.
Merge branch 'reorganize' of https://github.com/XIA-Project/xia-core into reorganize