-
Notifications
You must be signed in to change notification settings - Fork 277
Update generate_vcxproj to work with current source tree #4678
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
Would it be easy to run and briefly verify the function of this script in our Win32 CI? |
Doable, if we are ok with increasing the Windows build time (Travis usually takes the most time, so it would likely be ok). I'll add a commit taking care of this. |
@@ -16,6 +16,9 @@ function doit { | |||
for dir in $dirs ; do | |||
sources="`(cd $dest/src/$dir; make sources)`" | |||
for s in $sources ; do | |||
if [ "$s" = "goto_instrument_main.cpp" ] && [ "$s" != "${1}_main.cpp" ] ; then | |||
continue |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The first conjunct isn't subsumed by the second?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We want to continue
if seeing goto_instrument_main.cpp
while not actually building goto-instrument.vcxproj
- which actually tells me I still need to fix this and change the second conjunct to [ "$1" != "goto-instrument" ]
... will fix.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Very minor nit pick on inconsistent use of ${blah}
versus $blah
?
I am quite worried about the ever-slower CI... |
We could run it in parallel, but I don't know how/whether we can add more CodeBuild jobs. |
The Windows build is now failing in an expected way, PR to fix this will follow the next hours. |
fix for handling of wchars on windows in getting the directory name [blocks: #4678]
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
✔️
Passed Diffblue compatibility checks (cbmc commit: 3d0d151).
Build URL: https://travis-ci.com/diffblue/test-gen/builds/113716934
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks reasonable to me, so I'm happy for this to go in as is. The one nit pick is very minor, so I don't mind if you ignore it.
A more general question: Rather than having our own script to generate the project file, and effectively having yet another parallel build system (in the sense that its another script that has to be told about directories, various dependencies, etc) - can we just use CMake to geneerate the Visual Studio project file?
@@ -16,6 +16,9 @@ function doit { | |||
for dir in $dirs ; do | |||
sources="`(cd $dest/src/$dir; make sources)`" | |||
for s in $sources ; do | |||
if [ "$s" = "goto_instrument_main.cpp" ] && [ "$s" != "${1}_main.cpp" ] ; then | |||
continue |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Very minor nit pick on inconsistent use of ${blah}
versus $blah
?
1) We have multiple source files with the same basename, and thus need to instruct Visual Studio not to put build artefacts into a single directory. 2) Directory dependencies have changed. 3) Specifically, cbmc now also depends on (parts of) goto-instrument; yet we must not include goto_instrument_main.cpp in the CBMC build as it would cause duplicate main functions. 4) Set PlatformToolset in project file to make sure the project can be used with msbuild.
Build the Visual Studio project file and (re-)build CBMC using that project file via msbuild.
I think that's a route worth exploring, but does require more work. I'd prefer to make it part of my yet-to-be-completed work in #4300, which requires me experimenting with Windows a lot more. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
✔️
Passed Diffblue compatibility checks (cbmc commit: 6c2d601).
Build URL: https://travis-ci.com/diffblue/test-gen/builds/113745591
to instruct Visual Studio not to put build artefacts into a single
directory.
yet we must not include goto_instrument_main.cpp in the CBMC build as it
would cause duplicate main functions.
json$(LIBEXT) entry in CBMC's Makefile.