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

Musl/linux can not use RTLD_DEEPBIND #684

Merged
merged 1 commit into from
Dec 15, 2021

Conversation

kraj
Copy link
Contributor

@kraj kraj commented Dec 8, 2021

Exclude non-glibc linux systems along with android
Fixes
src/tbb/dynamic_link.cpp:417:29: error: use
of undeclared identifier 'RTLD_DEEPBIND' | flags = flags | RTLD_DEEPBIND;
| ^

Signed-off-by: Khem Raj raj.khem@gmail.com

Description

Add comprehensive description of proposed changes

Fixes # - issue number(s) if exists

  • - git commit message contains appropriate signed-off-by string (see CONTRIBUTING.md for details)

Type of change

Choose one or multiple, leave empty if none of the other choices apply

Add respective label(s) to PR if you have permissions

  • bug fix - change which fixes an issue
  • new feature - change which adds functionality
  • tests - change in tests
  • infrastructure - change in infrastructure and CI
  • documentation - documentation update

Tests

  • added - required for new features and for some bug fixes
  • not needed

Documentation

  • updated in # - add PR number
  • needs to be updated
  • not needed

Breaks backward compatibility

  • Yes
  • No
  • Unknown

Notify the following users

List users with @ to send notifications

Other information

Exclude non-glibc linux systems along with android
Fixes
src/tbb/dynamic_link.cpp:417:29: error: use
 of undeclared identifier 'RTLD_DEEPBIND'                                                                                    |             flags = flags | RTLD_DEEPBIND;
|                             ^

Signed-off-by: Khem Raj <raj.khem@gmail.com>
@@ -413,7 +413,7 @@ namespace r1 {
int flags = RTLD_NOW;
if (local_binding) {
flags = flags | RTLD_LOCAL;
#if __linux__ && !__ANDROID__ && !__TBB_USE_SANITIZERS
Copy link
Contributor

Choose a reason for hiding this comment

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

is it possible to have glibc on android ? I believe it is not but did not found and statement in android docs ....

Copy link
Contributor Author

Choose a reason for hiding this comment

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

android = bionic when it comes to C library.

Copy link
Contributor

Choose a reason for hiding this comment

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

POSIX.1.2017 does not require RTLD_DEEPBIND for dlopen so it seems to be glibc extension.

Copy link
Contributor

@anton-potapov anton-potapov left a comment

Choose a reason for hiding this comment

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

LGTM

@anton-potapov anton-potapov merged commit 883c2e5 into uxlfoundation:master Dec 15, 2021
kboyarinov pushed a commit that referenced this pull request Dec 27, 2021
Exclude non-glibc linux systems along with android
Fixes
src/tbb/dynamic_link.cpp:417:29: error: use
 of undeclared identifier 'RTLD_DEEPBIND'                                                                                    |             flags = flags | RTLD_DEEPBIND;
|                             ^

Signed-off-by: Khem Raj <raj.khem@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants