Re: Newbie's first RPM goes wrong

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

 



> For a while I tried to make a relocatable RPM, but I have
> temporarily give up on that.

Actually relocatable rpm's are quite easy .. did you ever check the --prefix
<path> option that rpm has? from the man page:

       --prefix NEWPATH
              For relocateable binary packages, translate all file paths
that
              start  with  the  installation  prefix in the package
relocation
              hint(s) to NEWPATH.

And also for things that don't use constructs like %{_bindir} (which is
defined in your /usr/lib/rpm macro's as %{_prefix}/bin) you can use this:

       --relocate OLDPATH=NEWPATH
              For relocatable binary packages, translate all file  paths
that
              start with OLDPATH in the package relocation hint(s) to
NEWPATH.
              This option can be used repeatedly if several OLDPATHâs  in
the
              package are to be relocated.

ie if the spec states /usr/bin you can --relocate /usr=/opt/myprog
forinstance

> I think I don't need Prefix:
> or Buildroot: lines in my .spec file.  Right?

I never include any Prefix: in the spec file, but i do specify:
BuildRoot: BuildRoot: /%{_tmppath}/%{name}-%{version}-%{release}-root

    -- Chris


_______________________________________________
Rpm-list mailing list
Rpm-list@xxxxxxxxxx
https://www.redhat.com/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