File pldebugger.spec of Package pldebugger

#
# Copyright (c) 2021 SUSE LLC
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
# upon. The license for this file, and modifications and additions to the
# file, is the same license as for the pristine package itself (unless the
# license for the pristine package is not an Open Source License, in which
# case the license is the MIT License). An "Open Source License" is a
# license that conforms to the Open Source Definition (Version 1.9)
# published by the Open Source Initiative.

# Please submit bugfixes or comments via https://bugs.opensuse.org/
#


# Those variables are important as they are used by pg_* macros below
%define pg_name  @BUILD_FLAVOR@%{nil}
%define ext_name pldebugger
%{pg_version_from_name}

Summary:        PL/pgSQL debugger for PostgreSQL
Name:           %{pg_name}-%{ext_name}
Version:        1.9
Release:        0
License:        Artistic-1.0
Group:          Productivity/Databases/Servers
URL:            https://github.com/EnterpriseDB/pldebugger
Source0:        https://github.com/EnterpriseDB/pldebugger/archive/refs/tags/v%{version}.tar.gz#/%{ext_name}-%{version}.tar.gz

BuildRequires:  %{pg_name}-llvmjit-devel
%pg_server_requires
%if "%{pg_name}" == ""
ExclusiveArch:  do_not_build
%endif

%description
The PL/pgSQL debugger lets you step through PL/pgSQL code, set and clear breakpoints,
view and modify variables, and walk through the call stack.

%prep
%autosetup -p1 -n %{ext_name}-%{version}

%build
%make_pgxs

%install
%make_pgxs_install
rm -rv %{buildroot}%{pg_config_docdir}

%files
%doc README-pldebugger.md
%{pg_config_pkglibdir}/plugin_debugger.so
%{pg_config_sharedir}/extension/pldbgapi*
%if %{postgresql_has_llvm}
%{pg_config_pkglibdir}/bitcode/*
%endif

%changelog
openSUSE Build Service is sponsored by