This is an archive of the discontinued LLVM Phabricator instance.

Make sure z3 can be disabled from outside, even if detected on the system.
AcceptedPublic

Authored by LocutusOfBorg on Apr 13 2020, 8:42 AM.

Details

Reviewers
lebedev.ri
Summary

This fix build failures e.g. in Ubuntu, where z3 is disabled, but we don't want support for it because z3 is not in main archive

Diff Detail

Event Timeline

LocutusOfBorg created this revision.Apr 13 2020, 8:42 AM
Herald added projects: Restricted Project, Restricted Project. · View Herald TranscriptJan 19 2023, 1:06 AM
lebedev.ri accepted this revision.Jan 19 2023, 8:53 AM
lebedev.ri added a subscriber: lebedev.ri.

Makes sense to me.

This revision is now accepted and ready to land.Jan 19 2023, 8:53 AM

Are you sure about this? FWIU right now the default is to "use Z3 if available". If I read the patch right, it will be "default to requiring Z3, unless explicitly disabled". Not that I mind but I suppose it's a semantic change.

I'm not cmake expert but does

option(LLVM_ENABLE_Z3_SOLVER
  "Enable Support for the Z3 constraint solver in LLVM."
  ON
)

means that it's enabled by default?

If so, I'd suggest making it disabled by default.