-
-
Notifications
You must be signed in to change notification settings - Fork 8.3k
Fix windows issues #9451
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fix windows issues #9451
Conversation
5f176ff
to
c0c8542
Compare
I just noticed that the ESP32 port uses an absolute path for micropython/ports/esp32/main/CMakeLists.txt Line 189 in bdbc444
as well as the Zephyr port: micropython/ports/zephyr/CMakeLists.txt Line 108 in bdbc444
that might be problematic. Is there a specific reason why absolute path is used instead of adding |
Because adding that as an include directory adds more files to the header search path, eg ff.h, which could clash with other included files. So making the include absolute makes it much less likely to clash with anything else. |
FYI, here's how I'm doing SED escaping. Handles the expressions being changed:
|
@pingemi that is neat, I like it more as it is easier to understand. Unfortunately, Zephyr port won't build on Windows due to missing
They do exist in When missing It looks like all missing defines are related to Maybe somebody who is familiar with |
Correct
|
c0c8542
to
294d2c9
Compare
Code size report:
|
Glad you were able to make use of it! I still have to figure out the right way to get manifest generation working on windows. It embeds the relative paths to each package (as far as I can tell, only for the help command) but doesn't love Windows paths. Currently converting Windows paths to unix paths but the bigger question for me is whether help() displaying paths actually makes sense. Python uses dots for subpackages rather than slashes. |
@pingemi didn't get that far yet |
It works, but not without issues... As soon as When
the
Unfortunately, broken define doesn't appear when running generated command (from build.ninja) directly in the command line. Without modification of |
- Correct failing pipe command when forward slash is used with executable. For example: `echo a | C:/gcc/bin/gcc.exe` fails with the following error: "'C:' is not recognized as an internal or external command, operable program or batch file." Use backslash to avoid the error. - Escape " in the first SED expression - Escapes `<` and `>` characters within `MP_CONFIGFILE` define. That allows it to be used within generated `cmd.exe /C` commands. Signed-off-by: Georgij Cernysiov <[email protected]>
294d2c9
to
2e5f298
Compare
Able to build and run µPython with lv-bindings with the latest changes. |
I've also encountered #9281 and changes from current PR resolve the issue. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I have the same problem with the Zephyr port under Windows. I can confirm that this fix works and I can build and run the Zephyr port on a Windows build platform.
Confirmed with MicroPython Master with Zephyr 3.1.0 and
https://github.com/MaureenHelm/micropython/tree/zephyr-v3.2.0/py with Zephyr 3.7.0
Thanks for the fix, I hope it can be merged.
The PR stayed open for several years without any traction. The final decision was to move away from the µPython. Therefore, I close the PR. |
It already warned about it. Fixes micropython#9451
I tried to build the Zephyr port on Windows in CMD and got similar issues to #9281.
This PR attempts to fix discovered issues:
^
,&
in sed expressions when building on Windows.CMAKE_C_COMPILER
to avoid"'C:' is not recognized as an internal or external
command, operable program, or batch file.".
<
and>
in "-DMP_CONFIGFILE=<mpconfigport.h>" (i.e., "-DMP_CONFIGFILE=^<mpconfigport.h^>") - could be a problem for any port that definesMP_CONFIGFILE
in a similar way as Zephyr port does.Fixes #9281.