Can generate targets in subdirectories.

pull/15/head
Jussi Pakkanen 12 years ago
parent 223d468355
commit 0783c7ff97
  1. 2
      interpreter.py
  2. 3
      shellgenerator.py

@ -138,7 +138,7 @@ class Executable(BuildTarget):
class StaticLibrary(BuildTarget):
def __init__(self, name, subdir, sources, environment):
BuildTarget.__init__(self, subdir, name, sources)
BuildTarget.__init__(self, name, subdir, sources)
prefix = environment.get_static_lib_prefix()
suffix = environment.get_static_lib_suffix()
self.filename = prefix + self.name + '.' + suffix

@ -151,7 +151,8 @@ echo Run compile.sh before this or bad things will happen.
break
if compiler is None:
raise RuntimeError('No specified compiler can handle file ' + src)
abs_src = os.path.join(self.environment.get_source_dir(), src)
abs_src = os.path.join(self.environment.get_source_dir(), target.get_source_subdir(), src)
print(target.get_source_subdir())
abs_obj = os.path.join(self.get_target_dir(target), src)
abs_obj += '.' + self.environment.get_object_suffix()
commands = []

Loading…
Cancel
Save