Closed lnarmour closed 1 year ago
This was very useful. One small fix (in the explanation above): case inconsistency in the "two new commands" listed above: GenerateMakefile --> generateMakefile
Yes, the java functions are named "GenerateMakefile" but the corresponding compiler script commands are "generateMakefile".
Previously
generateVerificationCode
andgenerateWriteC
did not work together because they both use the sameeval_
prefix in the generated code. Now the verification code uses the prefixeval_verify_
instead.Previously
generateMakefile
would produce a Makefile that looked something like this:and when you run
make
, only the plain and check targets are built. You have to manually runmake verify
to have it also build the verification code (if it was generated). But if you haven't generated the verification code, and try to runmake verify
then compilation will fail (obviously) because there are no C files for the verification code.I don't think it makes sense to put verification targets in the generated Makefile if
generateVerificationCode
has not also been run. However, there is not a good way to determine ifgenerateVerificationCode
has been run because the system does not really keep track of state during the execution of command scripts. Instead, now this can be controlled with an additional parameter to thegenerateMakefile
command.There are two new commands (with the following signatures):
The default behavior is to generate no verification targets/commands in the Makefile if withVerification is not specified.
Default behavior (no verification targets)
This command...
will generate a Makefile like this:
How to generate verification targets
This command passing
withVerification
as true...will generate a Makefile like this: