Fix compile error on Fedora 40

Signed-off-by: David Abdurachmanov <davidlt@rivosinc.com>
This commit is contained in:
David Abdurachmanov 2023-12-08 11:15:20 +02:00
parent e58ce1ba4c
commit e121a4aa8d
Signed by: davidlt
GPG Key ID: 8B7F1DA0E2C9FDBB
1 changed files with 8 additions and 1 deletions

View File

@ -34,7 +34,7 @@
Name: mp
Version: 3.1.0
Release: 42.%{date}git%{shortcommit}%{?dist}
Release: 42.%{date}git%{shortcommit}.0.riscv64%{?dist}
License: MIT and BSD
Summary: An open-source library for mathematical programming
URL: https://github.com/ampl/mp
@ -184,6 +184,10 @@ sed -i 's,returncode == 0,False,' support/build-docs.py
%endif
%build
# Fedora 40 compile issues
CFLAGS="-D_GNU_SOURCE $CFLAGS"
CXXFLAGS="-D_GNU_SOURCE $CXXFLAGS"
export LIBS="-lgsl -l%{blaslib}"
mkdir -p build && pushd build
BUILD="asl,gsl,smpswriter"
@ -314,6 +318,9 @@ popd
%doc build/doc/ampl.github.io/*
%changelog
* Fri Dec 08 2023 David Abdurachmanov <davidlt@rivosinc.com> - 3.1.0-42.20200303git7fd4828.0.riscv64
- Fix compile error on Fedora 40
* Thu Jul 20 2023 Fedora Release Engineering <releng@fedoraproject.org> - 3.1.0-42.20200303git7fd4828
- Rebuilt for https://fedoraproject.org/wiki/Fedora_39_Mass_Rebuild