Skip to content

Conversation

@rhubert
Copy link
Contributor

@rhubert rhubert commented Jan 21, 2026

The native file is used to specify the tools to be used for building native binaries. Without this file meson uses the system toolchain in /usr/bin if available.

Copy link
Member

@jkloetzke jkloetzke left a comment

Choose a reason for hiding this comment

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

I'm wondering why we need to add cmake to the cross file? Would be good to add this reasoning to the commit message...

Comment on lines 108 to 111
c_args = [$(meson_join_list "${MESON_CFLAGS[@]}")]
cpp_args = [$(meson_join_list "${MESON_CXXFLAGS[@]}")]
c_link_args = [$(meson_join_list "${MESON_LDFLAGS[@]}")]
cpp_link_args = [$(meson_join_list "${MESON_LDFLAGS[@]}")]
Copy link
Member

Choose a reason for hiding this comment

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

This looks odd. When cross-compiling, both a cross- and a native-file are passed. Does it mean we're using the flags same flags for host and target?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

AFAIU this providing both is valid?

We do not have separate environment variables for host and target toolchain, but I see that using the target flags for the native tools might also break. Maybe this should be set to some safe defaults instead?

@rhubert
Copy link
Contributor Author

rhubert commented Jan 22, 2026

I'm wondering why we need to add cmake to the cross file? Would be good to add this reasoning to the commit message...

I feared you'll ask this. I have this commit since a few years and missed to add details... I'll remove it and see what breaks..

The native file is used to specify the tools to be used for building
native binaries. Without this file meson uses the system toolchain in
/usr/bin if available.
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.

2 participants