Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [tycho-user] Exporting a Target Definition file

Am 24.11.2011 17:29, schrieb Igor Fedorenko:

> What is the purpose of the local P2 repository? To you need it for
> performance and reliability reasons or for something else?

Performance and reliability. As I said before, if I add the Indigo p2
site to my parent POM, "mvn clean" takes betwen five and 15 minutes.

And my build contains a couple of other sites which are even less reliable.

> In any case, I do not believe it is not currently possible to generate
> local p2 repository from .target file directly, but you should be able
> to setup eclipse-repository project to do that. It should also be
> possible to develop tycho extensions plugin to do what you want, I can
> give some pointers if you are interested.
> 
> Also, .target file with mode=slicer guarantees reproducible builds, i.e.
> the build will either use specific and stable set of dependencies or it
> will fail if some of the dependencies are not available. If build
> reproducibility is your main concern, you can use .target file directly,
> without intermediate p2 repository. The intermediate repository can be
> tricky to keep up-to-date on all developer machines.

I understand. In that case, I'll prepare the repo on my machine and put
it on our internal web servers, so every developer can consume it from
there.

I'd still like an automated way to create this repo from the .target
file. Your idea to build a plugin sounds tempting but looking at the
list of projects that I'm involved ... *sigh*

What is "mode=slicer"? I've never heard about that before. So far, I've
selected specific versions of bundles in my .target file. This is clumsy.

For example, I have a dependency to the subversion bundles. They were
updated recently and the old versions were deleted from the repo. That
caused a lot of errors in the target file editor: All of a sudden all
site entries showed the error "Unable to locate bundle
org.eclipse.subversion.team.connector.source" :-(

I feel quite uneasy about the target file editors and the whole
technology around it. For example, I don't know how I can set the target
platform per project. This doesn't seem to be possible which is ... odd.

Maybe a POM with dependencies and a plugin that understands how to
download those into the target/ directory would be a good solution :-/

Regards,


>> The story so far. Since the mirror options in the p2 ant tasks either
>> download too much (the whole site with all versions of all IUs, >> 1Gb
>> for Indigo) or too little, I used a script to download features.
>>
>> Basically the script installs Eclipse, runs the ant task to install the
>> feature(s) I want and then deletes all the files which came from the
>> install ZIP. Which leaves me with a set of files in features/plugins
>> which work with the least amount of effort.
>>
>> Then I was told that Eclipse has a Target Definition editor which could
>> do the same for me.
>>
>> I was able to create a Target Definition file (took me only 3 days
>> because of various bugs in the editor; that's about the same amount of
>> work my first approach took, so I'm not sure how much there is to be
>> gained here... in fact with my own tool set, I know what every part does
>> and how to fix it.)
>>
>> When I click the "Export" button, Eclipse considers my puny request for
>> half an hour and then creates a directory with features and plugins.
>> This p2 repo is broken - Tycho won't find the SWT fragments in it, for
>> example - but it's a start. Using the
>> org.eclipse.equinox.p2.publisher.FeaturesAndBundlesPublisher, I can
>> convert this into something that Tycho will like.
>>
>> But I'd like something that I can pass on to a fellow developer without
>> many explanations: I want to 100% automate the process.
>>
>> Is there an ant task or a Tycho plugin to export a *.target file into a
>> p2 repository?
>>
>> Is there a better way to do this?
>>
>> Regards,
>>
> _______________________________________________
> tycho-user mailing list
> tycho-user@xxxxxxxxxxx
> https://dev.eclipse.org/mailman/listinfo/tycho-user
> 


-- 
Aaron "Optimizer" Digulla a.k.a. Philmann Dark
"It's not the universe that's limited, it's our imagination.
Follow me and I'll show you something beyond the limits."
http://blog.pdark.de/


Back to the top