/usr/share/doc/drbd-doc/users-guide/s-build-rpm.html is in drbd-doc 8.4~20151102-1.
This file is owned by root:root, with mode 0o644.
The actual contents of the file can be viewed below.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 | <?xml version="1.0" encoding="UTF-8" standalone="no"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>4.4. Building a DRBD RPM package</title><link rel="stylesheet" type="text/css" href="default.css" /><meta name="generator" content="DocBook XSL Stylesheets V1.79.1" /><link rel="home" href="drbd-users-guide.html" title="The DRBD User’s Guide" /><link rel="up" href="ch-build-install-from-source.html" title="Chapter 4. Building and installing DRBD from source" /><link rel="prev" href="s-build-from-source.html" title="4.3. Building DRBD from source" /><link rel="next" href="s-build-deb.html" title="4.5. Building a DRBD Debian package" /></head><body><div class="navheader"><table width="100%" summary="Navigation header"><tr><th colspan="3" align="center">4.4. Building a DRBD RPM package</th></tr><tr><td width="20%" align="left"><a accesskey="p" href="s-build-from-source.html">Prev</a> </td><th width="60%" align="center">Chapter 4. Building and installing DRBD from source</th><td width="20%" align="right"> <a accesskey="n" href="s-build-deb.html">Next</a></td></tr></table><hr /></div><div class="section"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a id="s-build-rpm"></a>4.4. Building a DRBD RPM package</h2></div></div></div><p>The DRBD build system contains a facility to build RPM packages
directly out of the DRBD source tree. For building RPMs,
<a class="xref" href="s-build-from-source.html#s-build-prereq" title="4.3.1. Checking build prerequisites">Section 4.3.1, “Checking build prerequisites”</a> applies essentially in the same way as for building
and installing with <code class="literal">make</code>, except that you also need the RPM build
tools, of course.</p><p>Also, see <a class="xref" href="s-build-from-source.html#s-build-prepare-kernel-tree" title="4.3.2. Preparing the kernel source tree">Section 4.3.2, “Preparing the kernel source tree”</a> if you are not building
against a running kernel with precompiled headers available.</p><p>The build system offers two approaches for building RPMs. The simpler
approach is to simply invoke the <code class="literal">rpm</code> target in the top-level
Makefile:</p><pre class="screen">$ ./configure
$ make rpm
$ make km-rpm</pre><p>This approach will auto-generate spec files from pre-defined
templates, and then use those spec files to build binary RPM packages.</p><p>The <code class="literal">make rpm</code> approach generates a number of RPM packages:</p><div class="table"><a id="t-rpm-packages"></a><p class="title"><strong>Table 4.2. DRBD userland RPM packages</strong></p><div class="table-contents"><table class="table" summary="DRBD userland RPM packages" border="1"><colgroup><col class="col_1" /><col class="col_2" /><col class="col_3" /><col class="col_4" /></colgroup><thead><tr><th align="left" valign="top">Package name</th><th align="left" valign="top">Description</th><th align="left" valign="top">Dependencies</th><th align="left" valign="top">Remarks</th></tr></thead><tbody><tr><td align="left" valign="top"><p><code class="literal">drbd</code></p></td><td align="left" valign="top"><p>DRBD meta-package</p></td><td align="left" valign="top"><p>All other <code class="literal">drbd-*</code> packages</p></td><td align="left" valign="top"><p>Top-level virtual package. When installed, this pulls in all other userland packages as dependencies.</p></td></tr><tr><td align="left" valign="top"><p><code class="literal">drbd-utils</code></p></td><td align="left" valign="top"><p>Binary administration utilities</p></td><td align="left" valign="top"><p></p></td><td align="left" valign="top"><p>Required for any DRBD enabled host</p></td></tr><tr><td align="left" valign="top"><p><code class="literal">drbd-udev</code></p></td><td align="left" valign="top"><p>udev integration facility</p></td><td align="left" valign="top"><p><code class="literal">drbd-utils, udev</code></p></td><td align="left" valign="top"><p>Enables udev to manage user-friendly symlinks to DRBD devices</p></td></tr><tr><td align="left" valign="top"><p><code class="literal">drbd-xen</code></p></td><td align="left" valign="top"><p>Xen DRBD helper scripts</p></td><td align="left" valign="top"><p><code class="literal">drbd-utils, xen</code></p></td><td align="left" valign="top"><p>Enables xend to auto-manage DRBD resources</p></td></tr><tr><td align="left" valign="top"><p><code class="literal">drbd-heartbeat</code></p></td><td align="left" valign="top"><p>DRBD Heartbeat integration scripts</p></td><td align="left" valign="top"><p><code class="literal">drbd-utils, heartbeat</code></p></td><td align="left" valign="top"><p>Enables DRBD management by legacy v1-style Heartbeat clusters</p></td></tr><tr><td align="left" valign="top"><p><code class="literal">drbd-pacemaker</code></p></td><td align="left" valign="top"><p>DRBD Pacemaker integration scripts</p></td><td align="left" valign="top"><p><code class="literal">drbd-utils, pacemaker</code></p></td><td align="left" valign="top"><p>Enables DRBD management by Pacemaker clusters</p></td></tr><tr><td align="left" valign="top"><p><code class="literal">drbd-rgmanager</code></p></td><td align="left" valign="top"><p>DRBD Red Hat Cluster Suite integration scripts</p></td><td align="left" valign="top"><p><code class="literal">drbd-utils, rgmanager</code></p></td><td align="left" valign="top"><p>Enables DRBD management by rgmanager, the Red Hat Cluster Suite resource manager</p></td></tr><tr><td align="left" valign="top"><p><code class="literal">drbd-bashcompletion</code></p></td><td align="left" valign="top"><p>Progammable bash completion</p></td><td align="left" valign="top"><p><code class="literal">drbd-utils</code>, <code class="literal">bash-completion</code></p></td><td align="left" valign="top"><p>Enables Programmable bash completion for the <code class="literal">drbdadm</code> utility</p></td></tr></tbody></table></div></div><br class="table-break" /><p>The other, more flexible approach is to have <code class="literal">configure</code> generate the
spec file, make any changes you deem necessary, and then use the
<code class="literal">rpmbuild</code> command:</p><pre class="screen">$ ./configure --enable-spec
$ make tgz
$ cp drbd*.tar.gz `rpm -E %sourcedir`
$ rpmbuild -bb drbd.spec</pre><p>If you are about to build RPMs for both the DRBD userspace utilities
and the kernel module, use:</p><pre class="screen">$ ./configure --enable-spec --with-km
$ make tgz
$ cp drbd*.tar.gz `rpm -E %sourcedir`
$ rpmbuild -bb drbd.spec
$ rpmbuild -bb drbd-kernel.spec</pre><p>The RPMs will be created wherever your system RPM configuration (or
your personal <code class="literal">~/.rpmmacros</code> configuration) dictates.</p><p>After you have created these packages, you can install, upgrade, and
uninstall them as you would any other RPM package in your system.</p><p>Note that any kernel upgrade will require you to generate a new
<code class="literal">drbd-km</code> package to match the new kernel.</p><p>The DRBD userland packages, in contrast, need only be recreated when
upgrading to a new DRBD version. If at any time you upgrade to a new
kernel <span class="emphasis"><em>and</em></span> new DRBD version, you will need to upgrade both packages.</p></div><div class="navfooter"><hr /><table width="100%" summary="Navigation footer"><tr><td width="40%" align="left"><a accesskey="p" href="s-build-from-source.html">Prev</a> </td><td width="20%" align="center"><a accesskey="u" href="ch-build-install-from-source.html">Up</a></td><td width="40%" align="right"> <a accesskey="n" href="s-build-deb.html">Next</a></td></tr><tr><td width="40%" align="left" valign="top">4.3. Building DRBD from source </td><td width="20%" align="center"><a accesskey="h" href="drbd-users-guide.html">Home</a></td><td width="40%" align="right" valign="top"> 4.5. Building a DRBD Debian package</td></tr></table></div></body></html>
|