Temporary solution to compile with maven / bnd

Hi everyone,
thanks to the contribution of @massi there is a temporary solution to compile the bindings.

I am attaching the preview link
https://www.openhab.org/docs/developer/

Start from a new Eclipse by installing the selecting laster 03-2019 you do not install any OH component selected.
Once the installation is complete, you need to clone the latest repositories as per the guide.
@kai is working on a final version
I hope it helps you

1 Like

So if I build using this method can it be used in openhab 2.4 stable or 2.5 milestone 1?

Yes , once you build the jar it will run with both 2.4 stable and 2.5M1.
I tested it personally and it worked.

for bindings not part of the official distribution you install them copying the jar in the addons folder, and you still have to activate dependencies manually , but that was true also with the old build system

1 Like

@gozilla01
I am new to OH2 developing.
I tried your instruction set but after “Run OSGi” I get multiple OSGi framework errors:
org.osgi.framework.BundleException: Could not resolve module: org.openhab.core.boot [121] org.osgi.framework.BundleException: Could not resolve module: org.eclipse.xtext.xbase [115] org.osgi.framework.BundleException: Could not resolve module: org.openhab.core.compat1x [103]
and so on…

Did I miss anything?
Eclipse Version is 2019-3

After selecting laster 03-2019 you do not see any OH component selected.
Once the installation is complete, you need to clone the latest repositories as per the guide.

@gozilla01
Installed a fresh eclipse with eclipse installer and did all guide steps, but still the same errors like:

could not resolve the bundles: [com.eclipsesource.jaxrs.jersey-all-2.22.2 org.osgi.framework.BundleException: Could not resolve module: com.eclipsesource.jaxrs.jersey-all [1] Unresolved requirement: Import-Package: javax.activation

or

com.eclipsesource.jaxrs.publisher-5.3.1.201602281253 org.osgi.framework.BundleException: Could not resolve module: com.eclipsesource.jaxrs.publisher [2] Unresolved requirement: Import-Package: javax.ws.rs; version="[2.0.0,3.0.0)" -> Export-Package: javax.ws.rs; bundle-symbolic-name="com.eclipsesource.jaxrs.jersey-all"; bundle-version="2.22.2"; version="2.0.0"; uses:="javax.ws.rs.core,javax.ws.rs.ext" com.eclipsesource.jaxrs.jersey-all [1] Unresolved requirement: Import-Package: javax.activation Unresolved requirement: Import-Package: javax.ws.rs.core; version="[2.0.0,3.0.0)" -> Export-Package: javax.ws.rs.core; bundle-symbolic-name="com.eclipsesource.jaxrs.jersey-all"; bundle-version="2.22.2"; version="2.0.0"; uses:="javax.ws.rs.ext,javax.ws.rs,javax.xml.bind.annotation.adapters,javax.xml.namespace,javax.xml.bind.annotation"

FYI:
I have commited a fix now and we will get an updated page in some minutes hopefully. :slight_smile:

1 Like

Here we go:

Would be nice, if you edit the first post @gozilla01.
I don’t know if and when those preview builds get deleted automatically.

Done, thanks

1 Like

@Confectrician @massi

Hallo,
In the last update of the document https://www.openhab.org/docs/developer/ , I think they send points:

@massi you could upgrade with a PR

@David_Graeff
After the merger of these two PR


Could you correct the documentation with my suggestions from the previous post?
Unfortunately I never did it

Would be nice if you could quickly add those as your own PR. I have no insights here.

What is important: Do not specify a specific Eclipse version. That got outdated in the docs all the time. Rather have a hint somewhere saying: Tested with X.y.

1 Like