Why does rpmbuild ignore BuildRoot in spec file?

Solution Verified - Updated -

Issue

  • I used rpmdev-newspec to generate a sample .spec file to start my own .spec

BuildRoot in .spec file generated by rpmdev-newspec:

BuildRoot:      %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)

Actual BuildRoot used by RPM:

$HOME/rpmbuild/BUILDROOT/

Environment

  • Red Hat Enterprise Linux 6
  • rpmdevtools-7.5-1.el6.noarch

Subscriber exclusive content

A Red Hat subscription provides unlimited access to our knowledgebase, tools, and much more.

Current Customers and Partners

Log in for full access

Log In

New to Red Hat?

Learn more about Red Hat subscriptions

Using a Red Hat product through a public cloud?

How to access this content