bluekvirus / osgi-starterkit

Bare minimum starting point for OSGi based web app back-ends.
MIT License
2 stars 4 forks source link

Kotlin project problem #1

Open davidpodhola opened 6 years ago

davidpodhola commented 6 years ago

Following the instructions to add project test, I get this warning

> Configure project :
Gradle now uses separate output directories for each JVM language, but this build assumes a single directory for all classes from a source set. This behaviour has been deprecated and is scheduled to be removed in Gradle 5.0
        at build_6fro0prhrczp7fhe7kzk924yq$_run_closure2$_closure13$_closure16.doCall(/home/david/dev/osgi-starterkit/build.gradle:89)
        (Run with --stacktrace to get the full stack trace of this deprecation warning.)

> Task :test:bndJar
-----------------
Warnings
000: test: Unused Export-Package instructions: [software.hsharp.demo*] 
001: test: The JAR is empty: The instructions for the JAR named test did not cause any content to be included, this is likely wrong

I also changed the kotlin version in the build.gradle to

ext.kotlin_version = '1.2.21'

screenshot from 2018-02-15 17-42-09

The resulting JAR is really empty so the servlet does not work.

screenshot from 2018-02-15 17-45-45

davidpodhola commented 6 years ago

https://github.com/bndtools/bnd/wiki/Using-Kotlin-with-the-Bnd-Gradle-Plugin-for-Workspace-Builds related?

bluekvirus commented 6 years ago

Hey @davidpodhola, your /bin folder looks empty in the screenshot, have you tried to compile before building the jar out of the *.class in the /bin? I will double check with a Kotlin demo project later. I didn't use BND plugin in any way so no worries there.

davidpodhola commented 6 years ago

Hi, thanks a lot.

When I do

gradle :test:build

I get again

Warnings
000: test: Unused Export-Package instructions: [software.hsharp.demo*] 
001: test: The JAR is empty: The instructions for the JAR named test did not cause any content to be included, this is likely wrong

screenshot from 2018-02-16 07-13-25

BTW