I'm trying to compile a Smart Contract to bytecode using solc. I'm on a Ubuntu VM so I have to rely on a simple-to-install cmd line application.

Compilation works fine but it seems like I can't pass any input parameter for the constructor.

Any suggestions?

  • I'm not sure if your question is accurate. Solc serves only to compile a solidity written contract into Bytecode and ABI ... After having these you must use a Client (Infura, Parity, Geth, etc..) to deploy the contract. This is where you provide Arguments to your constructor – João Quintanilha Mar 24 '20 at 11:31
  • Thank you. I will mark @goodvibration 's answer as correct and create a new, more accurate question. – moritz-mbw Mar 24 '20 at 11:40

Constructor arguments are passed during deployment, not during compilation.

  • Thank you for your answer. – moritz-mbw Mar 24 '20 at 11:38
  • @moritz-mbw: You're welcome. – goodvibration Mar 24 '20 at 11:46

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.