Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
50 changes: 25 additions & 25 deletions INSTALL.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,21 +4,21 @@

| Version | Fedora-based | Suse-based | Debian-based |
|:---------------:|:------------------:|:------------------:|:--------------:|
| 1.13 or later | automake | automake | automake |
| 2.64 or later | autoconf | autoconf | autoconf |
| 1.16 or later | automake | automake | automake |
| 2.71 or later | autoconf | autoconf | autoconf |
Comment thread
clumens marked this conversation as resolved.
| | libtool | libtool | libtool |
| | libtool-ltdl-devel | | libltdl-dev |
| | libuuid-devel | libuuid-devel | uuid-dev |
| 0.28 or later | pkgconfig | pkgconfig | pkg-config |
| 2.42.0 or later | glib2-devel | glib2-devel | libglib2.0-dev |
| 2.9.2 or later | libxml2-devel | libxml2-devel | libxml2-dev |
| 2.1.0 or later | pkgconf-pkg-config | pkgconfig | pkg-config |
| 2.80.0 or later | glib2-devel | glib2-devel | libglib2.0-dev |
| 2.12.5 or later | libxml2-devel | libxml2-devel | libxml2-dev |
| | libxslt-devel | libxslt-devel | libxslt-dev |
| | bzip2-devel | libbz2-devel | libbz2-dev |
| 1.0.1 or later | libqb-devel | libqb-devel | libqb-dev |
| 3.6 or later | python3 | python3 | python3 |
| 0.18 or later | gettext-devel | gettext-tools | gettext |
| 2.0.8 or later | libqb-devel | libqb-devel | libqb-dev |
| 3.12.11 or later| python3 | python3 | python3 |
| 0.22 or later | gettext-devel | gettext-tools | gettext |
| 0.18 or later | | | autopoint |
| 3.4.6 or later | gnutls-devel | libgnutls-devel | libgnutls-dev |
| 3.8.9 or later | gnutls-devel | libgnutls-devel | libgnutls-dev |

Also:
* make must be GNU (or compatible) (setting MAKE=gmake might also work but is
Expand All @@ -31,29 +31,29 @@ Also:

| Version | Fedora-based | Suse-based | Debian-based |
|:---------------:|:------------------:|:------------------:|:--------------:|
| 2.0.0 or later | corosynclib | libcorosync | corosync |
| 2.0.0 or later | corosynclib-devel | libcorosync-devel | |
| 3.1.9 or later | corosynclib | libcorosync | corosync |
| 3.1.9 or later | corosynclib-devel | libcorosync-devel | |
| | | | libcfg-dev |
| | | | libcpg-dev |
| | | | libcmap-dev |
| | | | libquorum-dev |

### Optional Build Dependencies

| Feature Enabled | Version | Fedora-based | Suse-based | Debian-based |
|:-----------------------------------------------:|:--------------:|:-----------------------:|:-----------------------:|:-----------------------:|
| encrypted remote CIB admin | | pam-devel | pam-devel | libpam0g-dev |
| interactive crm_mon | | ncurses-devel | ncurses-devel | ncurses-dev |
| systemd support | | systemd-devel | systemd-devel | libsystemd-dev |
| systemd resource support | 1.5.12 or later| dbus-devel | dbus-devel | libdbus-1-dev |
| Linux-HA style fencing agents | | cluster-glue-libs-devel | libglue-devel | cluster-glue-dev |
| documentation | | help2man | help2man | help2man |
| documentation | | docbook-style-xsl | docbook-xsl-stylesheets | docbook-xsl |
| documentation | | python3-sphinx | python3-sphinx | python3-sphinx |
| documentation (PDF) | | latexmk texlive texlive-capt-of texlive-collection-xetex texlive-fncychap texlive-framed texlive-multirow texlive-needspace texlive-tabulary texlive-titlesec texlive-threeparttable texlive-upquote texlive-wrapfig texlive-xetex | texlive texlive-latex | texlive texlive-latex-extra |
| annotated source code as HTML via "make global" | | global | global | global |
| RPM packages via "make rpm" | 4.14 or later | rpm | rpm | (n/a) |
| unit tests | 1.1.0 or later | libcmocka-devel | libcmocka-devel | libcmocka-dev |
| Feature Enabled | Version | Fedora-based | Suse-based | Debian-based |
|:-----------------------------------------------:|:---------------:|:-----------------------:|:-----------------------:|:-----------------------:|
| encrypted remote CIB admin | | pam-devel | pam-devel | libpam0g-dev |
| interactive crm_mon | | ncurses-devel | ncurses-devel | ncurses-dev |
| systemd support | | systemd-devel | systemd-devel | libsystemd-dev |
| systemd resource support | 1.14.10 or later| dbus-devel | dbus-devel | libdbus-1-dev |
| Linux-HA style fencing agents | | cluster-glue-libs-devel | libglue-devel | cluster-glue-dev |
| documentation | | help2man | help2man | help2man |
| documentation | | docbook-style-xsl | docbook-xsl-stylesheets | docbook-xsl |
| documentation | | python3-sphinx | python3-sphinx | python3-sphinx |
| documentation (PDF) | | latexmk texlive texlive-capt-of texlive-collection-xetex texlive-fncychap texlive-framed texlive-multirow texlive-needspace texlive-tabulary texlive-titlesec texlive-threeparttable texlive-upquote texlive-wrapfig texlive-xetex | texlive texlive-latex | texlive texlive-latex-extra |
| annotated source code as HTML via "make global" | | global | global | global |
| RPM packages via "make rpm" | 4.19.1 or later | rpm | rpm | (n/a) |

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We don't appear to enforce this one anywhere either

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No, and I don't think we're really supposed to. I think it's generally considered better form in the spec file to conditionalize on the OS version or test that a macro is present before using it.

| unit tests | 1.1.0 or later | libcmocka-devel | libcmocka-devel | libcmocka-dev |

## Optional Testing Dependencies
* procps and psmisc (if running CTS lab)
Expand Down
25 changes: 11 additions & 14 deletions configure.ac
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ dnl Bootstrap autotools
dnl ==============================================

# Require a minimum version of autoconf itself
AC_PREREQ(2.64)
AC_PREREQ(2.71)

dnl AC_CONFIG_MACRO_DIR is deprecated as of autoconf 2.70 (2020-12-08).
dnl Once we can require that version, we can simplify this, and no longer
Expand Down Expand Up @@ -47,14 +47,14 @@ dnl - Should not include HAVE_* defines
dnl - Safe to include anywhere
AC_CONFIG_HEADERS([include/config.h include/crm_config.h])

dnl 1.13: minimum automake version required
dnl 1.16: minimum automake version required
dnl foreign: don't require GNU-standard top-level files
dnl tar-ustar: use (older) POSIX variant of generated tar rather than v7
dnl subdir-objects: keep .o's with their .c's (no-op in 2.0+)
AM_INIT_AUTOMAKE([1.13 foreign tar-ustar subdir-objects])
AM_INIT_AUTOMAKE([1.16 foreign tar-ustar subdir-objects])

dnl Require minimum version of pkg-config
PKG_PROG_PKG_CONFIG(0.28)
PKG_PROG_PKG_CONFIG(2.1.0)
AS_IF([test x"${PKG_CONFIG}" != x""], [],
[AC_MSG_FAILURE([Could not find required build tool pkg-config (0.28 or later)])])
PKG_INSTALLDIR
Expand All @@ -71,9 +71,6 @@ AC_PROG_CC
dnl C++ is needed only to run maintainer utilities, not to build
AC_PROG_CXX

dnl Use at least C99 if possible (automatic for autoconf >= 2.70)
m4_version_prereq([2.70], [:], [AC_PROG_CC_STDC])

# cc_supports_flag <compiler-flag>
# Return success if the C compiler supports the given flag
cc_supports_flag() {
Expand Down Expand Up @@ -261,7 +258,7 @@ AC_DEFUN([AM_NLS],
AC_SUBST([USE_NLS])]
)
AM_GNU_GETTEXT([external])
AM_GNU_GETTEXT_VERSION([0.18])
AM_GNU_GETTEXT_VERSION([0.22])

dnl --with-* options: external software support, and custom values

Expand Down Expand Up @@ -517,7 +514,7 @@ dnl If PYTHON was specified, ensure it is an absolute path
AS_IF([test x"${PYTHON}" != x""], [AC_PATH_PROG([PYTHON], [$PYTHON])])

dnl Require a minimum Python version
AM_PATH_PYTHON([3.6])
AM_PATH_PYTHON([3.12.11])

AC_PROG_LN_S
AC_PROG_MKDIR_P
Expand Down Expand Up @@ -1072,14 +1069,14 @@ PKG_CHECK_MODULES([UUID], [uuid],
LIBS="${LIBS} ${UUID_LIBS}"])

# Require minimum glib version
PKG_CHECK_MODULES([GLIB], [glib-2.0 >= 2.42.0],
PKG_CHECK_MODULES([GLIB], [glib-2.0 >= 2.80.0],
[CPPFLAGS="${CPPFLAGS} ${GLIB_CFLAGS}"
LIBS="${LIBS} ${GLIB_LIBS}"])

# Check whether high-resolution sleep function is available
AC_CHECK_FUNCS([nanosleep usleep])

PKG_CHECK_MODULES(LIBXML2, [libxml-2.0 >= 2.9.2],
PKG_CHECK_MODULES(LIBXML2, [libxml-2.0 >= 2.12.5],
[CPPFLAGS="${CPPFLAGS} ${LIBXML2_CFLAGS}"
LIBS="${LIBS} ${LIBXML2_LIBS}"])

Expand Down Expand Up @@ -1400,7 +1397,7 @@ dnl ========================================================================
dnl Cluster infrastructure - LibQB
dnl ========================================================================

PKG_CHECK_MODULES([libqb], [libqb >= 1.0.1])
PKG_CHECK_MODULES([libqb], [libqb >= 2.0.8])
CPPFLAGS="$libqb_CFLAGS $CPPFLAGS"
LIBS="$libqb_LIBS $LIBS"

Expand Down Expand Up @@ -1443,7 +1440,7 @@ dnl ===============================

HAVE_dbus=0
PC_NAME_DBUS=""
PKG_CHECK_MODULES([DBUS],[dbus-1 >= 1.5.12],
PKG_CHECK_MODULES([DBUS],[dbus-1 >= 1.14.10],
[
HAVE_dbus=1
PC_NAME_DBUS="dbus-1"
Expand Down Expand Up @@ -1608,7 +1605,7 @@ dnl ========================================================================
dnl GnuTLS
dnl ========================================================================

PKG_CHECK_MODULES(GNUTLS, [gnutls >= 3.4.6],
PKG_CHECK_MODULES(GNUTLS, [gnutls >= 3.8.9],
[CPPFLAGS="${CPPFLAGS} ${GNUTLS_CFLAGS}"
LIBS="${LIBS} ${GNUTLS_LIBS}"])

Expand Down
84 changes: 28 additions & 56 deletions rpm/pacemaker.spec.in
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
#
# Copyright 2008-2025 the Pacemaker project contributors
# Copyright 2008-2026 the Pacemaker project contributors
#
# The version control history for this file may have further details.
#
Expand Down Expand Up @@ -43,51 +43,27 @@
## Upstream commit (full commit ID, abbreviated commit ID, or tag) to build
%global commit HEAD

## Since git v2.11, the extent of abbreviation is autoscaled by default
## (used to be constant of 7), so we need to convey it for non-tags, too.
%if 0%{?fedora} || (0%{?rhel} >= 9)
%global commit_abbrev 9
%else
%global commit_abbrev 7
%endif


# Define conditionals so that "rpmbuild --with <feature>" and
# "rpmbuild --without <feature>" can enable and disable specific features

## Use systemd to create users/groups as required
%if (0%{?fedora} >= 38)
%bcond_without use_sysusers
%else
%bcond_with use_sysusers
%endif
## Use systemd to create users/groups
%bcond use_sysusers %[ 0%{?fedora} >= 38 ]

## Add option for Linux-HA (stonith/external) fencing agent support
%if 0%{?suse_version}
%bcond_without linuxha
%else
%bcond_with linuxha
%endif
%bcond linuxha 0%{?suse_version}

## Add option for whether to support storing sensitive information outside CIB
%if (0%{?fedora} && 0%{?fedora} <= 33) || (0%{?rhel} && 0%{?rhel} <= 8)
%bcond_with cibsecrets
%else
%bcond_without cibsecrets
%endif
%bcond cibsecrets %[ ! ((0%{?fedora} && 0%{?fedora} <= 33) || (0%{?rhel} && 0%{?rhel} <= 8)) ]

## Add option to enable Native Language Support (experimental)
%bcond_with nls
%bcond nls 0

## Add option to create binaries suitable for use with profiling tools
%bcond_with profiling
%bcond profiling 0

## Allow deprecated option to skip (or enable, on RHEL) documentation
%if 0%{?rhel}
%bcond_with doc
%else
%bcond_without doc
%endif
%bcond doc %[ ! 0%{?rhel} ]

## Add option to default to start-up synchronization with SBD.
##
Expand All @@ -96,18 +72,14 @@
## to synchronization improves safety, without requiring higher-level tools
## to be aware of the setting or requiring users to modify configurations
## after upgrading to versions that support synchronization.
%if 0%{?rhel} && 0%{?rhel} > 8
%bcond_without sbd_sync
%else
%bcond_with sbd_sync
%endif
%bcond sbd_sync %[ 0%{?rhel} > 8 ]

## Add option to prefix package version with "0."
## (so later "official" packages will be considered updates)
%bcond_with pre_release
%bcond pre_release 0

## Add option to turn off hardening of libraries and daemon executables
%bcond_without hardening
%bcond hardening 1

# Define globals for convenient use later

Expand Down Expand Up @@ -136,7 +108,7 @@
%define pcmk_release %{specversion}
%endif
%else
%define archive_version %(c=%{commit}; echo ${c:0:%{commit_abbrev}})
%define archive_version %(c=%{commit}; echo ${c:0:9})
%define archive_github_url %{archive_version}#/%{name}-%{archive_version}.tar.gz
%if %{with pre_release}
%define pcmk_release 0.%{specversion}.%{archive_version}.git
Expand Down Expand Up @@ -266,12 +238,12 @@ BuildRequires: %{python_name}-devel
BuildRequires: %{python_name}-setuptools

# Pacemaker requires a minimum libqb functionality
Requires: libqb >= 1.0.1
BuildRequires: pkgconfig(libqb) >= 1.0.1
Requires: libqb >= 2.0.8
BuildRequires: pkgconfig(libqb) >= 2.0.8

# Required basic build tools
BuildRequires: autoconf
BuildRequires: automake
BuildRequires: autoconf >= 2.71
BuildRequires: automake >= 1.16
BuildRequires: coreutils
BuildRequires: findutils
BuildRequires: gcc
Expand All @@ -281,32 +253,32 @@ BuildRequires: libtool
BuildRequires: %{?pkgname_libtool_devel}
%endif
BuildRequires: make
BuildRequires: pkgconfig >= 0.28
BuildRequires: pkgconfig >= 2.1.0
BuildRequires: sed

# Required for core functionality
BuildRequires: pkgconfig(glib-2.0) >= 2.42
BuildRequires: pkgconfig(gnutls) >= 3.4.6
BuildRequires: pkgconfig(libxml-2.0) >= 2.9.2
BuildRequires: pkgconfig(glib-2.0) >= 2.80
BuildRequires: pkgconfig(gnutls) >= 3.8.9
BuildRequires: pkgconfig(libxml-2.0) >= 2.12.5
BuildRequires: pkgconfig(systemd)
BuildRequires: libxslt-devel
BuildRequires: pkgconfig(uuid)
BuildRequires: %{pkgname_bzip2_devel}

# Enables optional functionality
BuildRequires: pkgconfig(dbus-1) >= 1.5.12
BuildRequires: pkgconfig(dbus-1) >= 1.14.10
BuildRequires: %{pkgname_docbook_xsl}
BuildRequires: help2man
BuildRequires: ncurses-devel
BuildRequires: pam-devel
BuildRequires: %{pkgname_gettext} >= 0.18
BuildRequires: %{pkgname_gettext} >= 0.22

# Required for "make check"
BuildRequires: libcmocka-devel >= 1.1.0
BuildRequires: %{python_name}-psutil

Requires: corosync >= 2.0.0
BuildRequires: corosync-devel >= 2.0.0
Requires: corosync >= 3.1.9
BuildRequires: corosync-devel >= 3.1.9

%if %{with linuxha}
BuildRequires: %{pkgname_glue_libs}-devel
Expand Down Expand Up @@ -426,14 +398,14 @@ Summary: Pacemaker development package
Requires: %{pkgname_pcmk_libs}%{?_isa} = %{version}-%{release}
Requires: %{name}-cluster-libs%{?_isa} = %{version}-%{release}
Requires: %{pkgname_bzip2_devel}%{?_isa}
Requires: corosync-devel >= 2.0.0
Requires: glib2-devel%{?_isa}
Requires: libqb-devel%{?_isa} >= 1.0.1
Requires: corosync-devel >= 3.1.9
Requires: glib2-devel%{?_isa} >= 2.80.0
Requires: libqb-devel%{?_isa} >= 2.0.8
%if %{defined pkgname_libtool_devel_arch}
Requires: %{?pkgname_libtool_devel_arch}
%endif
Requires: libuuid-devel%{?_isa}
Requires: libxml2-devel%{?_isa} >= 2.9.2
Requires: libxml2-devel%{?_isa} >= 2.12.5
Requires: libxslt-devel%{?_isa}

%description -n %{pkgname_pcmk_libs}-devel
Expand Down