-
-
Notifications
You must be signed in to change notification settings - Fork 1.9k
Improved Guessing of boost_python version #16027
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
Open
kjmeagher
wants to merge
9
commits into
mesonbuild:master
Choose a base branch
from
kjmeagher:kjm/stop_guessing_boost_python
base: master
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Changes from all commits
Commits
Show all changes
9 commits
Select commit
Hold shift + click to select a range
a4188a4
Stop Guessing which version of boost_python to select
kjmeagher f6e3477
handle python correctly
kjmeagher 7898f18
pylint and flake8
kjmeagher b62a8bb
remove python2 tests in `1 boost` and add fake boost libraries that
kjmeagher 1793a99
use set and only test in certian cases
kjmeagher 58cace0
rename windows files
kjmeagher f3d3cfd
Update mesonbuild/dependencies/boost.py
kjmeagher 553c465
incorperate suggestions from dnicolodi
kjmeagher de729d3
install boost_numpy on suse and ubuntu and disable windows tests
kjmeagher File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,8 @@ | ||
| ## Improve Version Guessing for boost_python and boost_numpy | ||
|
|
||
| Previously if you specified `boost_python` or `boost_numpy` as modules to | ||
| `dependency('boost')` it would pick a random version based on which file it | ||
| found first. Now, if there are multiple versions it will first try to find | ||
| the one matches the current python interpreter. If that fails, it will use | ||
| the most recent version. There is also a warning that this behavior will | ||
| be removed in a future release. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
File renamed without changes.
File renamed without changes.
1 change: 0 additions & 1 deletion
1
test cases/frameworks/35 boost symlinks/boost/lib/boost_python-vc142-mt-gd-x32-0_3.lib
This file was deleted.
Oops, something went wrong.
1 change: 0 additions & 1 deletion
1
test cases/frameworks/35 boost symlinks/boost/lib/boost_python-vc142-mt-gd-x64-0_3.lib
This file was deleted.
Oops, something went wrong.
1 change: 1 addition & 0 deletions
1
test cases/frameworks/35 boost symlinks/boost/lib/boost_python315-vc142-mt-gd-x32-0_3.lib
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1 @@ | ||
| ../Cellar/boost-python/0.3.0/lib/boost_python315-vc142-mt-gd-x32-0_3.lib |
1 change: 1 addition & 0 deletions
1
test cases/frameworks/35 boost symlinks/boost/lib/boost_python315-vc142-mt-gd-x64-0_3.lib
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1 @@ | ||
| ../Cellar/boost-python/0.3.0/lib/boost_python315-vc142-mt-gd-x64-0_3.lib |
1 change: 0 additions & 1 deletion
1
test cases/frameworks/35 boost symlinks/boost/lib/libboost_python.so.0.3.0
This file was deleted.
Oops, something went wrong.
1 change: 1 addition & 0 deletions
1
test cases/frameworks/35 boost symlinks/boost/lib/libboost_python315.so.0.3.0
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1 @@ | ||
| ../Cellar/boost-python/0.3.0/lib/libboost_python315.so.0.3.0 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
3 changes: 3 additions & 0 deletions
3
test cases/frameworks/42 boost python/boost/include/boost/version.hpp
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,3 @@ | ||
| #define BOOST_VERSION 100 | ||
|
|
||
| #error This is not a real version of boost |
Empty file.
Empty file.
Empty file.
Empty file.
Empty file.
Empty file.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,15 @@ | ||
| # this test case can be deleted if support for unversioned python libs is removed | ||
|
|
||
| project('boost python test', 'cpp') | ||
|
|
||
| bm = build_machine.system() | ||
|
|
||
| if bm == 'windows' or bm == 'cygwin' | ||
| error('MESON_SKIP_TEST: Windows uses different library files') | ||
| endif | ||
|
|
||
| dependency('boost', modules: ['python', 'numpy'], required: true) | ||
| dependency('boost', modules: ['python3', 'numpy3'], required: true) | ||
| dependency('boost', modules: ['python313', 'numpy313'], required: true) | ||
| dependency('boost', modules: ['python314', 'numpy314'], required: true) | ||
| dependency('boost', modules: ['python315', 'numpy315'], required: true) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,2 @@ | ||
| [properties] | ||
| boost_root = '@MESON_TEST_ROOT@/boost' |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,3 @@ | ||
| { | ||
| "expect_skip_on_jobname": ["azure", "windows"] | ||
| } |
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This looses the handling of versioned names spelled in different ways that are currently handled in
fix_python_namebelow. If this is intentional, it need to be documented, and it needs to be checked that the "alternative" naming schemes handled infix_python_nameare not in use on any supported platform.There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The more complicated behavior was due to Gentoo and OpenSUSE renameing the libraries circa 2020-2019 because they did not understand how boost_python was supposed to work. I do not believe there is any utility in meson continuing to support this behavior. I added a short note to the code
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't think a comment in the code is useful for this. Anyone interested in the history of this could simply look at the commit log. The change should be reported in the commit message. Also, "circa 2020-2019" is not very informative. Which distribution releases are affected? Are any of these still supported?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You can see in the reports in #4788 and #6886 when and which distribution were renaming library filenames, they all stopped doing it around 2020 and these platforms are already EOL. I really don't think that doing anymore detective work is worth it for a library that hardly anyone uses.