[Scons-users] download builder - tips

Philipp Kraus philipp.kraus at flashpixx.de
Wed Apr 10 10:16:24 EDT 2013



Am 07.04.2013 um 02:31 schrieb Philipp Kraus:


>

> Am 07.04.2013 um 02:25 schrieb William Deegan:

>

>> Phil,

>> On Apr 6, 2013, at 5:21 PM, Philipp Kraus <philipp.kraus at flashpixx.de> wrote:

>>

>>>

>>> Am 07.04.2013 um 01:59 schrieb William Deegan:

>>>

>>>> Phil,

>>>>

>>>> Sorry my mistake, I thought you were pointing at the whole project.

>>>

>>> no problem, I don't want to create for each script dir an own repo, it is a little bit overkill :-)

>>>

>>>> Looks like the problem is that you are adding directories to the list of targets in your Unpack emitter.

>>>> Directories depend on their contents by default, so I believe that's what's causing your issue.

>>>>

>>>> If you add:

>>>> target = [x for x in target if not x.endswith('/')]

>>>>

>>>> Before your:

>>>> return target,source

>>>> in your __emitter.

>>>>

>>>> The problem should go away.

>>>

>>> thanks, great, works fine, but imho it must be x.endswith(os.path.sep), mustn't it

>>> for correct path seperator names?

>>

>> It depends on the list command for your unpacking tools. So it's possible it's OS independent.

>> Since that list is just the output from such.

>

> Yes, so I use the os.path.sep and now I will put the Windows support in it (7zip, winrar, winzip)

> Thx


I have checked my target list, the list, which is created by the unpacking tool can be stored a file- or dirname
more than one, so the target list is not unique.
So I do before the return call in the emitter list(set(target)) for uniquifing my target list.

But I get a warning if I add my builder to the environment:
No dependency generated for file: <eg stdlib.h>

My emitter get's the filelist of an tgz file, wich stores *.c and *.h files, after that I push the list
to env.SharedLibrary. Scons compiles all *.c files and calls the linker, the DLL is build and
seems to be working, but I would like to remove the warning.

At the moment my emitter works like this:

*.tgz => unpack emitter list files in the archiv => list is pushed to SharedLibrary

the builder extract the files


If I write Scons code eg

env = Environment( tool=["default", "unpack"] )
env.SharedLibrary("testlib", Glob("src/*.c"))

the error is occured, if I change the the first line to

env = Environment( tool=["default"] )

no error is shown. So IMHO I have create an error in my builder code, does anybody send my
a helpfull tip, to search the error?

Thx

Phil

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://four.pairlist.net/pipermail/scons-users/attachments/20130410/4be74b3f/attachment.html>


More information about the Scons-users mailing list