@@ -22,16 +22,16 @@ template <typename Flavor, typename Circuit = typename Flavor::CircuitBuilder>
2222Circuit _compute_circuit (const std::string& bytecode_path, const std::string& witness_path)
2323{
2424 uint32_t honk_recursion = 0 ;
25- if constexpr (IsAnyOf<Flavor,
26- UltraFlavor,
27- UltraKeccakFlavor,
28- UltraStarknetFlavor,
29- UltraKeccakZKFlavor,
30- UltraStarknetZKFlavor>) {
25+ if constexpr (IsAnyOf<Flavor, UltraFlavor, UltraKeccakFlavor, UltraKeccakZKFlavor>) {
3126 honk_recursion = 1 ;
3227 } else if constexpr (IsAnyOf<Flavor, UltraRollupFlavor>) {
3328 honk_recursion = 2 ;
3429 }
30+ #ifdef STARKNET_GARAGA_FLAVORS
31+ if constexpr (IsAnyOf<Flavor, UltraStarknetFlavor, UltraStarknetZKFlavor>) {
32+ honk_recursion = 1 ;
33+ }
34+ #endif
3535
3636 // TODO(https://github.com/AztecProtocol/barretenberg/issues/1180): Don't init grumpkin crs when unnecessary.
3737 init_grumpkin_crs (1 << CONST_ECCVM_LOG_N);
@@ -176,12 +176,14 @@ void UltraHonkAPI::prove(const Flags& flags,
176176 _write (_prove<UltraFlavor>(flags.write_vk , bytecode_path, witness_path));
177177 } else if (flags.oracle_hash_type == " keccak" && !flags.zk ) {
178178 _write (_prove<UltraKeccakFlavor>(flags.write_vk , bytecode_path, witness_path));
179- } else if (flags.oracle_hash_type == " starknet" && !flags.zk ) {
180- _write (_prove<UltraStarknetFlavor>(flags.write_vk , bytecode_path, witness_path));
181179 } else if (flags.oracle_hash_type == " keccak" && flags.zk ) {
182180 _write (_prove<UltraKeccakZKFlavor>(flags.write_vk , bytecode_path, witness_path));
181+ #ifdef STARKNET_GARAGA_FLAVORS
182+ } else if (flags.oracle_hash_type == " starknet" && !flags.zk ) {
183+ _write (_prove<UltraStarknetFlavor>(flags.write_vk , bytecode_path, witness_path));
183184 } else if (flags.oracle_hash_type == " starknet" && flags.zk ) {
184185 _write (_prove<UltraStarknetZKFlavor>(flags.write_vk , bytecode_path, witness_path));
186+ #endif
185187 } else {
186188 throw_or_abort (" Invalid proving options specified in _prove" );
187189 }
@@ -200,9 +202,11 @@ bool UltraHonkAPI::verify(const Flags& flags,
200202 if (flags.oracle_hash_type == " keccak" ) {
201203 return _verify<UltraKeccakZKFlavor>(ipa_accumulation, public_inputs_path, proof_path, vk_path);
202204 }
205+ #ifdef STARKNET_GARAGA_FLAVORS
203206 if (flags.oracle_hash_type == " starknet" ) {
204207 return _verify<UltraStarknetZKFlavor>(ipa_accumulation, public_inputs_path, proof_path, vk_path);
205208 }
209+ #endif
206210 return false ;
207211 }
208212 if (flags.oracle_hash_type == " poseidon2" ) {
@@ -211,9 +215,11 @@ bool UltraHonkAPI::verify(const Flags& flags,
211215 if (flags.oracle_hash_type == " keccak" ) {
212216 return _verify<UltraKeccakFlavor>(ipa_accumulation, public_inputs_path, proof_path, vk_path);
213217 }
218+ #ifdef STARKNET_GARAGA_FLAVORS
214219 if (flags.oracle_hash_type == " starknet" ) {
215220 return _verify<UltraStarknetFlavor>(ipa_accumulation, public_inputs_path, proof_path, vk_path);
216221 }
222+ #endif
217223 return false ;
218224}
219225
@@ -237,12 +243,14 @@ void UltraHonkAPI::write_vk(const Flags& flags,
237243 _write (_compute_vk<UltraFlavor>(bytecode_path, " " ));
238244 } else if (flags.oracle_hash_type == " keccak" && !flags.zk ) {
239245 _write (_compute_vk<UltraKeccakFlavor>(bytecode_path, " " ));
246+ #ifdef STARKNET_GARAGA_FLAVORS
240247 } else if (flags.oracle_hash_type == " starknet" && !flags.zk ) {
241248 _write (_compute_vk<UltraStarknetFlavor>(bytecode_path, " " ));
242- } else if (flags.oracle_hash_type == " keccak" && flags.zk ) {
243- _write (_compute_vk<UltraKeccakZKFlavor>(bytecode_path, " " ));
244249 } else if (flags.oracle_hash_type == " starknet" && flags.zk ) {
245250 _write (_compute_vk<UltraStarknetZKFlavor>(bytecode_path, " " ));
251+ #endif
252+ } else if (flags.oracle_hash_type == " keccak" && flags.zk ) {
253+ _write (_compute_vk<UltraKeccakZKFlavor>(bytecode_path, " " ));
246254 } else {
247255 throw_or_abort (" Invalid proving options specified in _prove" );
248256 }
0 commit comments