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

(macos Mojave 10.13.6) "adb: failed to stat sndcpy.apk: No such file or directory" #98

Open
syastro opened this issue Jan 4, 2021 · 6 comments

Comments

@syastro
Copy link

syastro commented Jan 4, 2021

when i run the sndcpy normally it shows this:

/Users/MacbookAir/Downloads/sndcpy-v1.0/sndcpy ; exit;
Waiting for device...
Performing Streamed Install
adb: failed to stat sndcpy.apk: No such file or directory
Uninstalling existing version first...
Failure [DELETE_FAILED_INTERNAL_ERROR]
logout

but when i change the SNDCPY_APK=${SNDCPY_APK:-sndcpy.apk} into its directory which is SNDCPY_APK=${SNDCPY_APK:-/Users/MacbookAir/Downloads/sndcpy-v1.0/sndcpy.apk}

then i run it and now i got this:

/Users/MacbookAir/Downloads/sndcpy-v1.0/sndcpy ; exit;
Waiting for device...
Performing Streamed Install
adb: failed to install /Users/MacbookAir/Downloads/sndcpy-v1.0/sndcpy.apk: Security exception: You need the android.permission.INSTALL_GRANT_RUNTIME_PERMISSIONS permission to use the PackageManager.INSTALL_GRANT_RUNTIME_PERMISSIONS flag

java.lang.SecurityException: You need the android.permission.INSTALL_GRANT_RUNTIME_PERMISSIONS permission to use the PackageManager.INSTALL_GRANT_RUNTIME_PERMISSIONS flag
	at com.android.server.pm.PackageInstallerService.createSessionInternal(PackageInstallerService.java:542)
	at com.android.server.pm.PackageInstallerService.createSession(PackageInstallerService.java:465)
	at com.android.server.pm.PackageManagerShellCommand.doCreateSession(PackageManagerShellCommand.java:2710)
	at com.android.server.pm.PackageManagerShellCommand.runInstall(PackageManagerShellCommand.java:1061)
	at com.android.server.pm.PackageManagerShellCommand.onCommand(PackageManagerShellCommand.java:169)
	at android.os.ShellCommand.exec(ShellCommand.java:111)
	at com.android.server.pm.PackageManagerService.onShellCommand(PackageManagerService.java:22468)
	at android.os.Binder.sUninstalling existing version first...
Failure [DELETE_FAILED_INTERNAL_ERROR]
logout

i only took #80 as reference and i have no idea how to make this work anymore, im not good with coding much

@rom1v
Copy link
Owner

rom1v commented Jan 4, 2021

For the first issue, see PR #81 (but you already have a workaround).

For INSTALL_GRANT_RUNTIME_PERMISSIONS, just remove -g here:

sndcpy/sndcpy

Line 18 in f0995ca

"$ADB" $serial install -t -r -g "$SNDCPY_APK" ||

and

sndcpy/sndcpy

Line 22 in f0995ca

"$ADB" $serial install -t -g "$SNDCPY_APK"

(#39 (comment))

@syastro
Copy link
Author

syastro commented Jan 4, 2021

Okay it seems to work i saw the cast pop up in my phone and everything but the vlc didn't pop up

/Users/MacbookAir/Downloads/sndcpy-v1.0/sndcpy ; exit;
Waiting for device...
Performing Streamed Install
Success
Starting: Intent { act=android.intent.action.MAIN cat=[android.intent.category.LAUNCHER] cmp=com.rom1v.sndcpy/.MainActivity }
Press Enter once audio capture is authorized on the device to start playing...

/Users/MacbookAir/Downloads/sndcpy-v1.0/sndcpy: line 29: vlc: command not found
logout
Saving session...
...copying shared history...
...saving history...truncating history files...
...completed.

@rom1v
Copy link
Owner

rom1v commented Jan 4, 2021

Is VLC installed? What's its location?

@syastro
Copy link
Author

syastro commented Jan 4, 2021

in the applications folder...
I did tried to change the VLC=${VLC:-vlc} to VLC=${VLC:-/Applications/VLC.app} but it didn't work

/Users/MacbookAir/Downloads/sndcpy-v1.0/sndcpy: line 29: /Applications/VLC.app: is a directory
logout

@rom1v
Copy link
Owner

rom1v commented Jan 4, 2021

Try /Applications/VLC.app/Contents/MacOS/VLC.

@syastro
Copy link
Author

syastro commented Jan 4, 2021

Okay it works but almost
New error

VLC media player 3.0.11.1 Vetinari (revision 3.0.11.1-0-g52483f3ca2)
dlopen error : dlopen(libjack.0.dylib, 1): image not found 
[00007ff1d1d42a50] dummy interface: using the dummy interface module...
[00007ff1d1f100c0] main stream error: connection error: Connection refused


edit1 - wait is this the part i ignore this? am i done
edit2 - i was confuse because mx player didn't play any sound until i switch with a diffrent app lol
anyway thank you for helping me out.

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

No branches or pull requests

2 participants