# UE5.7.1 Packaging Android JNI Error: ld.lld: error: undefined symbol: UE::Jni::FEnv::FEnv() 

**URL:** <https://forums.unrealengine.com/t/ue5-7-1-packaging-android-jni-error-ld-lld-error-undefined-symbol-ue-fenv/2710465>\
**Category:** Mobile\
**Tags:** unreal-engine, question\
**Created:** [March 31, 2026, 5:45pm UTC](https://forums.unrealengine.com/t/ue5-7-1-packaging-android-jni-error-ld-lld-error-undefined-symbol-ue-fenv/2710465 "2026-03-31T17:45:00Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![Devichi](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@Devichi](https://forums.unrealengine.com/u/Devichi)\
**Post date:** [March 31, 2026, 5:45pm UTC](https://forums.unrealengine.com/t/ue5-7-1-packaging-android-jni-error-ld-lld-error-undefined-symbol-ue-fenv/2710465/1 "2026-03-31T17:45:00Z")

</div>

I’m trying to package an android build on UE5.7.1 but I’m running into the error: `ld.lld: error: undefined symbol: UE::Jni::FEnv::FEnv()` along with several other Java-related errors.

Here’s what I tried:

- Installing everything using Turnkey and just using the defaults
- Installing android studio / ndk / jdk without Turnkey based on the exact versions as specified in [Android Development Requirements for Unreal Engine | Unreal Engine 5.7 Documentation | Epic Developer Community](https://dev.epicgames.com/documentation/en-us/unreal-engine/android-development-requirements-for-unreal-engine)
- Everything in [Setting Up Android SDK and NDK for Unreal | Unreal Engine 4.27 Documentation | Epic Developer Community](https://dev.epicgames.com/documentation/en-us/unreal-engine/setting-up-android-sdk-and-ndk-for-unreal?application_version=4.27)
- Changing the SDK/NDK versions in Project Settings \> Android SDK
- Uninstalling any other Java installations
- Checking that my ANDROID\_HOME, JAVA\_HOME, NDK\_ROOT, NDKROOT environment variables match the intended path
- Restarting my computer
- Reinstalling the SDK via the editor
- Choosing to build different android flavors

Is there anything else that I can try?

---

<div class="post-metadata">

**Author:** ![Devichi](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@Devichi](https://forums.unrealengine.com/u/Devichi)\
**Post date:** [April 1, 2026, 8:29pm UTC](https://forums.unrealengine.com/t/ue5-7-1-packaging-android-jni-error-ld-lld-error-undefined-symbol-ue-fenv/2710465/2 "2026-04-01T20:29:25Z")

</div>

I managed to fix this by adding the following in (Game)Editor.Target.cs:

GlobalDefinitions.Add(“USE\_ANDROID\_JNI=1”);  
bOverrideBuildEnvironment = true;

I am not sure if there is a more suitable workaround than this, but that’s what worked for me.
