-
-
Notifications
You must be signed in to change notification settings - Fork 26
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
dcli compile broken on mac os #253
Comments
@bsutton The solution seems to be to provide a custom implementation of the pthread_mutex_timedlock function. I don't known low level details so with the help of chatgpt I replaced pthread_mutex_timedlock function in native_synchronization_temp/lib/src/bindings/pthread.dart with: /// at the top, add another import /// Constants (maybe we should get these values in another way, currently hard coded) /// Bind the /// Mutex lock implementation for macOS final nanosleep = DynamicLibrary.process().lookupFunction< final timeout = abstime.ref; while (true) {
} I don't know if the provided code is a right mock implementation of the pthread_mutex_timedlock. |
And now I've just read your updated comment and realised what the code was for. So you are saying that macos is missing the pthread_mutex_timedlock. That puts quite a different shade on the problem. So I don't have time now but I will look at the practicalities of integrating your mutex code into the library. At a quick look I don't think the chat gpt implementation is correct. This link proposes a solution: https://lists.apache.org/thread/yqdnsky6svc5cfdkx1s8m4d3j8h9xyj6 edit: updated link |
So, the issue is more related to native_synchronization_temp/native_synchronization? |
@danieletulone I'm heavily committed this week, If you have time to look at the above link and raise a PR it would be appreciated. |
Hi, @bsutton! Any updates on this issue? |
It's at the top of my list.
Will try to have a look this weekend.
…On Sun, 13 Oct 2024, 10:25 pm jifferon, ***@***.***> wrote:
Hi, @bsutton <https://github.com/bsutton>! Any updates on this issue?
—
Reply to this email directly, view it on GitHub
<#253 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AAG32OHSSPBOF7OI76MKTRDZ3JKBLAVCNFSM6AAAAABMYV37TSVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDIMBYHEZTSMRZGY>
.
You are receiving this because you were mentioned.Message ID:
***@***.***>
|
I've released 6.1.0 which I think solves the problem. Give it a spin and let me know if you have any issues. For the broader audience, this also fixes similar problems in Windows. |
Hi, I have same problem.
dcli version is 6.0.5 and dart 3.4.3, on macos arm64
ArgumentError: Invalid argument(s): Couldn't resolve native function 'pthread_mutex_timedlock' in 'package:native_synchronization_temp/src/bindings/pthread.dart' : No asset with id 'package:native_synchronization_temp/src/bindings/pthread.dart' found. No available native assets. Attempted to fallback to process lookup. dlsym(RTLD_DEFAULT, pthread_mutex_timedlock): symbol not found.
This problem also affects and dcli function that uses
withNamedLockAsync
The text was updated successfully, but these errors were encountered: