File haproxy-awslc.spec of Package haproxy-awslc

#
# spec file for package haproxy-awslc
#
# Copyright (c) 2026 Max Bäckström
#
# 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 bugs caused by packaging or build errors to home:nMax/haproxy-awslc
#
# Please submit other bugs to upstream (haproxy)


Name:		haproxy
Version:        3.3.3
Release:        0
Summary:        The Reliable, High Performance TCP/HTTP Load Balancer
License:        GPL-3.0-or-later AND LGPL-2.1-or-later
Group:          Productivity/Networking/Web/Proxy
URL:            https://www.haproxy.org/
Source:         haproxy-%{version}.tar.gz

Source99:	README.md


BuildRequires:  libgcrypt-devel
BuildRequires:  pcre2-devel
BuildRequires:  pkgconfig
BuildRequires:  vim
BuildRequires:  zlib-devel

%if %{with apparmor}
BuildRequires:  apparmor-abstractions
Recommends:     apparmor-abstractions
BuildRequires:  apparmor-rpm-macros
%endif

BuildRequires:  lua-devel >= 5.3

# Ska ändras till aws-lc-devel fast fips?
BuildRequires:  openssl-devel

BuildRequires:  pkgconfig(libsystemd)
BuildRequires:  pkgconfig(systemd)
BuildRequires:  sysuser-shadow
BuildRequires:  sysuser-tools

# BuildRoot: ???

%description
An unofficial openSUSE version of HAproxy Performance Packages by HAProxy Technologies.
This package is built with aws-lc fips certified version, enabling better performance 
than openssl and provides full quic support.

HAproxy is an high performance loadbalancer and proxy.

%prep
# %autosetup -p1
%setup -q -n %{name}-%{version}

# Disclaimer readme
cp %{SOURCE99} .


%build
# USE_OPENSSL_AWSLC=1 \
%make_build \
	TARGET=linux-glibc \
	CFLAGS="-march=native -Werror=implicit-function-declaration -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -fcf-protection -Wdate-time -D_FORTIFY_SOURCE=2" \
	USE_OPENSSL=1 \
	USE_LUA=1 \
	USE_QUIC=1 \
	USE_TFO=1 \
	USE_GETADDRINFO=1 \
	USE_PCRE2=1 \
	USE_PCRE2_JIT=1 \
	USE_PROMEX=1 \
	USE_SLZ=1 \
	USE_NS=1 \
	USE_KTLS=1 \
	USE_LINUX_CAP=1

%install
# make install

%files

%changelog
openSUSE Build Service is sponsored by