Skip to content

Conversation

@lithomas1
Copy link
Contributor

@lithomas1 lithomas1 commented Sep 19, 2023

@lithomas1 lithomas1 added the Build Library building on various platforms label Sep 19, 2023
@lithomas1 lithomas1 added this to the 2.1.1 milestone Sep 19, 2023
@lithomas1 lithomas1 marked this pull request as ready for review September 20, 2023 11:03
@WillAyd
Copy link
Member

WillAyd commented Sep 20, 2023

Is there a way for meson to automatically pick these up instead of manually having to specify? For sure doesn't change often, but would be nice to avoid hard coding

@lithomas1
Copy link
Contributor Author

Is there a way for meson to automatically pick these up instead of manually having to specify? For sure doesn't change often, but would be nice to avoid hard coding

Sadly, I think it has to be hardcoded, since the meson devs discourage using things like wildcards that would let us include all pyi files at once.
(Luckily, this is only for _libs though, since we have a mix of C/Cython/Python sources in there.)

@lithomas1 lithomas1 merged commit 61a6335 into pandas-dev:main Sep 20, 2023
@lithomas1 lithomas1 deleted the fix-duplicate-build branch September 20, 2023 16:59
meeseeksmachine pushed a commit to meeseeksmachine/pandas that referenced this pull request Sep 20, 2023
@lithomas1
Copy link
Contributor Author

Will self merge then so this gets in for the release.

@eli-schwartz
Copy link
Contributor

One thing you could do is offload the file list itself to a separate plaintext file containing one filename per line, and use it from meson as:

sources_to_install = fs_mod.read('sources.list').strip().split()

It's then much easier to statically verify through any means you like that the list of files is updated. You could have a CI script verify it as a test, for example, or auto refresh the file via a git-pre-commit hook.

This fulfills meson's requirement -- that any changes to the build plan are detected and force a reconfigure, so that running meson install will not result in outdated installdata that doesn't install all the files it was supposed to. Use of fs_mod.read() causes the file in question to become a regenerate dependency.

lithomas1 added a commit that referenced this pull request Sep 20, 2023
…g) (#55222) Backport PR #55206: BUILD: Fix duplicate files warning Co-authored-by: Thomas Li <47963215+lithomas1@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Build Library building on various platforms

4 participants