Browse Source

SCons: allow set object files in DefineGroup

The source files can be the raw file names end with .c or .o. So return
the raw file names is more flexible than wrap them with Object.
Grissiom 10 years ago
parent
commit
767720c1f7
1 changed files with 3 additions and 2 deletions
  1. 3 2
      tools/building.py

+ 3 - 2
tools/building.py

@@ -364,9 +364,10 @@ def DefineGroup(name, src, depend, **parameters):
     if group.has_key('LIBPATH'):
     if group.has_key('LIBPATH'):
         Env.Append(LIBPATH = group['LIBPATH'])
         Env.Append(LIBPATH = group['LIBPATH'])
 
 
-    objs = Env.Object(group['src'])
     if group.has_key('LIBRARY'):
     if group.has_key('LIBRARY'):
-        objs = Env.Library(name, objs)
+        objs = Env.Library(name, group['src'])
+    else:
+        objs = group['src']
 
 
     # merge group 
     # merge group 
     for g in Projects:
     for g in Projects: