Re: Optional %files support - (A or B or C)

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

 



It was <2021-10-20 śro 16:51>, when Graham Leggett wrote:
> Hi all,
>
> I am trying to package an Apache module in such a way that it can be built across distributions.
>
> The BuildRequires and Requires both work fine as follows:
>
> BuildRequires: gcc, pkgconfig(apr-1), pkgconfig(apr-util-1), (httpd-devel or apache-devel or apache2-devel)
> Requires: (httpd or apache or apache2)
>
> My next problem is the %files section. The modules will be installed in one of two locations:
>
> (%{_libdir}/apache2/mod_mymodule.so or %{_libdir}/httpd/modules/mod_mymodule.so)
>
> Is there a syntax like Requires that can specify a file at location A or B or C?
>
> Obviously the workaround is using %if to target certain macros on
> certain distros, but I've just had one of these macros arbitrarily
> disappear on a platform, so this is brittle and painful.
>
> Is there a better way to do this?

How about defining %{_apache_mod_dir} and using it in the %files
section?

-- 
Łukasz Stelmach
Samsung R&D Institute Poland
Samsung Electronics

Attachment: signature.asc
Description: PGP signature

_______________________________________________
Rpm-list mailing list
Rpm-list@xxxxxxxxxxxxx
http://lists.rpm.org/mailman/listinfo/rpm-list

[Index of Archives]     [RPM Ecosystem]     [Linux Kernel]     [Red Hat Install]     [PAM]     [Red Hat Watch]     [Red Hat Development]     [Red Hat]     [Gimp]     [Yosemite News]     [IETF Discussion]

  Powered by Linux