Skip to content
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

gh-94165: Prevent PY_CHECK_SQLITE_FUNC from accumulating linker options #94198

Draft
wants to merge 6 commits into
base: main
Choose a base branch
from

Conversation

erlend-aasland
Copy link
Contributor

@erlend-aasland erlend-aasland commented Jun 24, 2022

Fixes gh-94165

@erlend-aasland erlend-aasland changed the title sqlite multiple libs gh-94165: Prevent PY_CHECK_SQLITE_FUNC from accumulating linker options Jun 24, 2022
@erlend-aasland erlend-aasland requested a review from tiran Jun 24, 2022
@erlend-aasland
Copy link
Contributor Author

Similar to the curses macro.

@erlend-aasland erlend-aasland marked this pull request as draft Jun 24, 2022
@erlend-aasland
Copy link
Contributor Author

Darn, there are some Ubuntu issues.

[have_sqlite3_load_extension=yes],
[have_sqlite3_load_extension=no]
)
AC_CHECK_LIB([sqlite3], [sqlite3_serialize], [
PY_CHECK_SQLITE_FUNC([sqlite3_serialize], [
Copy link
Member

Choose a reason for hiding this comment

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

The third argument to PY_CHECK_SQLITE_FUNC([sqlite3_serialize], ...) is blank. Wouldn't this set have_supported_sqlite3=no if sqlite is missing the feature?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

🤦🏻‍♂️

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I added a dummy value. Alternatively we could for example add a fourth argument (required=true|false) to PY_CHECK_SQLITE_FUNC.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I'll have to revisit this later today.

@erlend-aasland erlend-aasland marked this pull request as ready for review Jun 24, 2022
@erlend-aasland erlend-aasland marked this pull request as draft Jun 24, 2022
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.

PY_CHECK_SQLITE_FUNC() adds -lsqlite3 multiple times
3 participants