Pass custom CooperPaths.xml to the compiler

Hi Carlo & Marc,

We are looking for possibilities to pass a custom JDK path to EBuild (the system is a portable build machine where the tool chain is deployed by simple copy rather than fully-fledged installation, so no registry entries for JDK). As far as I understand, the best way to do that in this case is by using CooperPaths.xml.

Following this guidance, we created a copy of CooperPaths.xml matching our scenario but we are not sure about how to pass it to the compiler. We tried placing the file next to EBuild.exe, in the user’s home directory (C:\Users\username), and in the compilation directory, but neither worked. Could you please advise?

Thanks!

Ken

Ken,

right now, EBuild looks for CooperPaths only in the global and per-user ApplicationData folders, under the “\RemObjects Software\Elements” subfolder. e.g. %APPDATA%\RemObjects Software\Elements and (I believe thats the right variable) %ProgramData%\RemObjects Software\Elements.

If you set a JDK path in VS or Water, you should see the file created/updated in there right place.

There’s no way to provide a different path to load the settings from, right now.

Thanks Marc - works perfectly now! I think we’ll get away with this approach just fine.

We used the %APPDATA% variant. The other variable is also correct by the way.

1 Like

Excellent, glad to hear it’s working for your needs.\

I’ll consider adding additional override options that would affect only the current run (eg either passing a custom xml, or custom JDK/ADK paths), in the future, but it’s not as trivial as it may sound, given the current structure of how different parts of EBuild are separated.

That would be great! I agree it might be tricky though, I’d had a quick look through EBuild code trying to find any shortcuts/quick solutions before asking this question here and was impressed by its level of modularity :smile:

thanx! I’m pretty proud of that codebase, if I dare say so myself… :wink:

1 Like