<?xml version="1.0" encoding="utf-8" standalone="yes"?><rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:content="http://purl.org/rss/1.0/modules/content/"><channel><title>Rpm on Life</title><link>/tags/rpm/</link><description>Recent content in Rpm on Life</description><generator>Hugo</generator><language>en-us</language><lastBuildDate>Fri, 08 May 2009 19:26:00 +0530</lastBuildDate><atom:link href="/tags/rpm/index.xml" rel="self" type="application/rss+xml"/><item><title>RPM, rpmbuild, and Macros</title><link>/post/2009/2009-05-08-rpm-rpmbuild-and-macros/</link><pubDate>Fri, 08 May 2009 19:26:00 +0530</pubDate><guid>/post/2009/2009-05-08-rpm-rpmbuild-and-macros/</guid><description>&lt;p&gt;When building RPMs, avoid using the root account. Fedora 11 configures non-root packaging by default. On other systems, create a &lt;code&gt;.rpmmacros&lt;/code&gt; file in your home directory with the following line:&lt;/p&gt;
&lt;div class="highlight"&gt;&lt;pre tabindex="0" style="color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;-webkit-text-size-adjust:none;"&gt;&lt;code class="language-ini" data-lang="ini"&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;&lt;span style="color:#a6e22e"&gt;%_topdir %{getenv:HOME}/rpmbuild&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;As an added bonus for systems with multilib architectures (such as &lt;code&gt;x86_64&lt;/code&gt;), add this format string to &lt;code&gt;.rpmmacros&lt;/code&gt;:&lt;/p&gt;
&lt;div class="highlight"&gt;&lt;pre tabindex="0" style="color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;-webkit-text-size-adjust:none;"&gt;&lt;code class="language-ini" data-lang="ini"&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;&lt;span style="color:#a6e22e"&gt;%_solve_name_fmt %{?_solve_pkgsdir}/%%{NAME}-%%{VERSION}-%%{RELEASE}.%%{ARCH}&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;&lt;strong&gt;Reference:&lt;/strong&gt;
&lt;a href="http://sadiquepp.blogspot.com/2009/02/how-to-patch-and-recompile-source-rpm.html"&gt;How to patch and recompile a source RPM&lt;/a&gt;&lt;/p&gt;</description></item></channel></rss>