Empresas
Empregos
  • Sobre nós
  • Soluções
    • Publicação de vagas
      Publique sua vaga e receba candidatos qualificados em 48h.
    • Avaliações de candidatos
      Mais de 500 testes técnicos e psicológicos, mais anti-fraude.
    • Headhunting
      Busca executiva personalizada do início ao fim.
    • Folha de Pagamento + EOR
      Dispersão de folha e EOR em mais de 15 países da LATAM.
  • Preços
  • Empregos

0

316
Visualizações
JavaCPP builds failing on macOS after Xcode 12.2 update due to missing JavaVM framework

I recently updated to Xcode version 12.2 from 12.1. My maven build of a javacpp project began failing at that point on the clang++ step the following command and error:

clang++ -I/Users/<username>/git/<product>-javacpp/src/main/cpp -I/usr/local/include -I/Library/Java/JavaVirtualMachines/jdk-14.0.2.jdk/Contents/Home/include -I/Library/Java/JavaVirtualMachines/jdk-14.0.2.jdk/Contents/Home/include/darwin /Users/<username>/git/<product>-javacpp/target/classes/com/<product>/javacpp/video/ffmpeg/jniAvFormatCallbackFactory.cpp /Users/<username>/git/<product>-javacpp/src/main/java/jnijavacpp.cpp -march=x86-64 -m64 -O3 -Wl,-rpath,@loader_path/. -Wall -fPIC -dynamiclib -undefined dynamic_lookup -o libjniAvFormatCallbackFactory.dylib -L/usr/local/lib -Wl,-rpath,/usr/local/lib -lavformat -lavutil -framework JavaVM

ld: framework not found JavaVM

I am building with macOS 10.15.7 and JavaCPP 1.4.4

By reinstalling each Xcode version, I confirmed that this framework is present in Xcode 12.1 and has been removed from Xcode 12.2. I can build now with 12.1, but need to understand a path forward to accept Xcode upgrades in the future.

over 4 years ago · Santiago Trujillo
3 Respostas
Responde à pergunta

0

You can safely replace -framework JavaVMwith -framework JavaNativeFoundation. It worked for me.

S.

over 4 years ago · Santiago Trujillo Relatório

0

Xcode 12.2 now uses the macOS 11 (Big Sur) set of frameworks, which no longer includes the JavaVM framework. The solution here is an upgrade of the maven build to the recently available JavaCPP 1.5.4. This version no longer adds the '-framework JavaVM' option to the clang++ command, and still builds/links correctly.

This change appears to address the issue: https://github.com/bytedeco/javacpp/issues/417

The pom.xml needed updates to both the org.bytedeco javacpp plugin and dependency.

over 4 years ago · Santiago Trujillo Relatório

0

To build on NaderNader's answer, according to Apple documentation JavaVM.framework has been marked deprecated as of OS X v10.7.

I was unable to find any mention of the change in the Xcode 12.2 change log. I need to show proper documentation for a version check, so I check the OS version instead of the Xcode version.

over 4 years ago · Santiago Trujillo Relatório
Responde à pergunta
Encontrar trabalhos remotos

Descubra a nova forma de encontrar um emprego!

melhores empregos
Principais categorias de trabalho
Empresas
Postar vaga Preços Comercial
Jurídico
Termos e Condições Política de privacidade
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Recomende algumas ofertas para mim
Preciso de ajuda