summaryrefslogtreecommitdiff
path: root/tools
diff options
context:
space:
mode:
authorStephen Simpson <megazig@gmail.com>2011-10-10 22:16:35 -0500
committerStephen Simpson <megazig@gmail.com>2011-10-10 22:16:35 -0500
commit1bf7f8a471746eef9badf5f37031da6f8d88e9a2 (patch)
tree03e4e62a435d88e5fd8d9dda2d9cc848e5a16af1 /tools
parenta61758720db96f59e0fb82aab9f326d37e186a11 (diff)
downloadkamek-1bf7f8a471746eef9badf5f37031da6f8d88e9a2.tar.gz
kamek-1bf7f8a471746eef9badf5f37031da6f8d88e9a2.zip
added ability to link in .o files
tweeked MountainGoombas Launch state for always arcing up added two more goomba types to the Launch state added in codehandler. bp not working, but rest seems functional
Diffstat (limited to 'tools')
-rw-r--r--tools/kamek.py24
1 files changed, 15 insertions, 9 deletions
diff --git a/tools/kamek.py b/tools/kamek.py
index f67f049..3f7fb5c 100644
--- a/tools/kamek.py
+++ b/tools/kamek.py
@@ -306,16 +306,19 @@ class KamekBuilder(object):
objfile = os.path.join(self._configTempDir, '%d.o' % generate_unique_id())
sourcefile = os.path.join(m.moduleDir, normal_sourcefile)
- # todo: better extension detection
- if sourcefile.endswith('.s') or sourcefile.endswith('.S'):
- command = as_command
+ if sourcefile.endswith('.o'):
+ new_command = ['cp', sourcefile, objfile]
else:
- command = cc_command
-
- new_command = command + ['-c', '-o', objfile, sourcefile]
-
- if 'cc_args' in m.data:
- new_command += m.data['cc_args']
+ # todo: better extension detection
+ if sourcefile.endswith('.s') or sourcefile.endswith('.S'):
+ command = as_command
+ else:
+ command = cc_command
+
+ new_command = command + ['-c', '-o', objfile, sourcefile]
+
+ if 'cc_args' in m.data:
+ new_command += m.data['cc_args']
if show_cmd:
print_debug(new_command)
@@ -428,6 +431,9 @@ class KamekBuilder(object):
def _find_func_by_symbol(self, find_symbol):
for sym in self._symbols:
+ #if show_cmd:
+ # out = "0x%08x - %s - %s" % (sym[0], sym[1], sym[2])
+ # print_debug(out)
if sym[2] == find_symbol:
return sym[0]