!13 [sync] PR-12: upgrade to 2.0.5

From: @openeuler-sync-bot 
Reviewed-by: @yangzhao_kl 
Signed-off-by: @yangzhao_kl
This commit is contained in:
openeuler-ci-bot 2022-05-07 02:43:02 +00:00 committed by Gitee
commit 15f47fffed
No known key found for this signature in database
GPG Key ID: 173E9B9CA92EEF8F
9 changed files with 99 additions and 233 deletions

View File

@ -1,44 +0,0 @@
From 47ecd21b9acb108eb4e024c51cdefadac2d74a64 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Jan=20Pokorn=C3=BD?= <jpokorny@redhat.com>
Date: Tue, 26 Nov 2019 20:07:36 +0100
Subject: [PATCH] Build: fix unability to build with Inkscape 1.0 beta
version(s)
...and possibly beyond.
References:
https://gitlab.com/inkscape/inbox/issues/1244
---
doc/Makefile.am | 11 ++++++++---
1 file changed, 8 insertions(+), 3 deletions(-)
diff --git a/doc/Makefile.am b/doc/Makefile.am
index 257f5cdf5..d8c846830 100644
--- a/doc/Makefile.am
+++ b/doc/Makefile.am
@@ -84,14 +84,19 @@ PNGS = $(PNGS_ORIGINAL) $(PNGS_GENERATED)
graphics: $(PNGS)
+
+# two-phased attempts for Inkscape pre-1.0 and 1.0+ (upcoming) discrepancy
%.png: %.svg
- $(AM_V_GEN)$(INKSCAPE) --file=$< --export-dpi=90 -C --export-png=$@ $(PCMK_quiet)
+ $(AM_V_GEN) { $(INKSCAPE) --export-dpi=90 -C --export-png=$@ $< \
+ || $(INKSCAPE) --export-dpi=90 -C --export-file=$@ $<; } $(PCMK_quiet)
%-small.png: %.svg
- $(AM_V_GEN)$(INKSCAPE) --file=$< --export-dpi=45 -C --export-png=$@ $(PCMK_quiet)
+ $(AM_V_GEN) { $(INKSCAPE) --export-dpi=45 -C --export-png=$@ $< \
+ || $(INKSCAPE) --export-dpi=45 -C --export-file=$@ $<; } $(PCMK_quiet)
%-large.png: %.svg
- $(AM_V_GEN)$(INKSCAPE) --file=$< --export-dpi=180 -C --export-png=$@ $(PCMK_quiet)
+ $(AM_V_GEN) { $(INKSCAPE) --export-dpi=180 -C --export-png=$@ $< \
+ || $(INKSCAPE) --export-dpi=180 -C --export-file=$@ $<; } $(PCMK_quiet)
if IS_ASCIIDOC
ASCIIDOC_HTML_ARGS = --unsafe --backend=xhtml11
--
2.24.0

View File

@ -1,13 +0,0 @@
diff --git a/cts/cts-cli.in b/cts/cts-cli.in
index cff4bbf..707403f 100644
--- a/cts/cts-cli.in
+++ b/cts/cts-cli.in
@@ -947,7 +947,7 @@ EOF
if [ "$(uname)" == "FreeBSD" ]; then
tomorrow=$(date -v+1d +"%F %T %z")
else
- tomorrow=$(date --date=tomorrow +"%F %T %z")
+ tomorrow=$(date --date=tomorrow +"%F %T")
fi
TMPXML=$(mktemp ${TMPDIR:-/tmp}/cts-cli.tools.xml.XXXXXXXXXX)

View File

@ -0,0 +1,10 @@
--- configure.ac 2020-12-03 01:08:53.000000000 +0800
+++ configure.ac 2022-02-16 06:04:06.770474753 +0800
@@ -1728,7 +1728,6 @@ dnl otherwise none of both
-Wno-long-long
-Wno-strict-aliasing
-Wpointer-arith
- -Wstrict-prototypes
-Wwrite-strings
-Wunused-but-set-variable
-Wunsigned-char"

View File

@ -1,34 +0,0 @@
From 77a79358cc72174cbba0dd44e313f6d06d96dbf4 Mon Sep 17 00:00:00 2001
From: Ken Gaillot <kgaillot@redhat.com>
Date: Thu, 2 Jan 2020 09:51:52 -0600
Subject: [PATCH] Refactor: attrd: properly declare global variables as extern in header
Restores buildability with GCC 10
---
daemons/attrd/pacemaker-attrd.h | 8 +++++---
1 file changed, 5 insertions(+), 3 deletions(-)
diff --git a/daemons/attrd/pacemaker-attrd.h b/daemons/attrd/pacemaker-attrd.h
index cc8e29ee1e..7b5ba03388 100644
--- a/daemons/attrd/pacemaker-attrd.h
+++ b/daemons/attrd/pacemaker-attrd.h
@@ -1,5 +1,7 @@
/*
- * Copyright 2013-2018 Andrew Beekhof <andrew@beekhof.net>
+ * Copyright 2013-2020 the Pacemaker project contributors
+ *
+ * The version control history for this file may have further details.
*
* This source code is licensed under the GNU General Public License version 2
* or later (GPLv2+) WITHOUT ANY WARRANTY.
@@ -106,8 +108,8 @@ typedef struct attribute_value_s {
gboolean seen;
} attribute_value_t;
-crm_cluster_t *attrd_cluster;
-GHashTable *attributes;
+extern crm_cluster_t *attrd_cluster;
+extern GHashTable *attributes;
#define attrd_send_ack(client, id, flags) \
crm_ipcs_send_ack((client), (id), (flags), "ack", __FUNCTION__, __LINE__)

View File

@ -1,65 +0,0 @@
From 2f2bd2f0236a311feb162d5e2a320b9b8d8ceb5b Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Jan=20Pokorn=C3=BD?= <jpokorny@redhat.com>
Date: Tue, 21 Jan 2020 18:24:44 +0100
Subject: [PATCH] Build: get ready for implicit -fno-common with upcoming GCC
10
Currently, -fno-common yields (and only yields, slightly restructured):
> /usr/bin/ld:
> pacemaker_execd-execd_commands.o:
> pcmk/daemons/execd/pacemaker-execd.h:23:
> multiple definition of `rsc_list';
> + pacemaker_execd-pacemaker-execd.o:
> pcmk/daemons/execd/pacemaker-execd.h:23:
> first defined here
>
> pacemaker_execd-execd_alerts.o:
> pcmk/daemons/execd/pacemaker-execd.h:23:
> multiple definition of `rsc_list';
> + pacemaker_execd-pacemaker-execd.o:
> pcmk/daemons/execd/pacemaker-execd.h:23:
> first defined here
>
> collect2: error: ld returned 1 exit status
The problem is that a global (with external linkage) variable without
explicit "extern" stands for "tentative definition" (as opposed to mere
reference to existing object with external linkage otherwise),
and these won't get automagically merged in -fno-common case (which
is going to be a default in upcoming GCC 10).
Solution is to explicitly add "extern" storage-class specifiers
at what's indeed meant as non-tentative reference in the header
files that are going to be included from various translation
units that will end up in the same link.
No more attempts at finding these was performed, just the only instance
that got hit in practice (see above) receives this treatment, since
manual work simply doesn't scale. Either a static analysis can be
employed to mark other potential show-stoppers, or we'll just deal
with the issues on case-by-case basis (with the gargantuan assistence
of CI systems).
References:
https://gcc.gnu.org/gcc-10/porting_to.html#common
---
daemons/execd/pacemaker-execd.h | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/daemons/execd/pacemaker-execd.h b/daemons/execd/pacemaker-execd.h
index 4a52d91..dab3ccd 100644
--- a/daemons/execd/pacemaker-execd.h
+++ b/daemons/execd/pacemaker-execd.h
@@ -20,7 +20,7 @@
# include <gnutls/gnutls.h>
# endif
-GHashTable *rsc_list;
+extern GHashTable *rsc_list;
typedef struct lrmd_rsc_s {
char *rsc_id;
--
2.23.0

Binary file not shown.

Binary file not shown.

View File

@ -3,6 +3,7 @@
## User and group to use for nonprivileged services ## User and group to use for nonprivileged services
%global uname hacluster %global uname hacluster
%global gname haclient %global gname haclient
%global hacluster_id 189
## Where to install Pacemaker documentation ## Where to install Pacemaker documentation
%global pcmk_docdir %{_docdir}/%{name} %global pcmk_docdir %{_docdir}/%{name}
@ -13,12 +14,12 @@
## Upstream pacemaker version, and its package version (specversion ## Upstream pacemaker version, and its package version (specversion
## can be incremented to build packages reliably considered "newer" ## can be incremented to build packages reliably considered "newer"
## than previously built packages with the same pcmkversion) ## than previously built packages with the same pcmkversion)
%global pcmkversion 2.0.3 %global pcmkversion 2.0.5
%global specversion 3 %global specversion 1
## Upstream commit (or git tag, such as "Pacemaker-" plus the ## Upstream commit (or git tag, such as "Pacemaker-" plus the
## {pcmkversion} macro for an official release) to use for this package ## {pcmkversion} macro for an official release) to use for this package
%global commit Pacemaker-2.0.3 %global commit Pacemaker-2.0.5
## Since git v2.11, the extent of abbreviation is autoscaled by default ## 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. ## (used to be constant of 7), so we need to convey it for non-tags, too.
%global commit_abbrev 9 %global commit_abbrev 9
@ -26,7 +27,7 @@
## Nagios source control identifiers ## Nagios source control identifiers
%global nagios_name nagios-agents-metadata %global nagios_name nagios-agents-metadata
%global nagios_hash 105ab8a7b2c16b9a29cf1c1596b80136eeef332b %global nagios_hash 105ab8a7b2c16b9a29cf1c1596b80136eeef332b
%global nagios_archive_github_url %{nagios_hash}#/%{nagios_name}-%{nagios_hash}.tar.gz
# Define globals for convenient use later # Define globals for convenient use later
@ -34,18 +35,26 @@
%global lparen ( %global lparen (
%global rparen ) %global rparen )
## Short version of git commit ## Whether this is a tagged release (final or release candidate)
%define shortcommit %(c=%{commit}; case ${c} in %define tag_release %(c=%{commit}; case ${c} in Pacemaker-*%{rparen} echo 1 ;;
Pacemaker-*%{rparen} echo ${c:10};; *%{rparen} echo 0 ;; esac)
*%{rparen} echo ${c:0:%{commit_abbrev}};; esac)
## Whether this is a tagged release ## Portion of export/dist tarball name after "pacemaker-", and release version
%define tag_release %([ %{commit} != Pacemaker-%{shortcommit} ]; echo $?) %if 0%{tag_release}
%define archive_version %{commit}
## Whether this is a release candidate (in case of a tagged release) %define archive_github_url %{commit}#/%{name}-%{archive_version}.tar.gz
%define pre_release %([ "%{tag_release}" -eq 0 ] || { %define pcmk_release %(c=%{commit}; case $c in *-rc[[:digit:]]*%{rparen}
case "%{shortcommit}" in *-rc[[:digit:]]*%{rparen} false;; echo 0.%{specversion}.${c: -3} ;;
esac; }; echo $?) *%{rparen} echo %{specversion} ;; esac)
%else
%define archive_version %(c=%{commit}; echo ${c:0:%{commit_abbrev}})
%define archive_github_url %{archive_version}#/%{name}-%{archive_version}.tar.gz
%if %{with pre_release}
%define pcmk_release 0.%{specversion}.%{archive_version}.git
%else
%define pcmk_release %{specversion}.%{archive_version}.git
%endif
%endif
## Heuristic used to infer bleeding-edge deployments that are ## Heuristic used to infer bleeding-edge deployments that are
## less likely to have working versions of the documentation tools ## less likely to have working versions of the documentation tools
@ -72,16 +81,19 @@
## Values that differ by Python major version ## Values that differ by Python major version
%global python_path /usr/bin/python%{?python3_pkgversion}%{!?python3_pkgversion:3} %global python_path /usr/bin/python%{?python3_pkgversion}%{!?python3_pkgversion:3}
%global python_pkg python3 %global python_name python3
%global python_min 3.2 %global python_min 3.2
%define py_site %{?python3_sitelib}%{!?python3_sitelib:%( %define python_site %{?python3_sitelib}%{!?python3_sitelib:%(
python3 -c 'from distutils.sysconfig import get_python_lib as gpl; print(gpl(1))' 2>/dev/null)} %{python_path} -c 'from distutils.sysconfig import get_python_lib as gpl; print(gpl(1))' 2>/dev/null)}
# Define conditionals so that "rpmbuild --with <feature>" and # Define conditionals so that "rpmbuild --with <feature>" and
# "rpmbuild --without <feature>" can enable and disable specific features # "rpmbuild --without <feature>" can enable and disable specific features
## NOTE: skip --with stonith ## NOTE: skip --with stonithd
## Add option to enable support for storing sensitive information outside CIB
%bcond_with cibsecrets
## Add option to create binaries suitable for use with profiling tools ## Add option to create binaries suitable for use with profiling tools
%bcond_with profiling %bcond_with profiling
@ -89,7 +101,7 @@
## Add option to create binaries with coverage analysis ## Add option to create binaries with coverage analysis
%bcond_with coverage %bcond_with coverage
## Add option to skip generating documentation ## Add option to skip/enable generating documentation
## (the build tools aren't available everywhere) ## (the build tools aren't available everywhere)
%bcond_without doc %bcond_without doc
@ -115,34 +127,30 @@
%endif %endif
%define pcmk_release %{specversion}
Name: pacemaker Name: pacemaker
Summary: Scalable High-Availability cluster resource manager Summary: Scalable High-Availability cluster resource manager
Version: %{pcmkversion} Version: %{pcmkversion}
Release: %{pcmk_release} Release: %{pcmk_release}
License: GPLv2+ and LGPLv2+ License: GPLv2+ and LGPLv2+
Url: http://www.clusterlabs.org Url: https://www.clusterlabs.org
# Hint: use "spectool -s 0 pacemaker.spec" (rpmdevtools) to check the final URL # Hint: use "spectool -s 0 pacemaker.spec" (rpmdevtools) to check the final URL
Source0: https://github.com/%{github_owner}/%{name}/archive/%{commit}/%{name}-%{shortcommit}.tar.gz Source0: https://codeload.github.com/%{github_owner}/%{name}/tar.gz/%{archive_github_url}
Source1: https://github.com/%{github_owner}/%{nagios_name}/archive/%{nagios_hash}/%{nagios_name}-%{nagios_hash}.tar.gz Source1: https://codeload.github.com/%{github_owner}/%{nagios_name}/tar.gz/%{nagios_archive_github_url}
# --- # ---
Patch0: Build-fix-unability-to-build-with-Inkscape-1.0-beta-.patch Patch0: fix-function-declaration-error.patch
Patch1: Resolve-the-failure-of-time-matching-in-test-cases.patch
Patch2: fix-multiple-definition-of-attributes-error.patch
Patch3: fix-multiple-definition-of-rsc_list-error.patch
Requires: resource-agents Requires: resource-agents
Requires: %{name}-libs%{?_isa} = %{version}-%{release} Requires: %{name}-libs = %{version}-%{release}
Requires: %{name}-cluster-libs%{?_isa} = %{version}-%{release} Requires: %{name}-cluster-libs = %{version}-%{release}
Requires: %{name}-cli = %{version}-%{release} Requires: %{name}-cli = %{version}-%{release}
%{?systemd_requires} %{?systemd_requires}
# Pacemaker requires a minimum Python functionality # Pacemaker requires a minimum Python functionality
Requires: %{python_pkg} >= %{python_min} Requires: %{python_name} >= %{python_min}
BuildRequires: %{python_pkg}-devel >= %{python_min} BuildRequires: make
BuildRequires: %{python_name}-devel >= %{python_min}
# Pacemaker requires a minimum libqb functionality # Pacemaker requires a minimum libqb functionality
Requires: libqb >= 0.13.0 Requires: libqb >= 0.13.0
@ -170,17 +178,17 @@ BuildRequires: corosynclib-devel >= 2.0.0
#BuildRequires: pkgconfig(libcfg) #BuildRequires: pkgconfig(libcfg)
## (note no avoiding effect when building through non-customized mock) ## (note no avoiding effect when building through non-customized mock)
#%%if !%%{bleeding} # %if !%{bleeding}
#%%if %%{with doc} # %if %{with doc}
# BuildRequires: asciidoc inkscape publican # BuildRequires: asciidoc inkscape publican
#%%endif # %endif
#%%endif # %endif
# git-style patch application # git-style patch application
BuildRequires: git # BuildRequires: git
Provides: pcmk-cluster-manager = %{version}-%{release} Provides: pcmk-cluster-manager = %{version}-%{release}
Provides: pcmk-cluster-manager%{?_isa} = %{version}-%{release} Provides: pcmk-cluster-manager = %{version}-%{release}
# Pacemaker uses the crypto/md5 module from gnulib # Pacemaker uses the crypto/md5 module from gnulib
Provides: bundled(gnulib) Provides: bundled(gnulib)
@ -197,15 +205,16 @@ when related resources fail and can be configured to periodically check
resource health. resource health.
Available rpmbuild rebuild options: Available rpmbuild rebuild options:
--with(out) : coverage doc hardening pre_release profiling --with(out) : cibsecrets coverage doc hardening pre_release profiling
%package cli %package cli
License: GPLv2+ and LGPLv2+ License: GPLv2+ and LGPLv2+
Summary: Command line tools for controlling Pacemaker clusters Summary: Command line tools for controlling Pacemaker clusters
Requires: %{name}-libs%{?_isa} = %{version}-%{release} Requires: %{name}-libs = %{version}-%{release}
%if 0%{?fedora} > 22 || 0%{?rhel} > 7
Recommends: pcmk-cluster-manager = %{version}-%{release} Recommends: pcmk-cluster-manager = %{version}-%{release}
%endif # For crm_report
Recommends: tar
Recommends: bzip2
Requires: perl-TimeDate Requires: perl-TimeDate
Requires: procps-ng Requires: procps-ng
Requires: psmisc Requires: psmisc
@ -237,7 +246,7 @@ nodes and those just running the CLI tools.
%package cluster-libs %package cluster-libs
License: GPLv2+ and LGPLv2+ License: GPLv2+ and LGPLv2+
Summary: Cluster Libraries used by Pacemaker Summary: Cluster Libraries used by Pacemaker
Requires: %{name}-libs%{?_isa} = %{version}-%{release} Requires: %{name}-libs = %{version}-%{release}
%description cluster-libs %description cluster-libs
Pacemaker is an advanced, scalable High-Availability cluster resource Pacemaker is an advanced, scalable High-Availability cluster resource
@ -249,13 +258,13 @@ libraries needed for nodes that will form part of the cluster nodes.
%package remote %package remote
License: GPLv2+ and LGPLv2+ License: GPLv2+ and LGPLv2+
Summary: Pacemaker remote daemon for non-cluster nodes Summary: Pacemaker remote daemon for non-cluster nodes
Requires: %{name}-libs%{?_isa} = %{version}-%{release} Requires: %{name}-libs = %{version}-%{release}
Requires: %{name}-cli = %{version}-%{release} Requires: %{name}-cli = %{version}-%{release}
Requires: resource-agents Requires: resource-agents
# -remote can be fully independent of systemd # -remote can be fully independent of systemd
%{?systemd_ordering}%{!?systemd_ordering:%{?systemd_requires}} %{?systemd_ordering}%{!?systemd_ordering:%{?systemd_requires}}
Provides: pcmk-cluster-manager = %{version}-%{release} Provides: pcmk-cluster-manager = %{version}-%{release}
Provides: pcmk-cluster-manager%{?_isa} = %{version}-%{release} Provides: pcmk-cluster-manager = %{version}-%{release}
%description remote %description remote
Pacemaker is an advanced, scalable High-Availability cluster resource Pacemaker is an advanced, scalable High-Availability cluster resource
@ -268,13 +277,13 @@ nodes not running the full corosync/cluster stack.
%package libs-devel %package libs-devel
License: GPLv2+ and LGPLv2+ License: GPLv2+ and LGPLv2+
Summary: Pacemaker development package Summary: Pacemaker development package
Requires: %{name}-libs%{?_isa} = %{version}-%{release} Requires: %{name}-libs = %{version}-%{release}
Requires: %{name}-cluster-libs%{?_isa} = %{version}-%{release} Requires: %{name}-cluster-libs = %{version}-%{release}
Requires: libtool-ltdl-devel libuuid-devel Requires: libtool-ltdl-devel libuuid-devel
Requires: libxml2-devel%{?_isa} libxslt-devel%{?_isa} Requires: libxml2-devel libxslt-devel
Requires: bzip2-devel%{?_isa} glib2-devel%{?_isa} Requires: bzip2-devel glib2-devel
Requires: libqb-devel%{?_isa} Requires: libqb-devel
Requires: corosynclib-devel%{?_isa} >= 2.0.0 Requires: corosynclib-devel >= 2.0.0
%description libs-devel %description libs-devel
Pacemaker is an advanced, scalable High-Availability cluster resource Pacemaker is an advanced, scalable High-Availability cluster resource
@ -286,21 +295,24 @@ for developing tools for Pacemaker.
%package cts %package cts
License: GPLv2+ and LGPLv2+ License: GPLv2+ and LGPLv2+
Summary: Test framework for cluster-related technologies like Pacemaker Summary: Test framework for cluster-related technologies like Pacemaker
Requires: %{python_pkg} >= %{python_min} Requires: %{python_name} >= %{python_min}
Requires: %{python_path}
Requires: %{name}-libs = %{version}-%{release} Requires: %{name}-libs = %{version}-%{release}
Requires: procps-ng Requires: procps-ng
Requires: psmisc Requires: psmisc
BuildArch: noarch BuildArch: noarch
Requires: %{python_pkg}-systemd Requires: %{python_name}-systemd
%description cts %description cts
Test framework for cluster-related technologies like Pacemaker Test framework for cluster-related technologies like Pacemaker
%package doc %package doc
License: CC-BY-SA License: CC-BY-SA-4.0
Summary: Documentation for Pacemaker Summary: Documentation for Pacemaker
BuildArch: noarch BuildArch: noarch
Conflicts: %{name}-libs > %{version}-%{release}
Conflicts: %{name}-libs < %{version}-%{release}
%description doc %description doc
Documentation for Pacemaker. Documentation for Pacemaker.
@ -324,11 +336,11 @@ License: GPLv3
Summary: Pacemaker Nagios Metadata Summary: Pacemaker Nagios Metadata
BuildArch: noarch BuildArch: noarch
# NOTE below are the plugins this metadata uses. # NOTE below are the plugins this metadata uses.
Requires: nagios-plugins-http # Requires: nagios-plugins-http
Requires: nagios-plugins-ldap # Requires: nagios-plugins-ldap
Requires: nagios-plugins-mysql # Requires: nagios-plugins-mysql
Requires: nagios-plugins-pgsql # Requires: nagios-plugins-pgsql
Requires: nagios-plugins-tcp # Requires: nagios-plugins-tcp
Requires: pcmk-cluster-manager Requires: pcmk-cluster-manager
%description nagios-plugins-metadata %description nagios-plugins-metadata
@ -336,19 +348,10 @@ The metadata files required for Pacemaker to execute the nagios plugin
monitor resources. monitor resources.
%prep %prep
%setup -q -a 1 -n %{name}-%{commit} %setup -q -a 1 -n %{name}-%{archive_version}
%global __scm git_am %patch0
%__scm_setup_git
%patch0 -p1
%patch1 -p1
%patch2 -p1
%patch3 -p1
%build %build
# Early versions of autotools (e.g. RHEL <= 5) do not support --docdir
export docdir=%{pcmk_docdir}
export systemdsystemunitdir=%{?_unitdir}%{!?_unitdir:no} export systemdsystemunitdir=%{?_unitdir}%{!?_unitdir:no}
%if %{with hardening} %if %{with hardening}
@ -374,8 +377,10 @@ export CPPFLAGS="-UPCMK_TIME_EMERGENCY_CGT $CPPFLAGS"
%{!?with_legacy_links: --disable-legacy-links} \ %{!?with_legacy_links: --disable-legacy-links} \
%{?with_profiling: --with-profiling} \ %{?with_profiling: --with-profiling} \
%{?with_coverage: --with-coverage} \ %{?with_coverage: --with-coverage} \
%{?with_cibsecrets: --with-cibsecrets} \
%{!?with_doc: --with-brand=} \ %{!?with_doc: --with-brand=} \
%{?gnutls_priorities: --with-gnutls-priorities="%{gnutls_priorities}"} \ %{?gnutls_priorities: --with-gnutls-priorities="%{gnutls_priorities}"} \
--disable-static \
--with-initdir=%{_initrddir} \ --with-initdir=%{_initrddir} \
--with-runstatedir=%{_rundir} \ --with-runstatedir=%{_rundir} \
--localstatedir=%{_var} \ --localstatedir=%{_var} \
@ -388,6 +393,7 @@ export CPPFLAGS="-UPCMK_TIME_EMERGENCY_CGT $CPPFLAGS"
make %{_smp_mflags} V=1 make %{_smp_mflags} V=1
%check %check
make %{_smp_mflags} check
{ cts/cts-scheduler --run load-stopped-loop \ { cts/cts-scheduler --run load-stopped-loop \
&& cts/cts-cli \ && cts/cts-cli \
&& touch .CHECKED && touch .CHECKED
@ -440,7 +446,7 @@ rm -f %{buildroot}/%{_initrddir}/pacemaker_remote
%if %{defined py_byte_compile} && %{defined python_path} %if %{defined py_byte_compile} && %{defined python_path}
%{py_byte_compile %{python_path} %{buildroot}%{_datadir}/pacemaker/tests} %{py_byte_compile %{python_path} %{buildroot}%{_datadir}/pacemaker/tests}
%if !%{defined _python_bytecompile_extra} %if !%{defined _python_bytecompile_extra}
%{py_byte_compile %{python_path} %{buildroot}%{py_site}/cts} %{py_byte_compile %{python_path} %{buildroot}%{python_site}/cts}
%endif %endif
%endif %endif
@ -500,7 +506,7 @@ fi
%post cli %post cli
%systemd_post crm_mon.service %systemd_post crm_mon.service
if [ "$1" = 2 ]; then if [ "$1" -eq 2 ]; then
# Package upgrade, not initial install: # Package upgrade, not initial install:
# Move any pre-2.0 logs to new location to ensure they get rotated # Move any pre-2.0 logs to new location to ensure they get rotated
{ mv -fbS.rpmsave %{_var}/log/pacemaker.log* %{_var}/log/pacemaker \ { mv -fbS.rpmsave %{_var}/log/pacemaker.log* %{_var}/log/pacemaker \
@ -518,8 +524,8 @@ fi
# XXX keep an eye on https://fedoraproject.org/wiki/Changes/SystemdSysusers # XXX keep an eye on https://fedoraproject.org/wiki/Changes/SystemdSysusers
# reopened recently: # reopened recently:
# https://lists.fedoraproject.org/archives/list/devel@lists.fedoraproject.org/message/AETGESYR4IEQJMA6SKL7OERSDZFWFNEU/ # https://lists.fedoraproject.org/archives/list/devel@lists.fedoraproject.org/message/AETGESYR4IEQJMA6SKL7OERSDZFWFNEU/
getent group %{gname} >/dev/null || groupadd -r %{gname} -g 189 getent group %{gname} >/dev/null || groupadd -r %{gname} -g %{hacluster_id}
getent passwd %{uname} >/dev/null || useradd -r -g %{gname} -u 189 -s /sbin/nologin -c "cluster user" %{uname} getent passwd %{uname} >/dev/null || useradd -r -g %{gname} -u %{hacluster_id} -s /sbin/nologin -c "cluster user" %{uname}
exit 0 exit 0
%ldconfig_scriptlets libs %ldconfig_scriptlets libs
@ -574,6 +580,9 @@ exit 0
%{_sbindir}/attrd_updater %{_sbindir}/attrd_updater
%{_sbindir}/cibadmin %{_sbindir}/cibadmin
%if %{with cibsecrets}
%{_sbindir}/cibsecret
%endif
%{_sbindir}/crm_diff %{_sbindir}/crm_diff
%{_sbindir}/crm_error %{_sbindir}/crm_error
%{_sbindir}/crm_failcount %{_sbindir}/crm_failcount
@ -669,7 +678,7 @@ exit 0
%license licenses/CC-BY-SA-4.0 %license licenses/CC-BY-SA-4.0
%files cts %files cts
%{py_site}/cts %{python_site}/cts
%{_datadir}/pacemaker/tests %{_datadir}/pacemaker/tests
%{_libexecdir}/pacemaker/cts-log-watcher %{_libexecdir}/pacemaker/cts-log-watcher
@ -705,6 +714,9 @@ exit 0
%license %{nagios_name}-%{nagios_hash}/COPYING %license %{nagios_name}-%{nagios_hash}/COPYING
%changelog %changelog
* Wed Feb 16 2022 jiangxinyu <jiangxinyu@kylinos.cn> - 2.0.5-1
- upgrade to 2.0.5
* Sat Aug 07 2021 wangyue <wangyue92@huawei.com> - 2.0.3-3 * Sat Aug 07 2021 wangyue <wangyue92@huawei.com> - 2.0.3-3
- fix build error with gcc 10 - fix build error with gcc 10