summaryrefslogtreecommitdiff
path: root/tools
diff options
context:
space:
mode:
Diffstat (limited to 'tools')
-rw-r--r--tools/kamek.py15
1 files changed, 9 insertions, 6 deletions
diff --git a/tools/kamek.py b/tools/kamek.py
index 72dfcb0..e23f57f 100644
--- a/tools/kamek.py
+++ b/tools/kamek.py
@@ -246,7 +246,8 @@ class KamekModule(object):
# load the module data
self.modulePath = os.path.normpath(filename)
self.moduleName = os.path.basename(self.modulePath)
- self.moduleDir = os.path.dirname(self.modulePath)
+ #self.moduleDir = os.path.dirname(self.modulePath)
+ self.moduleDir = 'processed'
with open(self.modulePath, 'r') as f:
self.rawData = f.read()
@@ -279,7 +280,9 @@ class KamekBuilder(object):
self._set_config(config)
- self._configTempDir = tempfile.mkdtemp()
+ #self._configTempDir = tempfile.mkdtemp()
+ self._configTempDir = 'tmp'
+ os.mkdir('tmp')
print_debug('Temp files for this configuration are in: '+self._configTempDir)
if 'dynamic_link' in self._config and self._config['dynamic_link']:
@@ -486,7 +489,7 @@ class KamekBuilder(object):
outname = 'object.plf' if self.dynamic_link_base else 'object.bin'
self._currentOutFile = '%s/%s_%s' % (self._outDir, nice_name, outname)
- ld_command = ['%s%s-ld' % (gcc_path, gcc_type), '-L.']
+ ld_command = ['%s%s-ld.exe' % (gcc_path, gcc_type), '-L.']
ld_command.append('-o')
ld_command.append(self._currentOutFile)
if self.dynamic_link_base:
@@ -566,14 +569,14 @@ class KamekBuilder(object):
# next up, run it through c++filt
print_debug('Running c++filt')
- p = subprocess.Popen(gcc_type + '-c++filt', stdin=subprocess.PIPE, stdout=subprocess.PIPE)
+ p = subprocess.Popen(gcc_type + '-c++filt.exe', stdin=subprocess.PIPE, stdout=subprocess.PIPE)
symbolNameList = [sym[1] for sym in self._symbols]
filtResult = p.communicate('\n'.join(symbolNameList))
filteredSymbols = filtResult[0].split('\n')
for sym, filt in zip(self._symbols, filteredSymbols):
- sym.append(filt)
+ sym.append(filt.strip())
print_debug('Done. All symbols complete.')
print_debug('Generated code is at 0x%08X .. 0x%08X' % (self._codeStart, self._codeEnd - 4))
@@ -658,7 +661,7 @@ class KamekProject(object):
# load the project data
self.projectPath = os.path.abspath(filename)
self.projectName = os.path.basename(self.projectPath)
- self.projectDir = os.path.dirname(self.projectPath)
+ self.projectDir = '' #os.path.dirname(self.projectPath)
with open(self.projectPath, 'r') as f:
self.rawData = f.read()