Discussion:
[Scons-users] Technical question abouir --debug=explain
Pierre-Luc Boily
2017-12-19 14:17:52 UTC
Permalink
Hello!

Was doing small test yesterday by changing a cpp file and compiling with
--debug=explain. I realized that the explain argument did not print the
message I was expected on my centos build :

scons: rebuilding
`build/debug/sim/simulator/vr/pbs/fpsm/i86-pc-linux-gnu/pbsfpsm_acreport.o'
because:
`sim/simulator/vr/pbs/fpsm/pbsfpsm_acreport.cpp' is no longer a
dependency
`sim/simulator/vr/pbs/fpsm/pbsfpsm_acreport.cpp' is a new
dependency

I did some test on windows as well, by changing a cpp file too, and I got
this :

scons: rebuilding
`build\debug\sr\sra\src\flatGui\win32\ASRResultObserverUI.obj' because
`sr\sra\src\flatGui\ASRResultObserverUI.cpp' changed

which is the message that I do expect. So, I am wondering if it is the
message on centos makes sense. This message sounds like that the cpp is
being removed. I double-check my pseudo-builder that creates Library and
Program, and the code executed is the same for both centos and windows.

I am using scons 2.5.1 with python 2.7.13

Thx



--
Sent from: http://scons.1086193.n5.nabble.com/Users-f16930.html
Bill Deegan
2017-12-19 14:59:49 UTC
Permalink
That is unexpected.
Is it repeatable?
Post by Pierre-Luc Boily
Hello!
Was doing small test yesterday by changing a cpp file and compiling with
--debug=explain. I realized that the explain argument did not print the
scons: rebuilding
`build/debug/sim/simulator/vr/pbs/fpsm/i86-pc-linux-gnu/
pbsfpsm_acreport.o'
`sim/simulator/vr/pbs/fpsm/pbsfpsm_acreport.cpp' is no longer a
dependency
`sim/simulator/vr/pbs/fpsm/pbsfpsm_acreport.cpp' is a new
dependency
I did some test on windows as well, by changing a cpp file too, and I got
scons: rebuilding
`build\debug\sr\sra\src\flatGui\win32\ASRResultObserverUI.obj' because
`sr\sra\src\flatGui\ASRResultObserverUI.cpp' changed
which is the message that I do expect. So, I am wondering if it is the
message on centos makes sense. This message sounds like that the cpp is
being removed. I double-check my pseudo-builder that creates Library and
Program, and the code executed is the same for both centos and windows.
I am using scons 2.5.1 with python 2.7.13
Thx
--
Sent from: http://scons.1086193.n5.nabble.com/Users-f16930.html
_______________________________________________
Scons-users mailing list
https://pairlist4.pair.net/mailman/listinfo/scons-users
Pierre-Luc Boily
2017-12-19 15:31:25 UTC
Permalink
Yes it is. It must be something with my implementation for sure., I'll dig
more on my scons implementation... It might be related with my
pseudo-builders. I have an implementation on top of Library, SharedLibrary
and Program calls, in order to be able to generated artifacts in the
correct variant dir. The Variant dir given to SConscript looks like
"/svn/products/build/debug/src". Then, my pseudo-builder receives the
variant dir and add a subfolder like that
"/svn/products/build/debug/src/i86-pc-linux-gnu". See
https://pastebin.com/6fTVDnMa. Code executed from pseudo-builders is the
same from windows and centos. So, it might be something elsewhere as
well....
Post by Bill Deegan
That is unexpected.
Is it repeatable?
On Tue, Dec 19, 2017 at 9:17 AM, Pierre-Luc Boily <
Post by Pierre-Luc Boily
Hello!
Was doing small test yesterday by changing a cpp file and compiling with
--debug=explain. I realized that the explain argument did not print the
scons: rebuilding
`build/debug/sim/simulator/vr/pbs/fpsm/i86-pc-linux-gnu/pbsf
psm_acreport.o'
`sim/simulator/vr/pbs/fpsm/pbsfpsm_acreport.cpp' is no longer a
dependency
`sim/simulator/vr/pbs/fpsm/pbsfpsm_acreport.cpp' is a new
dependency
I did some test on windows as well, by changing a cpp file too, and I got
scons: rebuilding
`build\debug\sr\sra\src\flatGui\win32\ASRResultObserverUI.obj' because
`sr\sra\src\flatGui\ASRResultObserverUI.cpp' changed
which is the message that I do expect. So, I am wondering if it is the
message on centos makes sense. This message sounds like that the cpp is
being removed. I double-check my pseudo-builder that creates Library and
Program, and the code executed is the same for both centos and windows.
I am using scons 2.5.1 with python 2.7.13
Thx
--
Sent from: http://scons.1086193.n5.nabble.com/Users-f16930.html
_______________________________________________
Scons-users mailing list
https://pairlist4.pair.net/mailman/listinfo/scons-users
_______________________________________________
Scons-users mailing list
https://pairlist4.pair.net/mailman/listinfo/scons-users
Bill Deegan
2017-12-19 17:07:23 UTC
Permalink
You might also run with

--taskmastertrace=FILE

And look at the generated file with respect to the source and
target(s) involved.


On Tue, Dec 19, 2017 at 10:31 AM, Pierre-Luc Boily <
Post by Pierre-Luc Boily
Yes it is. It must be something with my implementation for sure., I'll
dig more on my scons implementation... It might be related with my
pseudo-builders. I have an implementation on top of Library, SharedLibrary
and Program calls, in order to be able to generated artifacts in the
correct variant dir. The Variant dir given to SConscript looks like
"/svn/products/build/debug/src". Then, my pseudo-builder receives the
variant dir and add a subfolder like that "/svn/products/build/debug/src/i86-pc-linux-gnu".
See https://pastebin.com/6fTVDnMa. Code executed from pseudo-builders
is the same from windows and centos. So, it might be something elsewhere
as well....
Post by Bill Deegan
That is unexpected.
Is it repeatable?
On Tue, Dec 19, 2017 at 9:17 AM, Pierre-Luc Boily <
Post by Pierre-Luc Boily
Hello!
Was doing small test yesterday by changing a cpp file and compiling with
--debug=explain. I realized that the explain argument did not print the
scons: rebuilding
`build/debug/sim/simulator/vr/pbs/fpsm/i86-pc-linux-gnu/pbsf
psm_acreport.o'
`sim/simulator/vr/pbs/fpsm/pbsfpsm_acreport.cpp' is no longer a
dependency
`sim/simulator/vr/pbs/fpsm/pbsfpsm_acreport.cpp' is a new
dependency
I did some test on windows as well, by changing a cpp file too, and I got
scons: rebuilding
`build\debug\sr\sra\src\flatGui\win32\ASRResultObserverUI.obj' because
`sr\sra\src\flatGui\ASRResultObserverUI.cpp' changed
which is the message that I do expect. So, I am wondering if it is the
message on centos makes sense. This message sounds like that the cpp is
being removed. I double-check my pseudo-builder that creates Library and
Program, and the code executed is the same for both centos and windows.
I am using scons 2.5.1 with python 2.7.13
Thx
--
Sent from: http://scons.1086193.n5.nabble.com/Users-f16930.html
_______________________________________________
Scons-users mailing list
https://pairlist4.pair.net/mailman/listinfo/scons-users
_______________________________________________
Scons-users mailing list
https://pairlist4.pair.net/mailman/listinfo/scons-users
_______________________________________________
Scons-users mailing list
https://pairlist4.pair.net/mailman/listinfo/scons-users
Pierre-Luc Boily
2017-12-19 21:01:47 UTC
Permalink
I tried same test on a smaller part of the code to get smaller
tree/traces. I also rework the SConscript to make it simpler, and I don't
see anything shocking.
Tree : https://pastebin.com/iuwKekwD
Trace: https://pastebin.com/KwAieVGE

SConscript :
Import('envService')
envService.validate_supported_platform('posix')
env = envService.get_env32()
env.USE_QT()
env.Library(target = env.libName(),source = ["aiui_controller.cpp",
"aiui_widget_impl.cpp", "aiui_widget.cpp"])

Do you see something unusual?

thx
Post by Bill Deegan
You might also run with
--taskmastertrace=FILE
And look at the generated file with respect to the source and target(s) involved.
On Tue, Dec 19, 2017 at 10:31 AM, Pierre-Luc Boily <
Post by Pierre-Luc Boily
Yes it is. It must be something with my implementation for sure., I'll
dig more on my scons implementation... It might be related with my
pseudo-builders. I have an implementation on top of Library, SharedLibrary
and Program calls, in order to be able to generated artifacts in the
correct variant dir. The Variant dir given to SConscript looks like
"/svn/products/build/debug/src". Then, my pseudo-builder receives the
variant dir and add a subfolder like that "/svn/products/build/debug/src/i86-pc-linux-gnu".
See https://pastebin.com/6fTVDnMa. Code executed from pseudo-builders
is the same from windows and centos. So, it might be something elsewhere
as well....
Post by Bill Deegan
That is unexpected.
Is it repeatable?
On Tue, Dec 19, 2017 at 9:17 AM, Pierre-Luc Boily <
Post by Pierre-Luc Boily
Hello!
Was doing small test yesterday by changing a cpp file and compiling with
--debug=explain. I realized that the explain argument did not print the
scons: rebuilding
`build/debug/sim/simulator/vr/pbs/fpsm/i86-pc-linux-gnu/pbsf
psm_acreport.o'
`sim/simulator/vr/pbs/fpsm/pbsfpsm_acreport.cpp' is no longer a
dependency
`sim/simulator/vr/pbs/fpsm/pbsfpsm_acreport.cpp' is a new
dependency
I did some test on windows as well, by changing a cpp file too, and I got
scons: rebuilding
`build\debug\sr\sra\src\flatGui\win32\ASRResultObserverUI.obj' because
`sr\sra\src\flatGui\ASRResultObserverUI.cpp' changed
which is the message that I do expect. So, I am wondering if it is the
message on centos makes sense. This message sounds like that the cpp is
being removed. I double-check my pseudo-builder that creates Library and
Program, and the code executed is the same for both centos and windows.
I am using scons 2.5.1 with python 2.7.13
Thx
--
Sent from: http://scons.1086193.n5.nabble.com/Users-f16930.html
_______________________________________________
Scons-users mailing list
https://pairlist4.pair.net/mailman/listinfo/scons-users
_______________________________________________
Scons-users mailing list
https://pairlist4.pair.net/mailman/listinfo/scons-users
_______________________________________________
Scons-users mailing list
https://pairlist4.pair.net/mailman/listinfo/scons-users
_______________________________________________
Scons-users mailing list
https://pairlist4.pair.net/mailman/listinfo/scons-users
Bill Deegan
2017-12-19 21:54:56 UTC
Permalink
Is the file itself changing between builds in this case?
Or is it building when it's not changing?
Post by Pierre-Luc Boily
I tried same test on a smaller part of the code to get smaller
tree/traces. I also rework the SConscript to make it simpler, and I don't
see anything shocking.
Tree : https://pastebin.com/iuwKekwD
Trace: https://pastebin.com/KwAieVGE
Import('envService')
envService.validate_supported_platform('posix')
env = envService.get_env32()
env.USE_QT()
env.Library(target = env.libName(),source = ["aiui_controller.cpp",
"aiui_widget_impl.cpp", "aiui_widget.cpp"])
Do you see something unusual?
thx
Post by Bill Deegan
You might also run with
--taskmastertrace=FILE
And look at the generated file with respect to the source and target(s) involved.
On Tue, Dec 19, 2017 at 10:31 AM, Pierre-Luc Boily <
Post by Pierre-Luc Boily
Yes it is. It must be something with my implementation for sure., I'll
dig more on my scons implementation... It might be related with my
pseudo-builders. I have an implementation on top of Library, SharedLibrary
and Program calls, in order to be able to generated artifacts in the
correct variant dir. The Variant dir given to SConscript looks like
"/svn/products/build/debug/src". Then, my pseudo-builder receives the
variant dir and add a subfolder like that "/svn/products/build/debug/src/i86-pc-linux-gnu".
See https://pastebin.com/6fTVDnMa. Code executed from pseudo-builders
is the same from windows and centos. So, it might be something elsewhere
as well....
Post by Bill Deegan
That is unexpected.
Is it repeatable?
On Tue, Dec 19, 2017 at 9:17 AM, Pierre-Luc Boily <
Post by Pierre-Luc Boily
Hello!
Was doing small test yesterday by changing a cpp file and compiling with
--debug=explain. I realized that the explain argument did not print the
scons: rebuilding
`build/debug/sim/simulator/vr/pbs/fpsm/i86-pc-linux-gnu/pbsf
psm_acreport.o'
`sim/simulator/vr/pbs/fpsm/pbsfpsm_acreport.cpp' is no longer a
dependency
`sim/simulator/vr/pbs/fpsm/pbsfpsm_acreport.cpp' is a new
dependency
I did some test on windows as well, by changing a cpp file too, and I got
scons: rebuilding
`build\debug\sr\sra\src\flatGui\win32\ASRResultObserverUI.obj' because
`sr\sra\src\flatGui\ASRResultObserverUI.cpp' changed
which is the message that I do expect. So, I am wondering if it is the
message on centos makes sense. This message sounds like that the cpp is
being removed. I double-check my pseudo-builder that creates Library and
Program, and the code executed is the same for both centos and windows.
I am using scons 2.5.1 with python 2.7.13
Thx
--
Sent from: http://scons.1086193.n5.nabble.com/Users-f16930.html
_______________________________________________
Scons-users mailing list
https://pairlist4.pair.net/mailman/listinfo/scons-users
_______________________________________________
Scons-users mailing list
https://pairlist4.pair.net/mailman/listinfo/scons-users
_______________________________________________
Scons-users mailing list
https://pairlist4.pair.net/mailman/listinfo/scons-users
_______________________________________________
Scons-users mailing list
https://pairlist4.pair.net/mailman/listinfo/scons-users
_______________________________________________
Scons-users mailing list
https://pairlist4.pair.net/mailman/listinfo/scons-users
Bill Deegan
2017-12-19 22:22:34 UTC
Permalink
Here's the logic in question:
removed = [x for x in old_bkids if not x in new_bkids]
in SCons/Node/__init__.py

old_bkids and new_bkids are BuildInfo objects.

You could add some logic there to print the details of each element in
old_bkids and new_bkids and see why it's not seeing that file in new_bkids.?
Post by Bill Deegan
Is the file itself changing between builds in this case?
Or is it building when it's not changing?
On Tue, Dec 19, 2017 at 4:01 PM, Pierre-Luc Boily <
Post by Pierre-Luc Boily
I tried same test on a smaller part of the code to get smaller
tree/traces. I also rework the SConscript to make it simpler, and I don't
see anything shocking.
Tree : https://pastebin.com/iuwKekwD
Trace: https://pastebin.com/KwAieVGE
Import('envService')
envService.validate_supported_platform('posix')
env = envService.get_env32()
env.USE_QT()
env.Library(target = env.libName(),source = ["aiui_controller.cpp",
"aiui_widget_impl.cpp", "aiui_widget.cpp"])
Do you see something unusual?
thx
Post by Bill Deegan
You might also run with
--taskmastertrace=FILE
And look at the generated file with respect to the source and target(s) involved.
On Tue, Dec 19, 2017 at 10:31 AM, Pierre-Luc Boily <
Post by Pierre-Luc Boily
Yes it is. It must be something with my implementation for sure., I'll
dig more on my scons implementation... It might be related with my
pseudo-builders. I have an implementation on top of Library, SharedLibrary
and Program calls, in order to be able to generated artifacts in the
correct variant dir. The Variant dir given to SConscript looks like
"/svn/products/build/debug/src". Then, my pseudo-builder receives the
variant dir and add a subfolder like that "/svn/products/build/debug/src/i86-pc-linux-gnu".
See https://pastebin.com/6fTVDnMa. Code executed from
pseudo-builders is the same from windows and centos. So, it might be
something elsewhere as well....
Post by Bill Deegan
That is unexpected.
Is it repeatable?
On Tue, Dec 19, 2017 at 9:17 AM, Pierre-Luc Boily <
Post by Pierre-Luc Boily
Hello!
Was doing small test yesterday by changing a cpp file and compiling with
--debug=explain. I realized that the explain argument did not print the
scons: rebuilding
`build/debug/sim/simulator/vr/pbs/fpsm/i86-pc-linux-gnu/pbsf
psm_acreport.o'
`sim/simulator/vr/pbs/fpsm/pbsfpsm_acreport.cpp' is no longer a
dependency
`sim/simulator/vr/pbs/fpsm/pbsfpsm_acreport.cpp' is a new
dependency
I did some test on windows as well, by changing a cpp file too, and I got
scons: rebuilding
`build\debug\sr\sra\src\flatGui\win32\ASRResultObserverUI.obj' because
`sr\sra\src\flatGui\ASRResultObserverUI.cpp' changed
which is the message that I do expect. So, I am wondering if it is the
message on centos makes sense. This message sounds like that the cpp is
being removed. I double-check my pseudo-builder that creates Library and
Program, and the code executed is the same for both centos and windows.
I am using scons 2.5.1 with python 2.7.13
Thx
--
Sent from: http://scons.1086193.n5.nabble.com/Users-f16930.html
_______________________________________________
Scons-users mailing list
https://pairlist4.pair.net/mailman/listinfo/scons-users
_______________________________________________
Scons-users mailing list
https://pairlist4.pair.net/mailman/listinfo/scons-users
_______________________________________________
Scons-users mailing list
https://pairlist4.pair.net/mailman/listinfo/scons-users
_______________________________________________
Scons-users mailing list
https://pairlist4.pair.net/mailman/listinfo/scons-users
_______________________________________________
Scons-users mailing list
https://pairlist4.pair.net/mailman/listinfo/scons-users
Pierre-Luc Boily
2017-12-20 16:11:59 UTC
Permalink
Hello,

Not yet looked into __init__.py,, but I found that if I duplicate src files
into variant dir, message print by "--debug=explain" now make sense.
scons: rebuilding
`build/debug/gui/aiui_lib/lib/i86-pc-linux-gnu/aiui_controller.o' because
`build/debug/gui/aiui_lib/lib/aiui_controller.cpp' changed


In SConsctruct :
Changed this
SConscript("gui/aiui_lib/lib/aiui_lib.sc", exports='envService
vcxprojList', variant_dir="build/debug/gui/aiui_lib/lib", duplicate=0)

by this :
SConscript("gui/aiui_lib/lib/aiui_lib.sc", exports='envService
vcxprojList', variant_dir="build/debug/gui/aiui_lib/lib")

To answer you previous question, it is not building if I do not change the
file (as expected)
Post by Bill Deegan
removed = [x for x in old_bkids if not x in new_bkids]
in SCons/Node/__init__.py
old_bkids and new_bkids are BuildInfo objects.
You could add some logic there to print the details of each element in
old_bkids and new_bkids and see why it's not seeing that file in new_bkids.?
Post by Bill Deegan
Is the file itself changing between builds in this case?
Or is it building when it's not changing?
On Tue, Dec 19, 2017 at 4:01 PM, Pierre-Luc Boily <
Post by Pierre-Luc Boily
I tried same test on a smaller part of the code to get smaller
tree/traces. I also rework the SConscript to make it simpler, and I don't
see anything shocking.
Tree : https://pastebin.com/iuwKekwD
Trace: https://pastebin.com/KwAieVGE
Import('envService')
envService.validate_supported_platform('posix')
env = envService.get_env32()
env.USE_QT()
env.Library(target = env.libName(),source = ["aiui_controller.cpp",
"aiui_widget_impl.cpp", "aiui_widget.cpp"])
Do you see something unusual?
thx
Post by Bill Deegan
You might also run with
--taskmastertrace=FILE
And look at the generated file with respect to the source and target(s) involved.
On Tue, Dec 19, 2017 at 10:31 AM, Pierre-Luc Boily <
Post by Pierre-Luc Boily
Yes it is. It must be something with my implementation for sure.,
I'll dig more on my scons implementation... It might be related with my
pseudo-builders. I have an implementation on top of Library, SharedLibrary
and Program calls, in order to be able to generated artifacts in the
correct variant dir. The Variant dir given to SConscript looks like
"/svn/products/build/debug/src". Then, my pseudo-builder receives
the variant dir and add a subfolder like that "/svn/products/build/debug/src/i86-pc-linux-gnu".
See https://pastebin.com/6fTVDnMa. Code executed from
pseudo-builders is the same from windows and centos. So, it might be
something elsewhere as well....
On Tue, Dec 19, 2017 at 9:59 AM, Bill Deegan <
Post by Bill Deegan
That is unexpected.
Is it repeatable?
On Tue, Dec 19, 2017 at 9:17 AM, Pierre-Luc Boily <
Post by Pierre-Luc Boily
Hello!
Was doing small test yesterday by changing a cpp file and compiling with
--debug=explain. I realized that the explain argument did not print the
scons: rebuilding
`build/debug/sim/simulator/vr/pbs/fpsm/i86-pc-linux-gnu/pbsf
psm_acreport.o'
`sim/simulator/vr/pbs/fpsm/pbsfpsm_acreport.cpp' is no longer a
dependency
`sim/simulator/vr/pbs/fpsm/pbsfpsm_acreport.cpp' is a new
dependency
I did some test on windows as well, by changing a cpp file too, and I got
scons: rebuilding
`build\debug\sr\sra\src\flatGui\win32\ASRResultObserverUI.obj' because
`sr\sra\src\flatGui\ASRResultObserverUI.cpp' changed
which is the message that I do expect. So, I am wondering if it is the
message on centos makes sense. This message sounds like that the cpp is
being removed. I double-check my pseudo-builder that creates Library and
Program, and the code executed is the same for both centos and windows.
I am using scons 2.5.1 with python 2.7.13
Thx
--
Sent from: http://scons.1086193.n5.nabble.com/Users-f16930.html
_______________________________________________
Scons-users mailing list
https://pairlist4.pair.net/mailman/listinfo/scons-users
_______________________________________________
Scons-users mailing list
https://pairlist4.pair.net/mailman/listinfo/scons-users
_______________________________________________
Scons-users mailing list
https://pairlist4.pair.net/mailman/listinfo/scons-users
_______________________________________________
Scons-users mailing list
https://pairlist4.pair.net/mailman/listinfo/scons-users
_______________________________________________
Scons-users mailing list
https://pairlist4.pair.net/mailman/listinfo/scons-users
_______________________________________________
Scons-users mailing list
https://pairlist4.pair.net/mailman/listinfo/scons-users
Bill Deegan
2017-12-20 16:22:15 UTC
Permalink
So it's just a problem with debug messaging when duplicate=0?

If you can create a minimum test we can add to our test suite and fix..

On Wed, Dec 20, 2017 at 11:11 AM, Pierre-Luc Boily <
Post by Pierre-Luc Boily
Hello,
Not yet looked into __init__.py,, but I found that if I duplicate src
files into variant dir, message print by "--debug=explain" now make sense.
scons: rebuilding `build/debug/gui/aiui_lib/lib/i86-pc-linux-gnu/aiui_controller.o'
because `build/debug/gui/aiui_lib/lib/aiui_controller.cpp' changed
Changed this
SConscript("gui/aiui_lib/lib/aiui_lib.sc", exports='envService
vcxprojList', variant_dir="build/debug/gui/aiui_lib/lib", duplicate=0)
SConscript("gui/aiui_lib/lib/aiui_lib.sc", exports='envService
vcxprojList', variant_dir="build/debug/gui/aiui_lib/lib")
To answer you previous question, it is not building if I do not change the
file (as expected)
Post by Bill Deegan
removed = [x for x in old_bkids if not x in new_bkids]
in SCons/Node/__init__.py
old_bkids and new_bkids are BuildInfo objects.
You could add some logic there to print the details of each element in
old_bkids and new_bkids and see why it's not seeing that file in new_bkids.?
Post by Bill Deegan
Is the file itself changing between builds in this case?
Or is it building when it's not changing?
On Tue, Dec 19, 2017 at 4:01 PM, Pierre-Luc Boily <
Post by Pierre-Luc Boily
I tried same test on a smaller part of the code to get smaller
tree/traces. I also rework the SConscript to make it simpler, and I don't
see anything shocking.
Tree : https://pastebin.com/iuwKekwD
Trace: https://pastebin.com/KwAieVGE
Import('envService')
envService.validate_supported_platform('posix')
env = envService.get_env32()
env.USE_QT()
env.Library(target = env.libName(),source = ["aiui_controller.cpp",
"aiui_widget_impl.cpp", "aiui_widget.cpp"])
Do you see something unusual?
thx
On Tue, Dec 19, 2017 at 12:07 PM, Bill Deegan <
Post by Bill Deegan
You might also run with
--taskmastertrace=FILE
And look at the generated file with respect to the source and target(s) involved.
On Tue, Dec 19, 2017 at 10:31 AM, Pierre-Luc Boily <
Post by Pierre-Luc Boily
Yes it is. It must be something with my implementation for sure.,
I'll dig more on my scons implementation... It might be related with my
pseudo-builders. I have an implementation on top of Library, SharedLibrary
and Program calls, in order to be able to generated artifacts in the
correct variant dir. The Variant dir given to SConscript looks like
"/svn/products/build/debug/src". Then, my pseudo-builder receives
the variant dir and add a subfolder like that "/svn/products/build/debug/src/i86-pc-linux-gnu".
See https://pastebin.com/6fTVDnMa. Code executed from
pseudo-builders is the same from windows and centos. So, it might be
something elsewhere as well....
On Tue, Dec 19, 2017 at 9:59 AM, Bill Deegan <
Post by Bill Deegan
That is unexpected.
Is it repeatable?
On Tue, Dec 19, 2017 at 9:17 AM, Pierre-Luc Boily <
Post by Pierre-Luc Boily
Hello!
Was doing small test yesterday by changing a cpp file and compiling with
--debug=explain. I realized that the explain argument did not print the
scons: rebuilding
`build/debug/sim/simulator/vr/pbs/fpsm/i86-pc-linux-gnu/pbsf
psm_acreport.o'
`sim/simulator/vr/pbs/fpsm/pbsfpsm_acreport.cpp' is no longer a
dependency
`sim/simulator/vr/pbs/fpsm/pbsfpsm_acreport.cpp' is a new
dependency
I did some test on windows as well, by changing a cpp file too, and I got
scons: rebuilding
`build\debug\sr\sra\src\flatGui\win32\ASRResultObserverUI.obj' because
`sr\sra\src\flatGui\ASRResultObserverUI.cpp' changed
which is the message that I do expect. So, I am wondering if it is the
message on centos makes sense. This message sounds like that the cpp is
being removed. I double-check my pseudo-builder that creates Library and
Program, and the code executed is the same for both centos and windows.
I am using scons 2.5.1 with python 2.7.13
Thx
--
Sent from: http://scons.1086193.n5.nabble.com/Users-f16930.html
_______________________________________________
Scons-users mailing list
https://pairlist4.pair.net/mailman/listinfo/scons-users
_______________________________________________
Scons-users mailing list
https://pairlist4.pair.net/mailman/listinfo/scons-users
_______________________________________________
Scons-users mailing list
https://pairlist4.pair.net/mailman/listinfo/scons-users
_______________________________________________
Scons-users mailing list
https://pairlist4.pair.net/mailman/listinfo/scons-users
_______________________________________________
Scons-users mailing list
https://pairlist4.pair.net/mailman/listinfo/scons-users
_______________________________________________
Scons-users mailing list
https://pairlist4.pair.net/mailman/listinfo/scons-users
_______________________________________________
Scons-users mailing list
https://pairlist4.pair.net/mailman/listinfo/scons-users
Pierre-Luc Boily
2017-12-20 16:42:20 UTC
Permalink
It might be only a problem with debug messaging knowing that :
1 - All my executable runs fine
2 - SCons not rebuilding anything if I have no file changes (as expected)
3 - SCons is rebuilding only what is necessary when I change one file (as
expected)

I created this post because the message printed was worrying me, I thought
that it might be related with bad implementation on my end. Also, I am
still wondering why debug message is fine on windows but not on centos
6.7. Is it still relevant to dig in __init__.py as you point me out in
previous post? Also, could you point me out some test exemple for the test
suite?

thx
Post by Bill Deegan
So it's just a problem with debug messaging when duplicate=0?
If you can create a minimum test we can add to our test suite and fix..
On Wed, Dec 20, 2017 at 11:11 AM, Pierre-Luc Boily <
Post by Pierre-Luc Boily
Hello,
Not yet looked into __init__.py,, but I found that if I duplicate src
files into variant dir, message print by "--debug=explain" now make sense.
scons: rebuilding `build/debug/gui/aiui_lib/lib/
i86-pc-linux-gnu/aiui_controller.o' because
`build/debug/gui/aiui_lib/lib/aiui_controller.cpp' changed
Changed this
SConscript("gui/aiui_lib/lib/aiui_lib.sc", exports='envService
vcxprojList', variant_dir="build/debug/gui/aiui_lib/lib", duplicate=0)
SConscript("gui/aiui_lib/lib/aiui_lib.sc", exports='envService
vcxprojList', variant_dir="build/debug/gui/aiui_lib/lib")
To answer you previous question, it is not building if I do not change
the file (as expected)
Post by Bill Deegan
removed = [x for x in old_bkids if not x in new_bkids]
in SCons/Node/__init__.py
old_bkids and new_bkids are BuildInfo objects.
You could add some logic there to print the details of each element in
old_bkids and new_bkids and see why it's not seeing that file in new_bkids.?
Post by Bill Deegan
Is the file itself changing between builds in this case?
Or is it building when it's not changing?
On Tue, Dec 19, 2017 at 4:01 PM, Pierre-Luc Boily <
Post by Pierre-Luc Boily
I tried same test on a smaller part of the code to get smaller
tree/traces. I also rework the SConscript to make it simpler, and I don't
see anything shocking.
Tree : https://pastebin.com/iuwKekwD
Trace: https://pastebin.com/KwAieVGE
Import('envService')
envService.validate_supported_platform('posix')
env = envService.get_env32()
env.USE_QT()
env.Library(target = env.libName(),source = ["aiui_controller.cpp",
"aiui_widget_impl.cpp", "aiui_widget.cpp"])
Do you see something unusual?
thx
On Tue, Dec 19, 2017 at 12:07 PM, Bill Deegan <
Post by Bill Deegan
You might also run with
--taskmastertrace=FILE
And look at the generated file with respect to the source and target(s) involved.
On Tue, Dec 19, 2017 at 10:31 AM, Pierre-Luc Boily <
Post by Pierre-Luc Boily
Yes it is. It must be something with my implementation for sure.,
I'll dig more on my scons implementation... It might be related with my
pseudo-builders. I have an implementation on top of Library, SharedLibrary
and Program calls, in order to be able to generated artifacts in the
correct variant dir. The Variant dir given to SConscript looks like
"/svn/products/build/debug/src". Then, my pseudo-builder receives
the variant dir and add a subfolder like that "/svn/products/build/debug/src/i86-pc-linux-gnu".
See https://pastebin.com/6fTVDnMa. Code executed from
pseudo-builders is the same from windows and centos. So, it might be
something elsewhere as well....
On Tue, Dec 19, 2017 at 9:59 AM, Bill Deegan <
Post by Bill Deegan
That is unexpected.
Is it repeatable?
On Tue, Dec 19, 2017 at 9:17 AM, Pierre-Luc Boily <
Post by Pierre-Luc Boily
Hello!
Was doing small test yesterday by changing a cpp file and compiling with
--debug=explain. I realized that the explain argument did not print the
scons: rebuilding
`build/debug/sim/simulator/vr/pbs/fpsm/i86-pc-linux-gnu/pbsf
psm_acreport.o'
`sim/simulator/vr/pbs/fpsm/pbsfpsm_acreport.cpp' is no longer a
dependency
`sim/simulator/vr/pbs/fpsm/pbsfpsm_acreport.cpp' is a new
dependency
I did some test on windows as well, by changing a cpp file too, and I got
scons: rebuilding
`build\debug\sr\sra\src\flatGui\win32\ASRResultObserverUI.obj' because
`sr\sra\src\flatGui\ASRResultObserverUI.cpp' changed
which is the message that I do expect. So, I am wondering if it is the
message on centos makes sense. This message sounds like that the cpp is
being removed. I double-check my pseudo-builder that creates Library and
Program, and the code executed is the same for both centos and windows.
I am using scons 2.5.1 with python 2.7.13
Thx
--
Sent from: http://scons.1086193.n5.nabble.com/Users-f16930.html
_______________________________________________
Scons-users mailing list
https://pairlist4.pair.net/mailman/listinfo/scons-users
_______________________________________________
Scons-users mailing list
https://pairlist4.pair.net/mailman/listinfo/scons-users
_______________________________________________
Scons-users mailing list
https://pairlist4.pair.net/mailman/listinfo/scons-users
_______________________________________________
Scons-users mailing list
https://pairlist4.pair.net/mailman/listinfo/scons-users
_______________________________________________
Scons-users mailing list
https://pairlist4.pair.net/mailman/listinfo/scons-users
_______________________________________________
Scons-users mailing list
https://pairlist4.pair.net/mailman/listinfo/scons-users
_______________________________________________
Scons-users mailing list
https://pairlist4.pair.net/mailman/listinfo/scons-users
_______________________________________________
Scons-users mailing list
https://pairlist4.pair.net/mailman/listinfo/scons-users
Bill Deegan
2017-12-20 17:09:57 UTC
Permalink
Here's the wiki page: https://github.com/SCons/scons/wiki/TestingMethodology

It would be useful to figure out why it's yielding the odd messaging.


On Wed, Dec 20, 2017 at 11:42 AM, Pierre-Luc Boily <
Post by Pierre-Luc Boily
1 - All my executable runs fine
2 - SCons not rebuilding anything if I have no file changes (as expected)
3 - SCons is rebuilding only what is necessary when I change one file (as
expected)
I created this post because the message printed was worrying me, I thought
that it might be related with bad implementation on my end. Also, I am
still wondering why debug message is fine on windows but not on centos
6.7. Is it still relevant to dig in __init__.py as you point me out in
previous post? Also, could you point me out some test exemple for the test
suite?
thx
Post by Bill Deegan
So it's just a problem with debug messaging when duplicate=0?
If you can create a minimum test we can add to our test suite and fix..
On Wed, Dec 20, 2017 at 11:11 AM, Pierre-Luc Boily <
Post by Pierre-Luc Boily
Hello,
Not yet looked into __init__.py,, but I found that if I duplicate src
files into variant dir, message print by "--debug=explain" now make sense.
scons: rebuilding `build/debug/gui/aiui_lib/lib/
i86-pc-linux-gnu/aiui_controller.o' because
`build/debug/gui/aiui_lib/lib/aiui_controller.cpp' changed
Changed this
SConscript("gui/aiui_lib/lib/aiui_lib.sc", exports='envService
vcxprojList', variant_dir="build/debug/gui/aiui_lib/lib", duplicate=0)
SConscript("gui/aiui_lib/lib/aiui_lib.sc", exports='envService
vcxprojList', variant_dir="build/debug/gui/aiui_lib/lib")
To answer you previous question, it is not building if I do not change
the file (as expected)
Post by Bill Deegan
removed = [x for x in old_bkids if not x in new_bkids]
in SCons/Node/__init__.py
old_bkids and new_bkids are BuildInfo objects.
You could add some logic there to print the details of each element in
old_bkids and new_bkids and see why it's not seeing that file in new_bkids.?
Post by Bill Deegan
Is the file itself changing between builds in this case?
Or is it building when it's not changing?
On Tue, Dec 19, 2017 at 4:01 PM, Pierre-Luc Boily <
Post by Pierre-Luc Boily
I tried same test on a smaller part of the code to get smaller
tree/traces. I also rework the SConscript to make it simpler, and I don't
see anything shocking.
Tree : https://pastebin.com/iuwKekwD
Trace: https://pastebin.com/KwAieVGE
Import('envService')
envService.validate_supported_platform('posix')
env = envService.get_env32()
env.USE_QT()
env.Library(target = env.libName(),source = ["aiui_controller.cpp",
"aiui_widget_impl.cpp", "aiui_widget.cpp"])
Do you see something unusual?
thx
On Tue, Dec 19, 2017 at 12:07 PM, Bill Deegan <
Post by Bill Deegan
You might also run with
--taskmastertrace=FILE
And look at the generated file with respect to the source and target(s) involved.
On Tue, Dec 19, 2017 at 10:31 AM, Pierre-Luc Boily <
Post by Pierre-Luc Boily
Yes it is. It must be something with my implementation for sure.,
I'll dig more on my scons implementation... It might be related with my
pseudo-builders. I have an implementation on top of Library, SharedLibrary
and Program calls, in order to be able to generated artifacts in the
correct variant dir. The Variant dir given to SConscript looks like
"/svn/products/build/debug/src". Then, my pseudo-builder receives
the variant dir and add a subfolder like that "/svn/products/build/debug/src/i86-pc-linux-gnu".
See https://pastebin.com/6fTVDnMa. Code executed from
pseudo-builders is the same from windows and centos. So, it might be
something elsewhere as well....
On Tue, Dec 19, 2017 at 9:59 AM, Bill Deegan <
Post by Bill Deegan
That is unexpected.
Is it repeatable?
On Tue, Dec 19, 2017 at 9:17 AM, Pierre-Luc Boily <
Post by Pierre-Luc Boily
Hello!
Was doing small test yesterday by changing a cpp file and compiling with
--debug=explain. I realized that the explain argument did not print the
scons: rebuilding
`build/debug/sim/simulator/vr/pbs/fpsm/i86-pc-linux-gnu/pbsf
psm_acreport.o'
`sim/simulator/vr/pbs/fpsm/pbsfpsm_acreport.cpp' is
no longer a
dependency
`sim/simulator/vr/pbs/fpsm/pbsfpsm_acreport.cpp' is a new
dependency
I did some test on windows as well, by changing a cpp file too, and I got
scons: rebuilding
`build\debug\sr\sra\src\flatGui\win32\ASRResultObserverUI.obj' because
`sr\sra\src\flatGui\ASRResultObserverUI.cpp' changed
which is the message that I do expect. So, I am wondering if it is the
message on centos makes sense. This message sounds like that the cpp is
being removed. I double-check my pseudo-builder that creates Library and
Program, and the code executed is the same for both centos and windows.
I am using scons 2.5.1 with python 2.7.13
Thx
--
Sent from: http://scons.1086193.n5.nabble.com/Users-f16930.html
_______________________________________________
Scons-users mailing list
https://pairlist4.pair.net/mailman/listinfo/scons-users
_______________________________________________
Scons-users mailing list
https://pairlist4.pair.net/mailman/listinfo/scons-users
_______________________________________________
Scons-users mailing list
https://pairlist4.pair.net/mailman/listinfo/scons-users
_______________________________________________
Scons-users mailing list
https://pairlist4.pair.net/mailman/listinfo/scons-users
_______________________________________________
Scons-users mailing list
https://pairlist4.pair.net/mailman/listinfo/scons-users
_______________________________________________
Scons-users mailing list
https://pairlist4.pair.net/mailman/listinfo/scons-users
_______________________________________________
Scons-users mailing list
https://pairlist4.pair.net/mailman/listinfo/scons-users
_______________________________________________
Scons-users mailing list
https://pairlist4.pair.net/mailman/listinfo/scons-users
_______________________________________________
Scons-users mailing list
https://pairlist4.pair.net/mailman/listinfo/scons-users
s***@triad.rr.com
2017-12-22 16:45:22 UTC
Permalink
I have the following code

myBld = Builder(action = udb_precompile,
suffix='.c',
src_suffix='.sc',
emitter = udb_emitter)
rootEnv.Append( BUILDERS = {'UDBPrep' : myBld } )

I call it like so:
newlyCreatedTargets = UDBPrep(Glob('*.sc'))

The builder function simply calls a script with each source as a parameter and the emitter simply adds the secondary target that is also created ("*.bnd" suffix) by the script using target.append(). The target list ends up like this:

source=[files.sc, file2.sc, file3.sc]
target=[file1.c, file1.bnd, file2.bnd, file3,bnd]

as you can see, I don't have all my *.c targets in the target list - just the first one (they do get created by the script). If I call the builder individually for each source file it works perfect but I take a performance hit for this. Any ideas?

Thanks in advance!!!!

Spencer
Bill Deegan
2017-12-22 18:02:39 UTC
Permalink
Can you share udb_precompile?
Also please share your emitter.
Post by s***@triad.rr.com
I have the following code
myBld = Builder(action = udb_precompile,
suffix='.c',
src_suffix='.sc',
emitter = udb_emitter)
rootEnv.Append( BUILDERS = {'UDBPrep' : myBld } )
newlyCreatedTargets = UDBPrep(Glob('*.sc'))
The builder function simply calls a script with each source as a parameter
and the emitter simply adds the secondary target that is also created
("*.bnd" suffix) by the script using target.append(). The target list ends
source=[files.sc, file2.sc, file3.sc]
target=[file1.c, file1.bnd, file2.bnd, file3,bnd]
as you can see, I don't have all my *.c targets in the target list - just
the first one (they do get created by the script). If I call the builder
individually for each source file it works perfect but I take a performance
hit for this. Any ideas?
Thanks in advance!!!!
Spencer
_______________________________________________
Scons-users mailing list
https://pairlist4.pair.net/mailman/listinfo/scons-users
s***@triad.rr.com
2017-12-27 19:04:34 UTC
Permalink
Post by Bill Deegan
Can you share udb_precompile?
Also please share your emitter.
On Fri,
Sorry for the delay - holidays and all. The builder used to create a script file on the fly with all the sources and commands and then execute that; saving lots of time. But once I added the emitter, the targets are wrong if I pass more than one source file to the builder. So now I execute the builder for each source in a for-in loop.

def udb_precompile( target, source, env ):
stringTargets=', '.join(map(lambda f: str(f), target))
stringSources=', '.join(map(lambda f: str(f), source))
myDebugPrint("udb precompile parameters:",target=stringTargets, source=stringSources)
######################
# target isnt real here - emiiter below really modifies it
######################
for udbFile in source:
rootPath,fileName = os.path.split(str(udbFile))
rootName,suffix = os.path.splitext(fileName)
udbPackageName = dirname(str(udbFile))+"/"+rootName
udbBindFileName = dirname(str(udbFile))+"/"+ rootName + ".bnd"
myFileName = str(udbFile)
myDebugPrint("=======>>> UDB Precompiling ===>>> ", myFileName=myFileName )
subprocess.call([ '/home/db2inst1/sql_udb_prep', myFileName, udbPackageName, udbBindFileName, str(uuid.uuid4())])

return None

def udb_emitter( target, source, env ):
#Check empty sources here - emitter will see it before the builder
if 0 == len(source):
print("UDBPrepcompile called without sources - probably an error in your SConscript")
sys.exit(-1)
freshStart = True
for udbFile in source:
rootPath,fileName = os.path.split(str(udbFile))
rootName,suffix = os.path.splitext(fileName)
udbBindFileName = rootName+".bnd"
myDebugPrint("=======>>> UDB Emitter ===>>> ", udbBindFileName=udbBindFileName, udbfile=str(udbFile) )
target.append(udbBindFileName)

return target, source
Post by Bill Deegan
Can you share udb_precompile?
Also please share your emitter.
Post by s***@triad.rr.com
I have the following code
myBld = Builder(action = udb_precompile,
suffix='.c',
src_suffix='.sc',
emitter = udb_emitter)
rootEnv.Append( BUILDERS = {'UDBPrep' : myBld } )
newlyCreatedTargets = UDBPrep(Glob('*.sc'))
The builder function simply calls a script with each source as a parameter
and the emitter simply adds the secondary target that is also created
("*.bnd" suffix) by the script using target.append(). The target list ends
source=[files.sc, file2.sc, file3.sc]
target=[file1.c, file1.bnd, file2.bnd, file3,bnd]
as you can see, I don't have all my *.c targets in the target list - just
the first one (they do get created by the script). If I call the builder
individually for each source file it works perfect but I take a performance
hit for this. Any ideas?
Thanks in advance!!!!
Spencer
_______________________________________________
Scons-users mailing list
https://pairlist4.pair.net/mailman/listinfo/scons-users
Loading...