tools/makemanifest.py: Allow passing flags to mpy-tool.py#5412
Conversation
| CFLAGS += -DMICROPY_QSTR_EXTRA_POOL=mp_qstr_frozen_const_pool | ||
| CFLAGS += -DMICROPY_MODULE_FROZEN_MPY | ||
| CFLAGS += -DMPZ_DIG_SIZE=16 # force 16 bits to work on both 32 and 64 bit archs | ||
| ifneq ($(MICROPY_FORCE_32BIT),1) |
There was a problem hiding this comment.
I'm not sure this will catch all build scenarios: eg what about building on a 32-bit machine? Then this config option may not be set but the dig size should still be 16.
There was a problem hiding this comment.
Hmm, you're right. I'll think of another way, perhaps to check the compiler version.
Without this change, since mpy-tool assumes MPZ_DIG_SIZE=16, you must define MPZ_DIG_SIZE=16 in your CFLAGS/port to have it compile. It better be automatic.
There was a problem hiding this comment.
If you rebase this PR on to latest master that will include a new Travis build for 32-bit unix, which can test this.
There was a problem hiding this comment.
I think we should just remove this change.
|
I wonder if it's required, after all - I mean, I added this because my first idea was to change mpy-tool to use digit size = 32, instead of forcing the Linux kernel port to use digit size = 16. If we think it doesn't have any considerable performance impact, we might as well:
This is, apparently, not so easy as I thought. I think what most I think we can keep the mpy-tool addition, but remove the change in the unix port. |
|
Sigh, github hotkeys. |
|
@Jongy can you please rebase on latest master so it runs the CI (there are a lot of new tests now). Then I can comment on the above. |
|
This is erroring on qemu_mips and qeum_arm builds with: |
| "-f", "--mpy-cross-flags", default="", help="flags to pass to mpy-cross" | ||
| ) | ||
| cmd_parser.add_argument("-v", "--var", action="append", help="variables to substitute") | ||
| cmd_parser.add_argument('--mpy-tool-flags', default='', help='flags to pass to mpy-tool') |
There was a problem hiding this comment.
please use double quotes " (to satisfy Black formatting)
Agreed. |
|
@dpgeorge , I have:
and fixed other CI notes |
Codecov Report
@@ Coverage Diff @@
## master #5412 +/- ##
==========================================
- Coverage 98.29% 98.28% -0.02%
==========================================
Files 154 154
Lines 19986 19985 -1
==========================================
- Hits 19646 19643 -3
- Misses 340 342 +2
Continue to review full report at Codecov.
|
|
Thank you! |
Use it to remain with the default MPZ_DIG_SIZE = 32 on 64-bit builds.