Skip to content

Feature: Allowing alias names for kotlin targets#20

Merged
kdroidFilter merged 2 commits into
NucleusFramework:mainfrom
tuuhin:feat/target-alias-names
May 13, 2026
Merged

Feature: Allowing alias names for kotlin targets#20
kdroidFilter merged 2 commits into
NucleusFramework:mainfrom
tuuhin:feat/target-alias-names

Conversation

@tuuhin
Copy link
Copy Markdown
Contributor

@tuuhin tuuhin commented May 12, 2026

🚀 Description

This PR addresses allowing alias names for kotlin targets, primarily focusing on the KotlinNativeExportPlugin based on the issue #19

📄 Motivation and Context

Hardcoded kotlin target names were generating no code for JFF API when projects used custom aliases or non-standard naming conventions for their kotlin targets. By allowing alias names, the plugin is now more robust and flexible.

🧪 How Has This Been Tested?

  • Build Verification: Ran ./gradlew build on projects using standard naming conventions.
  • Alias Testing: Verified that projects using custom Kotlin target aliases (e.g., jvm("desktop"), mingwX64("windows) ) now generate proper files and renaming any example source-sets allowing it to build and run properly.

📦 Types of changes

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)

✅ Checklist

  • My code follows the code style of this project.
  • My change requires a change to the documentation.
  • I have updated the documentation accordingly.

tuuhin added 2 commits May 12, 2026 19:53
- Replace hardcoded "jvmMain" and "jvmTest" with dynamic target discovery based on the kotlin target thus allowing naming alias
- Included mandatory check for JVM target, throwing GradleException if missing
- Refactor mapTargetToPlatform with cleaner logic for architecture detection
- Add little logging for native target and alias identification
Moved Hardcoded version number and libraries to libs.versions.toml and read via Libraries.kt
@tuuhin
Copy link
Copy Markdown
Contributor Author

tuuhin commented May 12, 2026

try this version and let me know if any changes required

@kdroidFilter kdroidFilter merged commit 0b6f8ff into NucleusFramework:main May 13, 2026
13 of 14 checks passed
@kdroidFilter
Copy link
Copy Markdown
Collaborator

Thank you very much :) Great job !

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

Successfully merging this pull request may close these issues.

2 participants