# Build and Gradle

> Failures before the app comes up — dependency, native library, classname, assets, Web/TeaVM.

Source: https://crossfly.dev/docs/troubleshooting/build-gradle — CrossFly documentation. Full docs as one file: https://crossfly.dev/llms-full.txt

# Build and Gradle

Failures before the app comes up. Format: **symptom → cause → fix**.

## Dependency won't resolve
**Cause:** wrong module/coordinate.
**Fix:** check the CrossFly dependency in `core` + the **platform module**
(`lwjgl3`/`android`/`ios`/`web`) in `settings.gradle`/`build.gradle`.
([Installation](/docs/get-started/installation))

## Native library (`crossfly-lib` / SQLite3MC) not found at runtime
**Cause:** the native module for that platform wasn't packaged.
**Fix:** include the **correct launcher/native**; on desktop, ensure `crossfly-lib` is on the
`java.library.path`. (Remember: on **WebGL** the native library is **not** loaded.)
([Desktop](/docs/platforms/desktop-lwjgl3) · Ch. 23)

## `:lwjgl3:run` can't find `MainWindow`
**Cause:** the *classname* doesn't point to your class.
**Fix:** configure `cmdline["classname"]` (in the launcher) or override `getMainWindow()`.
([Project anatomy](/docs/get-started/project-structure))

## Assets/fonts (roboto/fontawesome/material) don't load
**Cause:** not packaged in the module.
**Fix:** check the launcher's assets directory (base fonts are loaded at bootstrap).

## Web target (TeaVM) fails to transpile
**Cause:** use of an API not supported on TeaVM.
**Fix:** **isolate non-web code** (behind platform checks / a service abstraction).
([Web (TeaVM)](/docs/platforms/web-teavm))

## See also
- [Platform-specific](/docs/troubleshooting/platform-specific) · [Build and distribution](/docs/platforms/building-and-releasing)
