Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fixes #16904: Aix package does not build anymore #2219

Merged
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
20 changes: 10 additions & 10 deletions rudder-agent/SPECS/rudder-agent.spec
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,7 @@
%endif

# OS family to build for
%if 0%{?aix}
%if "%{?aix}"
%define os_family aix
%else
%define os_family linux
Expand All @@ -86,7 +86,7 @@
%define use_system_fusion false

# 1- AIX
%if 0%{?aix}
%if "%{?aix}"
# no system anything on aix
%define use_system_perl false
%define use_system_pcre false
Expand Down Expand Up @@ -172,7 +172,7 @@ Requires: fusioninventory-agent fusioninventory-agent-task-inventory
%endif

## For Linux
%if 0%{?aix}
%if "%{?aix}"
BuildRequires: pam-devel
Requires: syslog
%endif
Expand Down Expand Up @@ -240,7 +240,7 @@ Requires: kernel-utils
%if 0%{?suse_version} && 0%{?suse_version} < 1200
%define use_https false
%endif
%if 0%{?aix}
%if "%{?aix}"
%define use_https false
%define build_old_openssl true
%endif
Expand All @@ -255,7 +255,7 @@ Requires: dmidecode
%endif

## ACL dependencies
%if 0%{?aix}
%if "%{?aix}"
BuildRequires: libacl-devel
Requires: libacl
%endif
Expand Down Expand Up @@ -329,7 +329,7 @@ make -d BUILD_CFLAGS="${RPM_OPT_FLAGS}" USE_SYSTEM_OPENSSL=%{use_system_openssl}
cd %{_sourcedir}

#### Use systemd everywhere except on: AIX, RHEL<7, SLES<12, Fedora<15
%if 0%{?aix}
%if "%{?aix}"
%define use_systemd false
%endif

Expand Down Expand Up @@ -430,7 +430,7 @@ fi
# Post Uninstallation
#=================================================

%if 0%{?aix}
%if "%{?aix}"
# AIX doesn't have a pidof command, let's define it
function pidof {
# Yeah, "grep -v grep" is ugly, but we can't use the [u]nique trick on a variable
Expand All @@ -457,7 +457,7 @@ if [ $1 -eq 0 ]; then
fi
done

%if 0%{?aix}
%if "%{?aix}"
# Remove the cron script we create at installation to prevent mail
# flooding, re-installation surprises, and general system garbage.
rm -f /etc/cron.d/rudder-agent
Expand Down Expand Up @@ -503,11 +503,11 @@ rm -f %{_builddir}/file.list.%{name}
%dir %{rudderlogdir}/install
%dir %{rudderlogdir}/agent-check

%if 0%{?aix}
%if "%{?aix}"
# no init no cron and no profile with aix
%config /etc/cron.d/rudder-agent
%config /etc/profile.d/rudder-agent.sh
%if "${use_systemd}" == "false"
%if "%{use_systemd}" == "false"
%config(noreplace) /etc/default/rudder-agent
%endif
%endif
Expand Down