Skip to content

Run makecorever.py before specific prebuild hooks. #6504

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

Merged
merged 4 commits into from
Sep 13, 2019

Conversation

mhightower83
Copy link
Contributor

@mhightower83 mhightower83 commented Sep 11, 2019

When a sketch needs information that is in core_version.h, you
have to build a dummy sketch 1st to get core_version.h created.
Since core_version.h is created after the sketch is compiled.

Moved prebuild recipe hook for running makecorever.py core to run
before all specific prebuild hooks. While this form of prebuild hook
is not explicitly listed, it seems like an intuitive expectation and works.

Recipie hooks of this form:

recipe.hooks.prebuild.NUMBER.pattern=...

build before recipies of this form:

recipe.hooks.SPECIFIC.prebuild.NUMBER.pattern=...

where SPECIFIC would be: sketch, libraries, core, linking, ...

Update: corrected typo

When a sketch needs information that is in `core_version.h`, you
have to build a dummy sketch 1st to get `core_version.h` created.
Since `core_version.h` is created after the sketch is compiled.

Moved rebuild recipe hook for running `makecorever.py` core to run
before all _specific_ prebuild hooks. While this form of prebuild hook
is not explicitly listed, it seems like an intuitive expectation.

Recipie hooks of this form:
```
recipe.hooks.prebuild.NUMBER.pattern=...
```
build before recipies of this form:
```
recipe.hooks.SPECIFIC.prebuild.NUMBER.pattern=...
```
where `SPECIFIC` would be: sketch, libraries, core, linking, ...
Copy link
Collaborator

@d-a-v d-a-v left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It seems to actually work
A little 1-line comment to explain it is quite a working hack is welcome
and I guess it will stop me reading Core:2.5.2-nnn-g<Ref>=0000000 in users's log
(can't reproduce with git)

Copy link
Collaborator

@earlephilhower earlephilhower left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM. Not sure what a "quite a working hack" is, but it seems to make sense to everyone else. :)

@devyte devyte merged commit 9629874 into esp8266:master Sep 13, 2019
@devyte devyte added this to the 2.6.0 milestone Sep 13, 2019
@mhightower83 mhightower83 deleted the platform.txt-core_version branch January 13, 2021 18:16
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants