Compiling firmware, do you have to do, this every time? Meaning, if I compile the Unix port, an initial step is...
$ make -C mpy-cross
If I later want to compile firmware for Pico or maybe ESP8266, to I have to setup the mpy-cross environment each time? Based on the MP directory structure, it seems like a shared resource across any port firmware compile, but maybe I am misunderstanding something?
Of course for each port you have to deal with the requirements, dependencies, refresh the submodules content, then compile the specific firmware. But as i am comparing the various steps in the various sources, everything is documented as a separate silo, pico or esp, but if I am setting up several in the same environment, what is shared versus not, the specific external SDKs withstanding of course.
Compiling firmware, do you have to do, this every time?
-
- Posts: 144
- Joined: Mon Jul 25, 2022 9:45 pm
Re: Compiling firmware, do you have to do, this every time?
No. This only needs to be done when the .mpy format changes (which is rare, and less than once per major release).Jibun no kage wrote: ↑Mon Aug 22, 2022 12:21 amCompiling firmware, do you have to do, this every time? Meaning, if I compile the Unix port, an initial step is...
$ make -C mpy-cross
Are you compiling ESP8266 with docker? In which case the mpy-cross you're building for ESP8266 (in docker) is for a different target than the one you'd be building (not in docker) for everything else. So yes, in this case, switching between esp8266-with-docker and anything-not-docker will require rebuilding.Jibun no kage wrote: ↑Mon Aug 22, 2022 12:21 amIf I later want to compile firmware for Pico or maybe ESP8266, to I have to setup the mpy-cross environment each time? Based on the MP directory structure, it seems like a shared resource across any port firmware compile, but maybe I am misunderstanding something?
Simple fix is just to have two different clones of the micropython repo (or a second worktree of your main clone) and have one dedicated to esp8266.
-
- Posts: 144
- Joined: Mon Jul 25, 2022 9:45 pm
Re: Compiling firmware, do you have to do, this every time?
I am not using docker as yet... on purpose, so I learn the process in detail before I use the 'easier' method. I did, once you sent me the links to the ci.sh logic, that answered the question, clearly the ci.sh is doing the entire set of steps for each port as applicable. THe mpy-cross, submodules, make, etc., some ports vary a bit.