0

I'm building a RPM package and one of my requirements is python-pip, only available in Epel repositories. (following line),

Requires:       python python-pip python-devel

If the OS already has epel-release installed, then everything works fine.

But if it's not installed, then I get a broken dependencies error.

I want to find a way that my RPM installs epel-release before checking for requirements.

I've tried to put epel-release in the same line, but it didn't work.

Is there a way of doing this? Installing it before checking for dependencies?

Michael Hampton
  • 237,123
  • 42
  • 477
  • 940
  • 2
    It is not for you to install another repo. You should check that it is installed or not and then tell the administrator that it is required. – user9517 Dec 29 '16 at 16:24

2 Answers2

1

A clean way to deal with this is checking if epel-release is installed in the %pre` section and aborting if it isn't.

Bruno9779
  • 182
  • 1
  • 1
  • 13
0

For now, I just put the epel dependency in the README file. But later I'll put it on the %pre section.