- android - 多次调用 OnPrimaryClipChangedListener
- android - 无法更新 RecyclerView 中的 TextView 字段
- android.database.CursorIndexOutOfBoundsException : Index 0 requested, 光标大小为 0
- android - 使用 AppCompat 时,我们是否需要明确指定其 UI 组件(Spinner、EditText)颜色
我刚刚开始使用 jlcj 来制作自己的视频播放器。我尝试了教程,但总是无法加载 libvlc.dylib。
我知道互联网上有很多类似的问题报告和解决方案。但是我尝试了,但仍然出现错误。
这是运行 uk.co.caprica.vlcj.test.environment.TroubleShooter
的日志。请您告诉我这个问题的原因和解决方案。
============================== 8< 8< 8< ==============================
Library name: vlc
libvlc shared object file name: libvlc.dylib
libvlc core shared object file name: libvlccore.dylib
SYSTEM PROPERTIES:
awt.toolkit=sun.lwawt.macosx.LWCToolkit
file.encoding=UTF-8
file.encoding.pkg=sun.io
file.separator=/
ftp.nonProxyHosts=local|*.local|169.254/16|*.169.254/16
gopherProxySet=false
http.nonProxyHosts=local|*.local|169.254/16|*.169.254/16
java.awt.graphicsenv=sun.awt.CGraphicsEnvironment
java.awt.printerjob=sun.lwawt.macosx.CPrinterJob
java.class.path=/Users/yasuosaito/Development/Workspace/vlcj/target/test-classes:/Users/yasuosaito/Development/Workspace/vlcj/target/classes:/Users/yasuosaito/.m2/repository/net/java/dev/jna/jna/4.1.0/jna-4.1.0.jar:/Users/yasuosaito/.m2/repository/net/java/dev/jna/jna-platform/4.1.0/jna-platform-4.1.0.jar:/Users/yasuosaito/.m2/repository/org/slf4j/slf4j-api/1.7.10/slf4j-api-1.7.10.jar:/Users/yasuosaito/.m2/repository/org/slf4j/slf4j-log4j12/1.7.10/slf4j-log4j12-1.7.10.jar:/Users/yasuosaito/.m2/repository/log4j/log4j/1.2.17/log4j-1.2.17.jar
java.class.version=52.0
java.endorsed.dirs=/Library/Java/JavaVirtualMachines/jdk1.8.0_144.jdk/Contents/Home/jre/lib/endorsed
java.ext.dirs=/Users/yasuosaito/Library/Java/Extensions:/Library/Java/JavaVirtualMachines/jdk1.8.0_144.jdk/Contents/Home/jre/lib/ext:/Library/Java/Extensions:/Network/Library/Java/Extensions:/System/Library/Java/Extensions:/usr/lib/java
java.home=/Library/Java/JavaVirtualMachines/jdk1.8.0_144.jdk/Contents/Home/jre
java.io.tmpdir=/var/folders/69/5_506wls4bj9vms7bsmg8q2h0000gn/T/
java.library.path=/Users/yasuosaito/Library/Java/Extensions:/Library/Java/Extensions:/Network/Library/Java/Extensions:/System/Library/Java/Extensions:/usr/lib/java:.
java.runtime.name=Java(TM) SE Runtime Environment
java.runtime.version=1.8.0_144-b01
java.specification.name=Java Platform API Specification
java.specification.vendor=Oracle Corporation
java.specification.version=1.8
java.vendor=Oracle Corporation
java.vendor.url=http://java.oracle.com/
java.vendor.url.bug=http://bugreport.sun.com/bugreport/
java.version=1.8.0_144
java.vm.info=mixed mode
java.vm.name=Java HotSpot(TM) 64-Bit Server VM
java.vm.specification.name=Java Virtual Machine Specification
java.vm.specification.vendor=Oracle Corporation
java.vm.specification.version=1.8
java.vm.vendor=Oracle Corporation
java.vm.version=25.144-b01
jna.library.path=/Applications/VLC.app/Contents/MacOS/lib
jna.platform.library.path=/usr/lib:/usr/lib
jnidispatch.path=/var/folders/69/5_506wls4bj9vms7bsmg8q2h0000gn/T/jna-1072754801/jna328949766312094835.tmp
os.arch=x86_64
os.name=Mac OS X
os.version=10.13.2
path.separator=:
socksNonProxyHosts=local|*.local|169.254/16|*.169.254/16
sun.arch.data.model=64
sun.boot.class.path=/Library/Java/JavaVirtualMachines/jdk1.8.0_144.jdk/Contents/Home/jre/lib/resources.jar:/Library/Java/JavaVirtualMachines/jdk1.8.0_144.jdk/Contents/Home/jre/lib/rt.jar:/Library/Java/JavaVirtualMachines/jdk1.8.0_144.jdk/Contents/Home/jre/lib/sunrsasign.jar:/Library/Java/JavaVirtualMachines/jdk1.8.0_144.jdk/Contents/Home/jre/lib/jsse.jar:/Library/Java/JavaVirtualMachines/jdk1.8.0_144.jdk/Contents/Home/jre/lib/jce.jar:/Library/Java/JavaVirtualMachines/jdk1.8.0_144.jdk/Contents/Home/jre/lib/charsets.jar:/Library/Java/JavaVirtualMachines/jdk1.8.0_144.jdk/Contents/Home/jre/lib/jfr.jar:/Library/Java/JavaVirtualMachines/jdk1.8.0_144.jdk/Contents/Home/jre/classes
sun.boot.library.path=/Library/Java/JavaVirtualMachines/jdk1.8.0_144.jdk/Contents/Home/jre/lib
sun.cpu.endian=little
sun.cpu.isalist=
sun.io.unicode.encoding=UnicodeBig
sun.java.command=uk.co.caprica.vlcj.test.environment.Troubleshooter
sun.java.launcher=SUN_STANDARD
sun.jnu.encoding=UTF-8
sun.management.compiler=HotSpot 64-Bit Tiered Compilers
sun.os.patch.level=unknown
user.country=JP
user.dir=/Users/yasuosaito/Development/Workspace/vlcj
user.home=/Users/yasuosaito
user.language=ja
user.name=yasuosaito
user.timezone=
ARCHITECTURE TELLS:
java.vm.name=Java HotSpot(TM) 64-Bit Server VM
os.arch=x86_64
sun.arch.data.model=64
PATH=/usr/bin:/bin:/usr/sbin:/sbin
/usr/bin
/bin
/usr/sbin
/sbin
jna.library.path=/Applications/VLC.app/Contents/MacOS/lib
/Applications/VLC.app/Contents/MacOS/lib found libvlc found libvlccore
java.library.path=/Users/yasuosaito/Library/Java/Extensions:/Library/Java/Extensions:/Network/Library/Java/Extensions:/System/Library/Java/Extensions:/usr/lib/java:.
/Users/yasuosaito/Library/Java/Extensions
/Library/Java/Extensions
/Network/Library/Java/Extensions
/System/Library/Java/Extensions
/usr/lib/java
.
Note that JNA does not use java.library.path, it is searched here for completeness.
LD_LIBRARY_PATH=<not-specified>
Load Library:
Failed to load libvlc: Unable to load library 'vlc': Native library (darwin/libvlc.dylib) not found in resource path ([file:/Users/yasuosaito/Development/Workspace/vlcj/target/test-classes/, file:/Users/yasuosaito/Development/Workspace/vlcj/target/classes/, file:/Users/yasuosaito/.m2/repository/net/java/dev/jna/jna/4.1.0/jna-4.1.0.jar, file:/Users/yasuosaito/.m2/repository/net/java/dev/jna/jna-platform/4.1.0/jna-platform-4.1.0.jar, file:/Users/yasuosaito/.m2/repository/org/slf4j/slf4j-api/1.7.10/slf4j-api-1.7.10.jar, file:/Users/yasuosaito/.m2/repository/org/slf4j/slf4j-log4j12/1.7.10/slf4j-log4j12-1.7.10.jar, file:/Users/yasuosaito/.m2/repository/log4j/log4j/1.2.17/log4j-1.2.17.jar])
============================== 8< 8< 8< ==============================
Note that CPU architecture detection is an informed *guess*, it may not be accurate.
It looks like you have a 64-bit OS because os.arch=x86_64.
It looks like you have a 64-bit JVM because java.vm.name=Java HotSpot(TM) 64-Bit Server VM.
If you are running a 64-bit JVM, then you need a 64-bit build of vlc.
If you only have a 32-bit build of vlc, then you can use a 32-bit JVM on your 64-bit OS.
libvlc was found in the following locations:
/Applications/VLC.app/Contents/MacOS/lib/libvlc.dylib
libvlccore was found in the following locations:
/Applications/VLC.app/Contents/MacOS/lib/libvlccore.dylib
libvlc could not be loaded.
============================== 8< 8< 8< ==============================
libvlc and libvlccore were found, so if the JVM CPU architecture matches your vlc build CPU architecture, you should be able to resolve this with configuration...
Some things to try:
Set this system property on the command-line : -Djna.library.path=/Applications/VLC.app/Contents/MacOS/lib
Set this system property in your Java code : System.setProperty("jna.library.path", "/Applications/VLC.app/Contents/MacOS/lib");
Add this statement to your Java code : NativeLibrary.addSearchPath("vlc", "/Applications/VLC.app/Contents/MacOS/lib");
Add this directory to your operating system path : /Applications/VLC.app/Contents/MacOS/lib
I will try setting the jna.library.path system property to '/Applications/VLC.app/Contents/MacOS/lib' for you...
Failed to load libvlc: Unable to load library 'vlc': Native library (darwin/libvlc.dylib) not found in resource path ([file:/Users/yasuosaito/Development/Workspace/vlcj/target/test-classes/, file:/Users/yasuosaito/Development/Workspace/vlcj/target/classes/, file:/Users/yasuosaito/.m2/repository/net/java/dev/jna/jna/4.1.0/jna-4.1.0.jar, file:/Users/yasuosaito/.m2/repository/net/java/dev/jna/jna-platform/4.1.0/jna-platform-4.1.0.jar, file:/Users/yasuosaito/.m2/repository/org/slf4j/slf4j-api/1.7.10/slf4j-api-1.7.10.jar, file:/Users/yasuosaito/.m2/repository/org/slf4j/slf4j-log4j12/1.7.10/slf4j-log4j12-1.7.10.jar, file:/Users/yasuosaito/.m2/repository/log4j/log4j/1.2.17/log4j-1.2.17.jar])
============================== 8< 8< 8< ==============================
最佳答案
cd src/main/resources/
cp -r /Applications/VLC.app/Contents/MacOS/lib darwin
rm darwin/*.*.*
cd darwin
install_name_tool -add_rpath @loader_path libvlc.dylib
mkdir vlc
cp -r /Applications/VLC.app/Contents/MacOS/plugins vlc/plugins
专为懒人而设。它对我有用,也许对你也有帮助。
关于java - 无法加载libvlc : Unable to load library 'vlc' ,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/49090931/
这个问题在这里已经有了答案: android studio adb Syntax error: ")" unexpected (4 个答案) 关闭 5 年前。 我确实将我的工作室更新到 Linux
当我打开 Android Studio 时,它会显示下面的对话框,我的应用程序无法以 Debug模式运行。 最佳答案 找到sdk->platform-tool文件夹,然后运行命令adb tcpip 5
我在 Fedora 33 机器上使用了 VSCode (1.52.1) 一段时间。 我正在使用 Docker 扩展 (v1.9.0) 但由于某种原因,在过去几天中,当我尝试将 VSCode 附加到 D
我正在尝试为我的任务加载一个名为“tr_model.h5”的预训练模型,但出现以下错误: Traceback (most recent call last): File "Trigger_Proje
我最近在 Google Play 中发布了一个 Android 应用程序,到目前为止一切看起来都很棒,但有一个异常(exception)(见下文),我有时会收到控制台崩溃的消息,它只发生在某些用户身上
单击警告时,我收到此消息。这是案件的截图。 错误写道, Unable to open 'warning.cpp': Unable to read file '/Users/dimen/code/C++
重新编译 php 后,当我使用 php cli 时出现以下错误: PHP Warning: PHP Startup: imap: Unable to initialize module Module
使用 git 1.6.4.2,当我尝试 git pull 时出现此错误: error: unable to resolve reference refs/remotes/origin/LT558-op
我是 Kotlin 的新手,我正在学习教程。运行我的应用程序会导致它在运行时崩溃。我在底部导航栏应用程序中有三个 fragment 和一个主要 Activity 。我的目标实际上只是成功运行该应用程序
我在 Windows 10 64 位上运行 Android Studio。我在 5 月 20 日早上升级到了最新的版本和 SDK,从那时起,我在打开 Android Studio 时收到上述错误。我还
因此,我创建了一个 GitHub 操作,该操作应该在发生推送时构建 docker 镜像并将其推送到 docker hub。所以这是我的 GitHub 操作:(第一次创建 GitHub 操作) name
当这些问题中的任何一个都没有帮助我时,这意味着我需要删除并重新安装 Android Studio。 这是错误: Error initializing ADB: Unable to create Deb
Iam running the latest OSX/Flutter/XCode Versions using flutter, android studio and firebase and
我最近重新安装了 ubuntu 20.04.3,在做了一些设置后,我现在在运行 apt update 时总是收到以下错误.我一定是不小心删除了某种缓存文件或目录,但我不知道如何诊断或解决这个问题。 任
今天,当我将更改推送到 Gitlab 中的代码存储库时,我才开始在 Gitlab 中收到此错误消息。 Gitlab fatal: unable to access '.......' SSL Cert
我正在使用 Protractor 和 Jasmine 。 我已经确定了 chrome 驱动程序版本:2.32.498550 (latest)与 Chrome 测试版不兼容 (Version 62.0.
我正在尝试使用 terraform (0.12.24) 和多个 Docker 提供程序(插件版本 2.7.0)执行简单部署。我使用下面的 Terraform 模板的目的是将两个不同的容器部署到两个不同
这个问题我看了很久,最后决定在这里提出来。我需要维护一些用 Delphi 2007 for .NET (ASP.NET 2.0) 编写的应用程序。通常,第一次运行应用程序(使用 IIS)时,我会收到经
如何修复 - 无法创建调试桥:无法启动 adb 服务器:无法检测 adb 版本,adb 输出:/home/dilip/Downloads/sdk/platform-tools/adb: 1:/home
通过命令提示符连接到 android 中的 Sqlite DB 时出现错误。 以下是我遵循的步骤: 我已经在 android 中通过 java 程序创建了 Sqlite 数据库。创建表并向其中插入数据
我是一名优秀的程序员,十分优秀!