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

[WIP] android-file-transfer: get working for darwin #67301

Closed
wants to merge 1 commit into from

Conversation

Amar1729
Copy link
Contributor

Motivation for this change
Things done
  • Tested using sandboxing (nix.useSandbox on NixOS, or option sandbox in nix.conf on non-NixOS)
  • Built on platform(s)
    • NixOS
    • macOS
    • other Linux distributions
  • Tested via one or more NixOS test(s) if existing and applicable for the change (look inside nixos/tests)
  • Tested compilation of all pkgs that depend on this change using nix-shell -p nix-review --run "nix-review wip"
  • Tested execution of all binary files (usually in ./result/bin/)
  • Determined the impact on package closure size (by running nix path-info -S before and after)
  • Ensured that relevant documentation is up to date
  • Fits CONTRIBUTING.md.
Notify maintainers

cc @

Unfortunately this is a work-in-progress: the files under bin seem to work fine, but the qt Application doesn't open yet:

$ open result/Applications/android-file-transfer.app
LSOpenURLsWithRole() failed with error -10810 for the file result/Applications/android-file-transfer.app.

$ ./result/Applications/android-file-transfer.app/Contents/MacOS/android-file-transfer
objc[32001]: Class QMacAutoReleasePoolTracker is implemented in both /nix/store/frk8i1qi24vx554fq0iiwd9p93dl0jdf-qtbase-5.12.0/lib/libQt5Core.5.dylib (0x103ec9768) and /nix/store/l08dykbz30jph236w6qqn0hgs9916kh6-qtbase-5.11.3/lib/libQt5Core.5.dylib (0x109ba6708). One of the two will be used. Which one is undefined.
objc[32001]: Class QT_ROOT_LEVEL_POOL__THESE_OBJECTS_WILL_BE_RELEASED_WHEN_QAPP_GOES_OUT_OF_SCOPE is implemented in both /nix/store/frk8i1qi24vx554fq0iiwd9p93dl0jdf-qtbase-5.12.0/lib/libQt5Core.5.dylib (0x103ec97e0) and /nix/store/l08dykbz30jph236w6qqn0hgs9916kh6-qtbase-5.11.3/lib/libQt5Core.5.dylib (0x109ba6780). One of the two will be used. Which one is undefined.
objc[32001]: Class RunLoopModeTracker is implemented in both /nix/store/frk8i1qi24vx554fq0iiwd9p93dl0jdf-qtbase-5.12.0/lib/libQt5Core.5.dylib (0x103ec9808) and /nix/store/l08dykbz30jph236w6qqn0hgs9916kh6-qtbase-5.11.3/lib/libQt5Core.5.dylib (0x109ba67a8). One of the two will be used. Which one is undefined.
QObject::moveToThread: Current thread (0x7fef5c7002a0) is not the object's thread (0x7fef5c41d180).
Cannot move to target thread (0x7fef5c7002a0)

You might be loading two sets of Qt binaries into the same process. Check that all plugins are compiled against the right Qt binaries. Export DYLD_PRINT_LIBRARIES=1 and check that only one set of binaries are being loaded.
qt.qpa.plugin: Could not load the Qt platform plugin "cocoa" in "" even though it was found.
This application failed to start because no Qt platform plugin could be initialized. Reinstalling the application may fix this problem.

Available platform plugins are: cocoa, minimal, offscreen.

[1]    32001 abort 

Not sure how to properly add the cocoa lib that qt needs? I tried adding qtmacextras to build inputs but that didn't work either.

When complete, will close #60495

@Amar1729
Copy link
Contributor Author

While this package isn't strictly "broken by the addition of wrapQtAppsHook", I think it still is related to #65399 since it's trying and failing to wrap a Qt app

@stale
Copy link

stale bot commented Jun 1, 2020

Thank you for your contributions.
This has been automatically marked as stale because it has had no activity for 180 days.
If this is still important to you, we ask that you leave a comment below. Your comment can be as simple as "still important to me". This lets people see that at least one person still cares about this. Someone will have to do this at most twice a year if there is no other activity.
Here are suggestions that might help resolve this more quickly:

  1. Search for maintainers and people that previously touched the
    related code and @ mention them in a comment.
  2. Ask on the NixOS Discourse. 3. Ask on the #nixos channel on
    irc.freenode.net.

@stale stale bot added the 2.status: stale https://github.com/NixOS/nixpkgs/blob/master/.github/STALE-BOT.md label Jun 1, 2020
@ryantm ryantm marked this pull request as draft October 23, 2020 03:05
@stale stale bot removed the 2.status: stale https://github.com/NixOS/nixpkgs/blob/master/.github/STALE-BOT.md label Oct 23, 2020
@stale
Copy link

stale bot commented Jul 21, 2021

I marked this as stale due to inactivity. → More info

@stale stale bot added the 2.status: stale https://github.com/NixOS/nixpkgs/blob/master/.github/STALE-BOT.md label Jul 21, 2021
@wegank
Copy link
Member

wegank commented Jan 2, 2023

All changes in this PR seem to be upstreamed, so closing this.

It still doesn't launch, though:

$ result/Applications/android-file-transfer.app/Contents/MacOS/android-file-transfer 
upload worker started
current text color value:  255 , guessed theme:  "dark"
scan

@wegank wegank closed this Jan 2, 2023
@Amar1729 Amar1729 deleted the darwin-fix/aft branch January 2, 2023 20:20
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
2.status: merge conflict 2.status: stale https://github.com/NixOS/nixpkgs/blob/master/.github/STALE-BOT.md 6.topic: darwin Running or building packages on Darwin 8.has: package (new) 10.rebuild-darwin: 1-10 10.rebuild-linux: 1-10
Projects
None yet
Development

Successfully merging this pull request may close these issues.

android-file-transfer: support darwin via osxfuse?
3 participants