Discussion:
Include source features in eclipse repository
(too old to reply)
Timo Rohrberg
2013-01-15 15:39:50 UTC
Permalink
Hello everybody,

in the attached demo projects, I am building a simple bundle, a feature
containing that bundle, and an eclipse p2 repository for publishing them.
The build for the feature uses the tycho-source-feature-plugin to also
build a source feature. Unfortunately that source feature is not published
within the eclipse p2 repository.

I already listed the source feature explicitly in the category.xml, but it
does not help. I also don't know how to specify the URL to the source
bundle correctly there as it is just available after a successful build of
the com.initplan.example.component.feature project.

I also tried to add the tycho-source-plugin and the
tycho-source-feature-plugin to the eclipse p2 repository build, but it does
not help either.

Do you have any ideas?

Thank you.

Regards
Timo
Nick Boldt
2013-01-15 16:12:53 UTC
Permalink
Your category.xml could contain foo.feature and foo.feature.source. That
should include the generated source feature (and contained source
plugins) on the update site.
Post by Timo Rohrberg
Hello everybody,
in the attached demo projects, I am building a simple bundle, a feature
containing that bundle, and an eclipse p2 repository for publishing
them. The build for the feature uses the tycho-source-feature-plugin to
also build a source feature. Unfortunately that source feature is not
published within the eclipse p2 repository.
I already listed the source feature explicitly in the category.xml, but
it does not help. I also don't know how to specify the URL to the source
bundle correctly there as it is just available after a successful build
of the com.initplan.example.component.feature project.
I also tried to add the tycho-source-plugin and the
tycho-source-feature-plugin to the eclipse p2 repository build, but it
does not help either.
Do you have any ideas?
Thank you.
Regards
Timo
_______________________________________________
tycho-user mailing list
https://dev.eclipse.org/mailman/listinfo/tycho-user
--
Nick Boldt :: http://nick.divbyzero.com
Nick Boldt
2013-01-15 18:39:35 UTC
Permalink
Site which contains features and feature.sources:

http://download.jboss.org/jbosstools/updates/nightly/core/trunk/

Built from here as an eclipse-update-site (using site.xml):

https://github.com/jbosstools/jbosstools-build-sites/blob/master/aggregate/site/pom.xml

---

Site which contains features and feature.sources:

http://download.jboss.org/jbosstools/builds/staging/jbosstools-4.1_trunk.component--central-maven-examples/all/repo/

Build from here as an eclipse-repository (using category.xml):

https://github.com/jbosstools/jbosstools-central/blob/master/site/pom.xml

N
Hello Nick,�
yes, that is exactly what I also thought of doing... Unfortunately, it
does not work. No *.feature.source.jar file is being copied into the
repository (update site). Even though resolving a target definition on
the resulting repository shows something like the source feature - but
this only seems to be a phantom which is not really usable.
Do you have any further hint?�
Thanks again.
Regards
Timo
Your category.xml could contain foo.feature and foo.feature.source.
That should include the generated source feature (and contained
source plugins) on the update site.
Hello everybody,
in the attached demo projects, I am building a simple bundle, a feature
containing that bundle, and an eclipse p2 repository for publishing
them. The build for the feature uses the
tycho-source-feature-plugin to
also build a source feature. Unfortunately that source feature is not
published within the eclipse p2 repository.
I already listed the source feature explicitly in the
category.xml, but
it does not help. I also don't know how to specify the URL to the source
bundle correctly there as it is just available after a
successful build
of the com.initplan.example.__component.feature project.
I also tried to add the tycho-source-plugin and the
tycho-source-feature-plugin to the eclipse p2 repository build, but it
does not help either.
Do you have any ideas?
Thank you.
Regards
Timo
_________________________________________________
tycho-user mailing list
https://dev.eclipse.org/__mailman/listinfo/tycho-user
<https://dev.eclipse.org/mailman/listinfo/tycho-user>
--
Nick Boldt :: http://nick.divbyzero.com
--
Nick Boldt :: http://nick.divbyzero.com
Simon Goodall
2013-01-15 16:17:35 UTC
Permalink
Hi Timo,

You can leave the URL parameter out of the category.xml file - it is not
needed by tycho. It can also be useful to specify the version as "0.0.0 -
this helps when using the Tycho set-versions plugin.

I think the problem in your case is a missing feature.properties file that
needs to exist in the sourceTemplateFeature directory. This can be just an
empty file.

HTH,

Simon
Post by Timo Rohrberg
Hello everybody,
in the attached demo projects, I am building a simple bundle, a feature
containing that bundle, and an eclipse p2 repository for publishing them.
The build for the feature uses the tycho-source-feature-plugin to also
build a source feature. Unfortunately that source feature is not published
within the eclipse p2 repository.
I already listed the source feature explicitly in the category.xml, but it
does not help. I also don't know how to specify the URL to the source
bundle correctly there as it is just available after a successful build of
the com.initplan.example.component.feature project.
I also tried to add the tycho-source-plugin and the
tycho-source-feature-plugin to the eclipse p2 repository build, but it does
not help either.
Do you have any ideas?
Thank you.
Regards
Timo
_______________________________________________
tycho-user mailing list
https://dev.eclipse.org/mailman/listinfo/tycho-user
Cristiano Gavião
2013-01-15 16:22:04 UTC
Permalink
Post by Simon Goodall
I think the problem in your case is a missing feature.properties file
that needs to exist in the sourceTemplateFeature directory. This can
be just an empty file.
if I understood right this is not need anymore:
https://bugs.eclipse.org/bugs/show_bug.cgi?id=395711
Simon Goodall
2013-01-15 16:25:55 UTC
Permalink
Perhaps, but that bug report targets Tycho 0.17.0 whereas your example
appears to be using 0.16.0.

Regards,

Simon
Post by Simon Goodall
I think the problem in your case is a missing feature.properties file
that needs to exist in the sourceTemplateFeature directory. This can be
just an empty file.
https://bugs.eclipse.org/bugs/**show_bug.cgi?id=395711<https://bugs.eclipse.org/bugs/show_bug.cgi?id=395711>
______________________________**_________________
tycho-user mailing list
https://dev.eclipse.org/**mailman/listinfo/tycho-user<https://dev.eclipse.org/mailman/listinfo/tycho-user>
Cristiano Gavião
2013-01-15 18:53:22 UTC
Permalink
Hi,

I patch a bit your demo project. it is now generating the source feature
but it is not adding the label and description feature.properties from
the sourceTemplateFeature folder.

perhaps someone here could take a look and find what is wrong or maybe
there is a bug.

regards,

Cristiano
Post by Timo Rohrberg
Hello everybody,
in the attached demo projects, I am building a simple bundle, a
feature containing that bundle, and an eclipse p2 repository for
publishing them. The build for the feature uses the
tycho-source-feature-plugin to also build a source feature.
Unfortunately that source feature is not published within the eclipse
p2 repository.
I already listed the source feature explicitly in the category.xml,
but it does not help. I also don't know how to specify the URL to the
source bundle correctly there as it is just available after a
successful build of the com.initplan.example.component.feature project.
I also tried to add the tycho-source-plugin and the
tycho-source-feature-plugin to the eclipse p2 repository build, but it
does not help either.
Do you have any ideas?
Thank you.
Regards
Timo
_______________________________________________
tycho-user mailing list
https://dev.eclipse.org/mailman/listinfo/tycho-user
Timo Rohrberg
2013-01-16 08:07:50 UTC
Permalink
Hello,

thank you for your help. Unfortunately, even your patched project did not
work for me. I tried to build it with a recent 3.0.4 apache maven
configured for our company network. The only thing I had to adjust is the
url of the tycho snapshots site as I could not use https connections from
within our company network. So I was just using the same url, but with a
normal http connection.

The source feature is generated within the
com.initplan.example.component.feature project. But that was working with
my demo project already. However, the source feature is not copied into the
resulting p2 repository within the target/repository folder in
com.initplan.example.component.build.

Also with my own version of the demo project it does not work if I provide
a feature.properties within the sourceTemplateFeature folder and am using
Tycho 0.16.0.

Does the publishing of source features really only work with the recent
Tycho snapshots? Once again: The source feature jar is generated, just the
copying into the resulting p2 repository does not work for me...

Do you have any ideas?

Thanks again.

Regards
Timo
Post by Cristiano Gavião
Hi,
I patch a bit your demo project. it is now generating the source feature
but it is not adding the label and description feature.properties from the
sourceTemplateFeature folder.
perhaps someone here could take a look and find what is wrong or maybe
there is a bug.
regards,
Cristiano
Hello everybody,
in the attached demo projects, I am building a simple bundle, a feature
containing that bundle, and an eclipse p2 repository for publishing them.
The build for the feature uses the tycho-source-feature-plugin to also
build a source feature. Unfortunately that source feature is not published
within the eclipse p2 repository.
I already listed the source feature explicitly in the category.xml, but
it does not help. I also don't know how to specify the URL to the source
bundle correctly there as it is just available after a successful build of
the com.initplan.example.component.feature project.
I also tried to add the tycho-source-plugin and the
tycho-source-feature-plugin to the eclipse p2 repository build, but it does
not help either.
Do you have any ideas?
Thank you.
Regards
Timo
_______________________________________________
_______________________________________________
tycho-user mailing list
https://dev.eclipse.org/mailman/listinfo/tycho-user
Simon Goodall
2013-01-16 08:59:44 UTC
Permalink
Hi,

Taking Cristiano's patched project, I added the following snippet to the
end of the build section of the feature pom to hook up the p2-metadata
creation. This now hooks up the source feature to the p2 repository;

<plugin>
<groupId>org.eclipse.tycho</groupId>
<artifactId>tycho-p2-plugin</artifactId>
<version>${tycho-version}</version>
<executions>
<execution>
<id>attached-p2-metadata</id>
<phase>package</phase>
<goals>
<goal>p2-metadata</goal>
</goals>
</execution>
</executions>
</plugin>


Regards,

Simon
Post by Timo Rohrberg
Hello,
thank you for your help. Unfortunately, even your patched project did not
work for me. I tried to build it with a recent 3.0.4 apache maven
configured for our company network. The only thing I had to adjust is the
url of the tycho snapshots site as I could not use https connections from
within our company network. So I was just using the same url, but with a
normal http connection.
The source feature is generated within the
com.initplan.example.component.feature project. But that was working with
my demo project already. However, the source feature is not copied into the
resulting p2 repository within the target/repository folder in
com.initplan.example.component.build.
Also with my own version of the demo project it does not work if I provide
a feature.properties within the sourceTemplateFeature folder and am using
Tycho 0.16.0.
Does the publishing of source features really only work with the recent
Tycho snapshots? Once again: The source feature jar is generated, just the
copying into the resulting p2 repository does not work for me...
Do you have any ideas?
Thanks again.
Regards
Timo
Post by Cristiano Gavião
Hi,
I patch a bit your demo project. it is now generating the source feature
but it is not adding the label and description feature.properties from the
sourceTemplateFeature folder.
perhaps someone here could take a look and find what is wrong or maybe
there is a bug.
regards,
Cristiano
Hello everybody,
in the attached demo projects, I am building a simple bundle, a feature
containing that bundle, and an eclipse p2 repository for publishing them.
The build for the feature uses the tycho-source-feature-plugin to also
build a source feature. Unfortunately that source feature is not published
within the eclipse p2 repository.
I already listed the source feature explicitly in the category.xml, but
it does not help. I also don't know how to specify the URL to the source
bundle correctly there as it is just available after a successful build of
the com.initplan.example.component.feature project.
I also tried to add the tycho-source-plugin and the
tycho-source-feature-plugin to the eclipse p2 repository build, but it does
not help either.
Do you have any ideas?
Thank you.
Regards
Timo
_______________________________________________
_______________________________________________
tycho-user mailing list
https://dev.eclipse.org/mailman/listinfo/tycho-user
_______________________________________________
tycho-user mailing list
https://dev.eclipse.org/mailman/listinfo/tycho-user
Timo Rohrberg
2013-01-16 09:19:19 UTC
Permalink
Hello,

perfect, this is working now - even for my own demo project using Tycho
0.16.0. And actually, including the tycho-p2-plugin as you did it, is
mentioned by Igor in one of the bug reports related to the
tycho-source-feature-plugin.

The only thing missing now is to correctly include the label and provider
information in the resulting feature and source feature.

Furthermore, resolving a target definition against the created p2
repository does show the feature and the source feature, but only the
binary component after resolving and downloading. The source of the
component is missing.

Any further hints, especially for the latter issue?

Regards
Timo
Post by Simon Goodall
Hi,
Taking Cristiano's patched project, I added the following snippet to the
end of the build section of the feature pom to hook up the p2-metadata
creation. This now hooks up the source feature to the p2 repository;
<plugin>
<groupId>org.eclipse.tycho</groupId>
<artifactId>tycho-p2-plugin</artifactId>
<version>${tycho-version}</version>
<executions>
<execution>
<id>attached-p2-metadata</id>
<phase>package</phase>
<goals>
<goal>p2-metadata</goal>
</goals>
</execution>
</executions>
</plugin>
Regards,
Simon
Post by Timo Rohrberg
Hello,
thank you for your help. Unfortunately, even your patched project did not
work for me. I tried to build it with a recent 3.0.4 apache maven
configured for our company network. The only thing I had to adjust is the
url of the tycho snapshots site as I could not use https connections from
within our company network. So I was just using the same url, but with a
normal http connection.
The source feature is generated within the
com.initplan.example.component.feature project. But that was working with
my demo project already. However, the source feature is not copied into the
resulting p2 repository within the target/repository folder in
com.initplan.example.component.build.
Also with my own version of the demo project it does not work if I
provide a feature.properties within the sourceTemplateFeature folder and am
using Tycho 0.16.0.
Does the publishing of source features really only work with the recent
Tycho snapshots? Once again: The source feature jar is generated, just the
copying into the resulting p2 repository does not work for me...
Do you have any ideas?
Thanks again.
Regards
Timo
Post by Cristiano Gavião
Hi,
I patch a bit your demo project. it is now generating the source feature
but it is not adding the label and description feature.properties from the
sourceTemplateFeature folder.
perhaps someone here could take a look and find what is wrong or maybe
there is a bug.
regards,
Cristiano
Hello everybody,
in the attached demo projects, I am building a simple bundle, a feature
containing that bundle, and an eclipse p2 repository for publishing them.
The build for the feature uses the tycho-source-feature-plugin to also
build a source feature. Unfortunately that source feature is not published
within the eclipse p2 repository.
I already listed the source feature explicitly in the category.xml, but
it does not help. I also don't know how to specify the URL to the source
bundle correctly there as it is just available after a successful build of
the com.initplan.example.component.feature project.
I also tried to add the tycho-source-plugin and the
tycho-source-feature-plugin to the eclipse p2 repository build, but it does
not help either.
Do you have any ideas?
Thank you.
Regards
Timo
_______________________________________________
_______________________________________________
tycho-user mailing list
https://dev.eclipse.org/mailman/listinfo/tycho-user
_______________________________________________
tycho-user mailing list
https://dev.eclipse.org/mailman/listinfo/tycho-user
_______________________________________________
tycho-user mailing list
https://dev.eclipse.org/mailman/listinfo/tycho-user
Sievers, Jan
2013-01-16 11:49:21 UTC
Permalink
The only thing missing now is to correctly include the label and provider information in the resulting feature and source feature.
https://bugs.eclipse.org/bugs/show_bug.cgi?id=374349

Jan
Cristiano Gavião
2013-01-16 13:26:41 UTC
Permalink
Jan,

you have pointed us to a already resolved issue.

but even setting up the way is discussed in it I could not make it work
properly using the example here...

I have opened another bug in [1] and attached a new patched project that
is using 0.17 and using this:

<plugin>
<groupId>org.eclipse.tycho.extras</groupId>
<artifactId>tycho-source-feature-plugin</artifactId>
<version>${tycho-version}</version>
<executions>
<execution>
<id>source-feature</id>
<phase>package</phase>
<goals>
<goal>source-feature</goal>
</goals>
</execution>
</executions>
<configuration>
<labelSuffix>(source)</labelSuffix>
</configuration>
</plugin>

1 - https://bugs.eclipse.org/bugs/show_bug.cgi?id=398250
Post by Sievers, Jan
The only thing missing now is to correctly include the label and provider information in the resulting feature and source feature.
https://bugs.eclipse.org/bugs/show_bug.cgi?id=374349
Jan
_______________________________________________
tycho-user mailing list
https://dev.eclipse.org/mailman/listinfo/tycho-user
Cristiano Gavião
2013-01-16 17:02:32 UTC
Permalink
Hi Simon,

Finally I had the time to try the workaround suggested by you.

I could confirm that it works in my project too.

thanks a lot.

Cristiano
Post by Simon Goodall
Hi,
Taking Cristiano's patched project, I added the following snippet to
the end of the build section of the feature pom to hook up the
p2-metadata creation. This now hooks up the source feature to the p2
repository;
<plugin>
<groupId>org.eclipse.tycho</groupId>
<artifactId>tycho-p2-plugin</artifactId>
<version>${tycho-version}</version>
<executions>
<execution>
<id>attached-p2-metadata</id>
<phase>package</phase>
<goals>
<goal>p2-metadata</goal>
</goals>
</execution>
</executions>
</plugin>
Regards,
Simon
Hello,
thank you for your help. Unfortunately, even your patched project
did not work for me. I tried to build it with a recent 3.0.4
apache maven configured for our company network. The only thing I
had to adjust is the url of the tycho snapshots site as I could
not use https connections from within our company network. So I
was just using the same url, but with a normal http connection.
The source feature is generated within the
com.initplan.example.component.feature project. But that was
working with my demo project already. However, the source feature
is not copied into the resulting p2 repository within the
target/repository folder in com.initplan.example.component.build.
Also with my own version of the demo project it does not work if I
provide a feature.properties within the sourceTemplateFeature
folder and am using Tycho 0.16.0.
Does the publishing of source features really only work with the
recent Tycho snapshots? Once again: The source feature jar is
generated, just the copying into the resulting p2 repository does
not work for me...
Do you have any ideas?
Thanks again.
Regards
Timo
Hi,
I patch a bit your demo project. it is now generating the
source feature but it is not adding the label and description
feature.properties from the sourceTemplateFeature folder.
perhaps someone here could take a look and find what is wrong
or maybe there is a bug.
regards,
Cristiano
Post by Timo Rohrberg
Hello everybody,
in the attached demo projects, I am building a simple bundle,
a feature containing that bundle, and an eclipse p2
repository for publishing them. The build for the feature
uses the tycho-source-feature-plugin to also build a source
feature. Unfortunately that source feature is not published
within the eclipse p2 repository.
I already listed the source feature explicitly in the
category.xml, but it does not help. I also don't know how to
specify the URL to the source bundle correctly there as it is
just available after a successful build of the
com.initplan.example.component.feature project.
I also tried to add the tycho-source-plugin and the
tycho-source-feature-plugin to the eclipse p2 repository
build, but it does not help either.
Do you have any ideas?
Thank you.
Regards
Timo
_______________________________________________
tycho-user mailing list
https://dev.eclipse.org/mailman/listinfo/tycho-user
_______________________________________________
tycho-user mailing list
https://dev.eclipse.org/mailman/listinfo/tycho-user
_______________________________________________
tycho-user mailing list
https://dev.eclipse.org/mailman/listinfo/tycho-user
_______________________________________________
tycho-user mailing list
https://dev.eclipse.org/mailman/listinfo/tycho-user
Continue reading on narkive:
Loading...