thelema-engine icon indicating copy to clipboard operation
thelema-engine copied to clipboard

How to download engine libraries?

Open EdithBirrer1 opened this issue 2 years ago • 3 comments

I am looking for a 3D library in Java or Kotlin and your one looks very promising, so I want to try it out. Working through the QuickStart (https://github.com/zeganstyl/thelema-engine/wiki/Quick-Start), lots of classes cannot be imported. Probably I need the engine as stated in the Main page from readme (https://thelema.app/), where you write: Enter your credentials to download engine libraries. How to get token.

I have created a token in GitHub, but when I try a gradle build, I am still getting Could not GET 'https://maven.pkg.github.com/zeganstyl/thelema-engine/app/thelema/thelema-jvm/0.7.0/thelema-jvm-0.7.0.pom'. Received status code 401 from server: Unauthorized

My build.gradle.kts looks as follows (inserted username/token instead of ... parts):

[...]
repositories {
    jcenter()
    mavenCentral()
    maven {
        url = uri("https://maven.pkg.github.com/zeganstyl/thelema-engine")    // not found
        credentials {
            username = "...myusername..."
            password = "...thetoken..."
        }
    }
}

dependencies {
    implementation("app.thelema:thelema-jvm:0.7.0")       // this is the current version
    implementation("org.jetbrains.kotlin:kotlin-stdlib-jdk8")
    implementation("org.ksdfv.thelema:thelema-lwjgl3:0.1.0")

    testImplementation(kotlin("test"))
}
[...]

How can I download the engine files? Do you need to give access? (I noticed that you are also in GitLab, I can also access there if you prefer that).

Thanks a lot!

EdithBirrer1 avatar Dec 16 '22 08:12 EdithBirrer1

Hello.

These binary libs are obsolete.

Quick-Start is even more obsolete. Better to look tests (samples): https://github.com/zeganstyl/thelema-engine/tree/master/tests/src/commonMain/kotlin/app/thelema/test You can find class MainTest, and there you can switch between test classes.

I think it is better to download sources from master and try to build it by yourself. It is not hard. After successful build, libs can be installed to local maven through publishKotlinMultiplatformPublicationToMavenLocal, publishJvmPublicationToMavenLocal, and etc.

Mostly engine is supported under Linux, Windows must be also supported, macOS don't know.

GitLab I'm not using now.

zeganstyl avatar Dec 16 '22 19:12 zeganstyl

Thanks for your feedback. Would be good if in the places I found it stated that it is outdated.

Anyway, I cloned https://github.com/zeganstyl/thelema-engine/ and tried gradlew publishKotlinMultiplatformPublicationToMavenLocal in the project directory. It worked for a while and then failed with some Unresolved reference errors - see output below. I am working with Jetbrains IntelliJ newes version on Windows. What am I doing wrongly?

Thanks a lot, and I hope you can enjoy Christmas time and have a good start into the new year!

F:\...localpath...\Thelema\engine> gradlew publishKotlinMultiplatformPublicationToMavenLocal

Welcome to Gradle 7.3!

Here are the highlights of this release:
 - Easily declare new test suites in Java projects
 - Support for Java 17
 - Support for Scala 3

For more details see https://docs.gradle.org/7.3/release-notes.html


> Configure project :
Kotlin Multiplatform Projects are an Alpha feature. See: https://kotlinlang.org/docs/reference/evolution/components-stability.html. To hide this message, add 'kotlin.mpp.stability.nowa
rn=true' to the Gradle properties.

The property 'kotlin.mpp.enableGranularSourceSetsMetadata=true' has no effect in this and future Kotlin versions, as Hierarchical Structures support is now enabled by default. It is sa
fe to remove the property.

The property 'kotlin.native.enableDependencyPropagation=false' has no effect in this and future Kotlin versions, as Kotlin/Native dependency commonization is now enabled by default. It
 is safe to remove the property.


The Kotlin source set androidAndroidTestRelease was configured but not added to any Kotlin compilation. You can add a source set to a target's compilation by connecting it with the com
pilation's default source set using 'dependsOn'.
See https://kotlinlang.org/docs/reference/building-mpp-with-gradle.html#connecting-source-sets

The Kotlin source set androidAndroidTestRelease was configured but not added to any Kotlin compilation. You can add a source set to a target's compilation by connecting it with the com
pilation's default source set using 'dependsOn'.
See https://kotlinlang.org/docs/reference/building-mpp-with-gradle.html#connecting-source-sets

> Task :kotlinNpmInstall
warning workspace-aggregator-e36a839c-8a67-42d8-b186-593af4a6f0b4 > thelema-tests > webpack-dev-server > url > [email protected]: The querystring API is considered Legacy. new code sho
uld use the URLSearchParams API instead.
warning Ignored scripts due to flag.

> Task :compileCommonMainKotlinMetadata FAILED
e: F:\...localpath...\Thelema\engine\src\commonMain\kotlin\app\thelema\shader\Shader.kt: (788, 28): Type mismatch: inferred type is Unit but IEntityComponent was expected
e: F:\...localpath...\Thelema\engine\src\commonMain\kotlin\app\thelema\shader\Shader.kt: (788, 30): Unresolved reference: SkyboxOutputNode
e: F:\...localpath...\Thelema\engine\src\commonMain\kotlin\app\thelema\shader\Shader.kt: (789, 37): Unresolved reference: SkyboxOutputNode
e: F:\...localpath...\Thelema\engine\src\commonMain\kotlin\app\thelema\shader\Shader.kt: (789, 55): Unresolved reference: fragColor
e: F:\...localpath...\Thelema\engine\src\commonMain\kotlin\app\thelema\shader\Shader.kt: (790, 38): Unresolved reference: SkyboxOutputNode
e: F:\...localpath...\Thelema\engine\src\commonMain\kotlin\app\thelema\shader\Shader.kt: (790, 56): Unresolved reference: textureCoordinates

FAILURE: Build failed with an exception.

* What went wrong:
Execution failed for task ':compileCommonMainKotlinMetadata'.
> A failure occurred while executing org.jetbrains.kotlin.compilerRunner.GradleCompilerRunnerWithWorkers$GradleKotlinCompilerWorkAction
   > Compilation error. See log for more details

* Try:
Deprecated Gradle features were used in this build, making it incompatible with Gradle 8.0.

You can use '--warning-mode all' to show the individual deprecation warnings and determine if they come from your own scripts or plugins.

See https://docs.gradle.org/7.3/userguide/command_line_interface.html#sec:command_line_warnings

BUILD FAILED in 1m 51s
23 actionable tasks: 17 executed, 6 up-to-date

F:\...localpath...\Thelema\engine>

EdithBirrer1 avatar Dec 21 '22 13:12 EdithBirrer1

Yes. I think I forgot to delete some code. Fixed https://github.com/zeganstyl/thelema-engine/commit/8e2943b6d2de3376ce338025b58ff31c14097caf Try now.

zeganstyl avatar Dec 21 '22 19:12 zeganstyl