Open fruffy opened 7 months ago
Why is the p4test
assumed to be always present? Or is it just that p4test
does not have any dependencies that are also not dependencies of the "core" used by all backends?
Why is the
p4test
assumed to be always present? Or is it just thatp4test
does not have any dependencies that are also not dependencies of the "core" used by all backends?
Yes, p4test does not have any non-core dependencies (except the control-plane maybe). We could make it optional too but then we only have gtest
.
We could make it optional too but then we only have
gtest
.
There is already a ENABLE_P4TEST
option. So presumably it can be disabled already.
Of course, building without p4test makes the test suite much less useful, but I could see a downstream backend disabling it just to make the builds a bit faster.
Yes, p4test does not have any non-core dependencies (except the control-plane maybe). We could make it optional too but then we only have
gtest
.
I would probably vote to have control-plane dependency optional, if possible. As control-plane currently requires protobuf and it's ok for a downstream project to have completely separate controlplane
From the conversation it seems we are heading to disable the control plane dependencies which we install for p4test which is a non-core dependency. And also if we could disable other dependencies which are backend specific am I correct?
The relevant issue for this problem is https://github.com/p4lang/p4c/issues/4420. This requires adding checks for every back end and code that depends on the control plane.
Do not force users to install more than necessary if they only want to use one particular part of the compiler.