[Date Prev][Date Next] [Thread Prev][Thread Next]
[Thread Index]
[Date Index]
[Author Index]
Re: Creating subpackages dynamically
- From: Valery Reznic <valery_reznic yahoo com>
- To: RPM Package Manager <rpm-list redhat com>
- Subject: Re: Creating subpackages dynamically
- Date: Tue, 2 Jan 2007 03:29:39 -0800 (PST)
--- Erez Zilber <erezz voltaire com> wrote:
> Valery Reznic wrote:
> > --- Erez Zilber <erezz voltaire com> wrote:
> >
> >
> >> Valery Reznic wrote:
> >>
> >>> --- Erez Zilber <erezz voltaire com> wrote:
> >>>
> >>>
> >>>
> >>>> Hi,
> >>>>
> >>>> I'm building rpms for 2 different distributions
> >>>> (SuSE & RedHat) using a
> >>>> single spec file. In order to do that, I'm
> using
> >>>> "%package". The 2
> >>>> packages contain more or less the same files,
> but
> >>>> the package name is
> >>>> different.
> >>>>
> >>>>
> >>> You can make use %if and/or %? construction to
> >>>
> >> make
> >>
> >>> you package name, rpm filename, filelist depend
> on
> >>> distribution. No need for subpackages.
> >>>
> >>> Valery
> >>>
> >>>
> >>>
> >> Using something like:
> >>
> >> %if "%{_vendor}" == "suse"
> >> %if %sles_version == 10
> >> %define _build_name_fmt
> >> %_arch/sles-name-%{version}.%{release}.%_arch.rpm
> >> %endif
> >> %else
> >> %if %_vendor == "redhat"
> >> %define _build_name_fmt
> >>
> %_arch/redhat-name-%{version}.%{release}.%_arch.rpm
> >> %endif
> >> %endif
> >>
> > As long as i remember, %define "work" always, so
> this
> > code really problematic.
> >
> >
> >> was problematic and results in behavior like
> having
> >> 2 debuginfo rpms in
> >> RedHat instead of 1 normal rpm and 1 rpm with
> >> debuginfo.
> >>
> >> Why don't you recommend using "%package"?
> >>
> > I just suggested another approach to solve your
> > problem.
> >
> > You can have a look in
> > /usr/share/doc/rpm-<version>/conditionalbuilds
> >
> I didn't find anything that was relevant for my
> problem there.
> > By the way, what do you trying to achive ?
> > Do you want only rpm filenames different, or
> package
> > names different too ?
> >
> >
> The 2 packages are different. RedHat & SuSE pack it
> differently
> (different files and different package name) and I'm
> trying to build
> something that will fit both distros. Any other
> idea?
You can have one specfile template and use
sed/awk/perl whatever to generate specfile which suit
your distribution.
Valery.
>
> Thanks,
> Erez
>
> _______________________________________________
> Rpm-list mailing list
> Rpm-list redhat com
> https://www.redhat.com/mailman/listinfo/rpm-list
>
__________________________________________________
Do You Yahoo!?
Tired of spam? Yahoo! Mail has the best spam protection around
http://mail.yahoo.com
[Date Prev][Date Next] [Thread Prev][Thread Next]
[Thread Index]
[Date Index]
[Author Index]