Skip to content

Recompile when config.yml changes#3932

Merged
kddnewton merged 1 commit intoruby:mainfrom
eregon:recompile-when-config.yml-changes
Feb 17, 2026
Merged

Recompile when config.yml changes#3932
kddnewton merged 1 commit intoruby:mainfrom
eregon:recompile-when-config.yml-changes

Conversation

@eregon
Copy link
Member

@eregon eregon commented Feb 17, 2026

* Fixes ruby#3931.
* The first line is the default one, we want to keep that default dependency too.
* Some docs about this: https://docs.ruby-lang.org/en/4.0/MakeMakefile.html
@eregon eregon force-pushed the recompile-when-config.yml-changes branch from bbfa295 to 318ee7d Compare February 17, 2026 13:57
@eregon eregon requested a review from kddnewton February 17, 2026 13:59
@kddnewton kddnewton merged commit ffe8f7a into ruby:main Feb 17, 2026
67 checks passed
@Earlopain
Copy link
Collaborator

Ah, right:

If “depend” file exist in the source directory, that content will be included in the generated makefile, with formatted by depend_rules method.

So quite easy actually. But shouldn't this include all the headers? This basically just takes care of all the gitignored/generated ones but what if for example defines.h changes?

@Earlopain
Copy link
Collaborator

I had unknown symbol errors after #3964 was merged so without looking too much into it I guess my comment is somewhat relevant. At least it failed loudly this time 😅

@eregon
Copy link
Member Author

eregon commented Mar 5, 2026

So quite easy actually. But shouldn't this include all the headers? This basically just takes care of all the gitignored/generated ones but what if for example defines.h changes?

Yes, I think you're right, I'll try it.

@Earlopain
Copy link
Collaborator

I found that adding the headers to $headers(I think) in extconf seemed to work. But I barely found any usage of that so not sure about that.

Would be nice since they can just be globbed in ruby

eregon added a commit to eregon/yarp that referenced this pull request Mar 5, 2026
@eregon
Copy link
Member Author

eregon commented Mar 5, 2026

Yes, I came to the same conclusion, #3967
And those headers are included in ruby_headers so there is no need to depend on LOCAL_HDRS explicitly (but we can for clarity if wanted)

kddnewton pushed a commit that referenced this pull request Mar 5, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Extension not fully rebuild when config.yml changes

3 participants