[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: Unable to install custom package using defined dependency version



Frank,

On Fri, May 26, 2017 at 6:54 AM, Frank <zuiderduin@gmx.com> wrote:
Op 25-05-17 om 23:36 schreef Sijis Aviles:
It seems that my qualifier of '=' isn't working as I expect. What am I doing
wrong?

You appear to assume you can tell apt to ignore a newer version of one package by specifying a previous version of that package as a dependency of another package. You can't.

Oh bummer!
 

apt will always go for the most recent version mentioned in the package list*), unless you explicitely tell it not to in the apt-get install command for that package. In this case apt wants to get app-configs 1.0-6~bbbb, notices my-app needs 1.0-5~aaa and tells you it can't install my-app because of that.

I'm not sure what you're aiming for with those two versions of app-configs. You can only have one of them installed at a time anyway. If the machine you want to install my-app on doesn't need 1.0.6~bbbb, you could try

apt-get install my-app app-configs=1.0-5~aaa

As suggested, I was able to tell apt to install the specific 1.0.5~aaa package first and then I was able to install 'my-app' in a subsequent command. This works but its not what I was expecting to do.

What I was trying to do was automatically build 'my-app' and 'app-configs' (via Jenkins) every day and upload those .deb files to Artifactory in a single repo. At some point in time (about once a week), I would want to release 'my-app' and update its control file to use a specified version of 'app-configs' (probably not the latest), then I would use a script to install this version of 'my-app', which would only require the specific version of app-configs.

If I understand what you say, only 1 version of app-configs should be available in the debian repo in order for this to work. If that's the case, then what are my options? Does each daily build of 'my-app' and 'app-configs' go into a separate repository?

I do find it strange that I was able to use apt-get install app-configs=1.0.5~aaa but I cannot specificy something similar through a control file.


You may have to 'hold' app-configs after that, because apt-get upgrade will 'see' the newer version and may want to remove my-app again (I'm not absolutely sure about this, as I'm tracking Testing so I always use dist-upgrade - which definitely will remove my-app).

Regards,
Frank


*) I'm ignoring 'priority pinning' here, as we're talking about a single repository
I'm actually quite curious about this, as I was anticipating coping the 'released' my-app and app-configs into a separate repository for 'safer' keeping.

Thanks again for an advice you can provide.

Sijis


Reply to: