[Scons-users] Problem with variant_dir on cygwin

Bogdan Tenea btenea at ixiacom.com
Mon Sep 23 16:09:53 EDT 2013


Hello

I'm using a include "test.hpp" from test.cpp. I've now tried with env['CPPPATH'] and it does not work.
I think it's a Cygwin only related issue - I tried running with debug and on Cygwin I get:

vmwareuser at vmware-xpspih /cygdrive/c/test
$ scons --debug=duplicate
scons: Reading SConscript files ...
dup: relinking variant 'build/SConscript' from 'src/SConscript'
scons: done reading SConscript files.
scons: Building targets ...
dup: relinking variant 'build/test.cpp' from 'src/test.cpp'
g++ -o build/test.os -c -fPIC build/test.cpp
build/test.cpp:1:0: warning: -fPIC ignored for target (all code is position independent) [enabled by default]
build/test.cpp:1:20: fatal error: test.hpp: No such file or directory
compilation terminated.
scons: *** [build/test.os] Error 1
scons: building terminated because of errors.

Exactly the same script I tried to run on a Linux system and it worked just fine as it duplicated the header:

btenea at btenealinux:~/perforce/btenealinux/test$ scons --debug=duplicate
scons: Reading SConscript files ...
dup: relinking variant 'build/SConscript' from 'src/SConscript'
scons: done reading SConscript files.
scons: Building targets ...
dup: relinking variant 'build/test.cpp' from 'src/test.cpp'
dup: relinking variant 'build/test.hpp' from 'src/test.hpp'
g++ -o build/test.os -c -fPIC build/test.cpp
g++ -o build/libtest.so -shared build/test.os
scons: done building targets.

I've also dug a little in the dependency tree (--debug=stree) and on cygwin test.hpp does not appear and on Linux it does.
With duplicate=0 it seems to be able to build even if the dependency tree is broken because the includes are there.

Regards,

Bogdan Tenea
Senior Software Engineer II
Ixia RO Stack Manager Dev

-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://four.pairlist.net/pipermail/scons-users/attachments/20130923/0e149951/attachment.htm


More information about the Scons-users mailing list