Re: C/C++ Object Suffix to include source names

Hua Yanghao <[email protected]>
Newsgroups gmane.comp.programming.tools.scons.user
Message-ID <CAPTzt1CqxKtP0dxEhfbJ_QGw-+27FP0zhZKZSrH2K5WY+xjdMg@mail.gmail.com>
This is an example for anyone who might have a similar issue, not sure
if this is the best way to do it in scons.
I have to use the variant_dir passed explicity through env, any way to
get it out of the FS node object?

  1 import os
                                                        | |
  2
                                                        | |
  3 def targets_change(targets, sources, env):
                                                        | |
  4     new_targets = []
                                                        | |
  5     build_dir = env['USW_BUILD_ROOT']
                                                        | |
  6     for i in sources:
                                                        | |
  7         new = i.path +'.o'
                                                        | |
  8         new = os.path.relpath(new, build_dir)
                                                        | |
  9         new_targets.append(new)
                                                        | |
 10     return new_targets, sources
_______________________________________________
Scons-users mailing list
[email protected]
https://pairlist4.pair.net/mailman/listinfo/scons-users
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.