<p>As far as I can tell, <code>conanrun.sh</code> is something you should not have to do. Just run the <code>CuraEngine</code> binary directly. If that doesn't work, update your question with what went wrong and I can expand on this answer.</p>
<p>To get into the nitty details, it appears the point of <code>conanrun.sh</code> is to setup library paths to find the libraries Conan (a really awful, unconventional C++ Language Package Manager the Ultimaker folks have adopted) built itself and linked CuraEngine against, since they're not present in system-wide paths. However at least on Windows, I would expect any needed DLLs to be automatically found in the same directory as the executable, and on Linux, etc., sourcing a script to override library paths like this will <em>break anything else run from the same shell environment</em> (!!) - it's <strong>not</strong> the right thing to do. Unfortunately, Conan has made it really difficult to build CuraEngine right (see my bug report <a href="https://github.com/Ultimaker/Cura/issues/12941" rel="nofollow noreferrer">12941</a>) but on Windows it's probably not that bad.</p>

CC BY-SA 4.0
2022-10-23T17:31:23.943Z
2022-10-23T17:31:23.943Z
R.. GitHub STOP HELPING ICE
<p>I apologize first if this is a super basic question to most, I am currently a computer science student in my last semester before an Associate's degree with little knowledge of the command line and Python download environments. I also primarily work with Java but have an internship using Python.</p>
<p>I have written a program that is able to take a G-code file and convert it into an SBP file with a Python script through a click of a button within a GUI. I have now been tasked with taking in an STL file and using a slicer (Cura) to convert that file into G-code.</p>
<p>I am currently trying to get the CuraEngine (without Cura) to work <strong>via</strong> the command line in order to use the subprocess library within Python to do all of these conversions within my personal GUI. However, the wiki on downloading CuraEngine isn't helping much.</p>
<p>I have been able to achieve installing and building the CuraEngine release, but cannot activate the Conan run environment through the walkthrough of the <a href="https://github.com/Ultimaker/CuraEngine/wiki/Building-CuraEngine-From-Source" rel="nofollow noreferrer">wiki</a>.</p>
<p>I am getting the error that the pathway (<code>\build\generators\conanrun.sh</code>) is not a recognized internal/external command, operable program, or batch file. When looking up the files within the generators folder, the <code>conanrun</code> file is actually an extension of .bat (<code>conanrun.bat</code>).</p>
<p>So a few questions I have:</p>
<ul>
<li>What do I do to get the CuraEngine running on the command line at this point?</li>
<li>Would it be easier to just download/run the entire Cura application through the source? I've noticed a lot of others have done that, but I don't want the GUI that goes along with it. I've also had trouble downloading the Cura application from the command line, with <code>ERROR: pynest2d/5.3.0-alpha+testing_0@ultimaker/testing: Error in generate() method</code> showing up in the install.</li>
<li>As an extension of the above question, it seems the build instructions for CuraEngine have had a lot of complaints from others. As a result, is there a better way to get a slicer engine to work through a self-made GUI?</li>
</ul>
<p>Also, I did post this question on StackOverflow.com and community.ultimaker.com as well, in case you run into it there.</p>

CC BY-SA 4.0
2022-10-20T22:25:56.520Z
I am unsure if this question is a good fit for this site, It may be a better fit to Stack Overflow or Super User.  
However, your path of `\build\generators\conanrun.sh` does not appear to include a `.` at the start, which is needed for relative paths like this. (The error produced also eludes to this missing dot)
craftxbox
CC BY-SA 4.0
2023-03-22T18:16:40.367Z
@craftxbox: Insomuch as it's needed to build and run CuraEngine from source, which is a task you might do for 3D printing and to experiment with changes to slicing for 3D printing, I think it's well on-topic.
R.. GitHub STOP HELPING ICE
<ultimaker-cura><troubleshooting><slicing>
Activating Conan run environment and running CuraEngine from command line
BiLeVi
# Activating Conan run environment and running CuraEngine from command line

(Asked by: username_0 on 2022-10-20)

I apologize first if this is a super basic question to most, I am currently a computer science student in my last semester before an Associate's degree with little knowledge of the command line and Python download environments. I also primarily work with Java but have an internship using Python.

I have written a program that is able to take a G-code file and convert it into an SBP file with a Python script through a click of a button within a GUI. I have now been tasked with taking in an STL file and using a slicer (Cura) to convert that file into G-code.

I am currently trying to get the CuraEngine (without Cura) to work **via** the command line in order to use the subprocess library within Python to do all of these conversions within my personal GUI. However, the wiki on downloading CuraEngine isn't helping much.

I have been able to achieve installing and building the CuraEngine release, but cannot activate the Conan run environment through the walkthrough of the [wiki](https://github.com/Ultimaker/CuraEngine/wiki/Building-CuraEngine-From-Source).

I am getting the error that the pathway (`\build\generators\conanrun.sh`) is not a recognized internal/external command, operable program, or batch file. When looking up the files within the generators folder, the `conanrun` file is actually an extension of .bat (`conanrun.bat`).

So a few questions I have:

* What do I do to get the CuraEngine running on the command line at this point?
* Would it be easier to just download/run the entire Cura application through the source? I've noticed a lot of others have done that, but I don't want the GUI that goes along with it. I've also had trouble downloading the Cura application from the command line, with `ERROR: pynest2d/5.3.0-alpha+testing_0@ultimaker/testing: Error in generate() method` showing up in the install.
* As an extension of the above question, it seems the build instructions for CuraEngine have had a lot of complaints from others. As a result, is there a better way to get a slicer engine to work through a self-made GUI?

Also, I did post this question on StackOverflow.com and community.ultimaker.com as well, in case you run into it there.

**Tags:** ultimaker-cura, troubleshooting, slicing
> **Comments:**
> **username_1**: I am unsure if this question is a good fit for this site, It may be a better fit to Stack Overflow or Super User.   However, your path of `\build\generators\conanrun.sh` does not appear to include a `.` at the start, which is needed for relative paths like this. (The error produced also eludes to this missing dot)  
> **username_2**: @craftxbox: Insomuch as it's needed to build and run CuraEngine from source, which is a task you might do for 3D printing and to experiment with changes to slicing for 3D printing, I think it's well on-topic.  

---

## 1 answers

### Answer by username_2 on 2022-10-23. Score: 0

As far as I can tell, `conanrun.sh` is something you should not have to do. Just run the `CuraEngine` binary directly. If that doesn't work, update your question with what went wrong and I can expand on this answer.

To get into the nitty details, it appears the point of `conanrun.sh` is to setup library paths to find the libraries Conan (a really awful, unconventional C++ Language Package Manager the Ultimaker folks have adopted) built itself and linked CuraEngine against, since they're not present in system-wide paths. However at least on Windows, I would expect any needed DLLs to be automatically found in the same directory as the executable, and on Linux, etc., sourcing a script to override library paths like this will *break anything else run from the same shell environment* (!!) - it's **not** the right thing to do. Unfortunately, Conan has made it really difficult to build CuraEngine right (see my bug report [12941](https://github.com/Ultimaker/Cura/issues/12941)) but on Windows it's probably not that bad.


---

