How to call compiler on command-line "using -D" to make #define definitions? How to call MQL5 cloud protector from commandline?

 

Hi all,

Coming from C/C++ background it's common for GCC or whatever to on commandline be able to pass a flag `-Dflag` which would be equivalent of `#define flag` so the compiled sources would be able to generate different codes depending on whatever you defined using the GCC command.

1) Is it possible to do anything similar with `metaeditor64.exe`? For instance, could I do something like `metaeditor64.exe /compile:DX100.mq5 -DFIXED_INPUTS` if I wanted to define `FIXED_INPUTS` prior to generating the binary?


2) Since I am here already- Is there any way to call MQL5 cloud protector from the commandline too?



Thanks in advance! 

Distributed Computing in the MQL5 Cloud Network
Distributed Computing in the MQL5 Cloud Network
  • cloud.mql5.com
Today's computers spend most of their time idle and do not use all the features of their CPU. Now you can benefit from the spare power of your PC. You can sell your computer's CPU time to other members of our network community for a variety of tasks like optimizing Expert Advisors optimization or developing mathematical models. Join the MQL5...
 
You aren't using GCC, I doubt you can.
 
William Roeder:
You aren't using GCC, I doubt you can.

I see. Yeah, maybe I could write a commandline tool to simply prepend the #define definitions I want.


Nevertheless, does anyone know if I can call the cloud protector from commandline? All the reasoning behind this is I want to implement a service that will compile an image of my EA that is "tailor made" to some users, to lock who can use it and the parameters that are used (without showing the on the EA interface). If I write a preprocessor to simple preppend the #define definitions, this is easily achievable.


But in the end, is there a way to still run it through the clould protector? Because otherwise there wouldn't be much meaning in going through all of this if I cannot automate that last step as well.



Thanks again

Reason: