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

Fix #1628 failing macOS os.findlib() test #1739

Merged
merged 1 commit into from
Oct 29, 2021
Merged

Conversation

starkos
Copy link
Member

@starkos starkos commented Oct 27, 2021

What does this PR do?

Fixes—or rather disables—a failing os.findlib() unit test on macOS. From Apple's release notes:

New in macOS Big Sur 11.0.1, the system ships with a built-in dynamic linker cache of all system-provided libraries. As part of this change, copies of dynamic libraries are no longer present on the filesystem. Code that attempts to check for dynamic library presence by looking for a file at a path or enumerating a directory will fail. Instead, check for library presence by attempting to dlopen() the path, which will correctly check for the library in the cache. (62986286)

So os.findlib() is effectively useless for locating system libraries on macOS. I've documented the issue and disabled the failing test for macOS.

How does this PR change Premake's behavior?

No changes to behavior, only the unit test.

Anything else we should know?

I think you're all doing a wonderful job.

Did you check all the boxes?

  • Focus on a single fix or feature; remove any unrelated formatting or code changes
  • Add unit tests showing fix or feature works; all tests pass
  • Mention any related issues (put closes #XXXX in comment to auto-close issue when PR is merged)
  • Follow our coding conventions
  • Minimize the number of commits
  • Align documentation to your changes

You can now support Premake on our OpenCollective. Your contributions help us spend more time responding to requests like these!

@samsinsane
Copy link
Member

This function could attempt to load the library on macOS instead? Additionally, the documentation suggests that this function will still work in older versions of macOS but your change applies to all versions of macOS not just 11.0 and higher.

@starkos starkos merged commit 775e6ba into premake:master Oct 29, 2021
@starkos starkos deleted the issue/1628 branch October 29, 2021 10:37
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.

4 participants