Trouble strikes when order of dependencies matters

1 view
Skip to first unread message

Niklaus Giger

unread,
Feb 17, 2012, 6:14:28 PM2/17/12
to build...@googlegroups.com, Thomas Huster, Marco Descher
Hi Antoine

I am somehow successfull at building our PDE application Elexis. See
http://ngiger.dyndns.org/jenkins/view/buildr/job/elexis-2.2.dev_jpa-Buildr/18/

It was quite easy to use the IzPack installer to use the same artefacts to
generate an installer for various platforms.

But I still have problems to overcome, e.g. I have not yet found an easy way
to import an eclipse target definition as maven artefacts. Therefore I use for
this step still buckminster, where it is a no-brainer.

Currently I am stuck that I have a situation where I have to manually change
the generated dependencies.yml as the order of dependents projects decides
whether files compile or not.

Eg. the project at.medevit.elexis.jpapoadapter compiles fine when I have in
dependencies.yml the lines
> projects:
> - elexis:ch.elexis
> - elexis:at.medevit.elexis.model
> - elexis:ch.elexis.core
but fails with the sorted (default)
> projects:
> - elexis:at.medevit.elexis.model
> - elexis:ch.elexis
> - elexis:ch.elexis.core
Why? Both at.medevit.elexis.model and ch.elexis define Kontakt inside the
package ch.elexis.data. ch.elexis defines it as
public class Kontakt extends PersistentObject
Therefore compiling jpapoadapter fails, as it does not see the methods coming
from PersistentObject.

Do you see any easy solution to it? And as far as I understood buildr4osgi one
cannot easily get an unsorted array of dependencies as its structure depend on
a SortedHash.

Is there a way to override the order of dependencies from inside a project? I
didn't spot any easy method and used a simple script to patch the order inside
the dependencies.yml.

Thanks a lot for you attention.

Best regards

--
Niklaus Giger

Antoine Toulme

unread,
Feb 17, 2012, 6:59:02 PM2/17/12
to build...@googlegroups.com, Thomas Huster, Marco Descher
No, this never came up before.

In general, you generate the dependencies.yml once, and you don't recreate it. I would manually reorder as needed, commit, and ensure everybody is ok as is.

If this stuff is bigger than it should be, you should fork buildr4osgi and make it possible to sort the sortedHash with a block you define in the Buildfile.

I had created a buildr plugin for iZPack as well, it got pretty ancient by now:

Cheers,

Antoine
Reply all
Reply to author
Forward
0 new messages