Set RUSTFLAGS in mingw env

This commit is contained in:
Sandro Mani 2023-04-06 09:19:51 +02:00
parent a34e458d5e
commit b8c708695e
3 changed files with 9 additions and 2 deletions

View File

@ -27,6 +27,7 @@
%mingw32_cppflags %{nil} %mingw32_cppflags %{nil}
%mingw32_fflags -O2 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions --param=ssp-buffer-size=4 %mingw32_fflags -O2 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions --param=ssp-buffer-size=4
%mingw32_ldflags -fstack-protector -lssp %mingw32_ldflags -fstack-protector -lssp
%mingw32_rustflags -Copt-level=3 -Cdebuginfo=2 -Ccodegen-units=1 -Cforce-frame-pointers=yes --cap-lints=warn
%mingw32_cc %{mingw32_target}-gcc %mingw32_cc %{mingw32_target}-gcc
%mingw32_cxx %{mingw32_target}-g++ %mingw32_cxx %{mingw32_target}-g++
@ -77,6 +78,7 @@
FFLAGS="${MINGW32_FFLAGS-%mingw32_fflags}"; export FFLAGS; \ FFLAGS="${MINGW32_FFLAGS-%mingw32_fflags}"; export FFLAGS; \
FCFLAGS="${MINGW32_FCFLAGS-%mingw32_fflags}"; export FCFLAGS; \ FCFLAGS="${MINGW32_FCFLAGS-%mingw32_fflags}"; export FCFLAGS; \
LDFLAGS="${MINGW32_LDFLAGS:-%mingw32_ldflags}"; export LDFLAGS; \ LDFLAGS="${MINGW32_LDFLAGS:-%mingw32_ldflags}"; export LDFLAGS; \
RUSTFLAGS="${MINGW32_RUSTFLAGS:-%mingw32_rustflags}"; export RUSTFLAGS; \
for i in `ls %{mingw32_bindir}/*|grep -- "-config\$"` ; do \ for i in `ls %{mingw32_bindir}/*|grep -- "-config\$"` ; do \
x=`basename $i|tr "a-z+-." "A-ZX_"`; \ x=`basename $i|tr "a-z+-." "A-ZX_"`; \
declare -x $x="$i" ; export $x; \ declare -x $x="$i" ; export $x; \

View File

@ -27,6 +27,7 @@
%mingw64_cppflags %{nil} %mingw64_cppflags %{nil}
%mingw64_fflags -O2 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions --param=ssp-buffer-size=4 %mingw64_fflags -O2 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions --param=ssp-buffer-size=4
%mingw64_ldflags -fstack-protector -lssp %mingw64_ldflags -fstack-protector -lssp
%mingw64_rustflags -Copt-level=3 -Cdebuginfo=2 -Ccodegen-units=1 -Cforce-frame-pointers=yes --cap-lints=warn
%mingw64_cc %{mingw64_target}-gcc %mingw64_cc %{mingw64_target}-gcc
%mingw64_cxx %{mingw64_target}-g++ %mingw64_cxx %{mingw64_target}-g++
@ -77,6 +78,7 @@
FFLAGS="${MINGW64_FFLAGS-%mingw64_fflags}"; export FFLAGS; \ FFLAGS="${MINGW64_FFLAGS-%mingw64_fflags}"; export FFLAGS; \
FCFLAGS="${MINGW64_FCFLAGS-%mingw64_fflags}"; export FCFLAGS; \ FCFLAGS="${MINGW64_FCFLAGS-%mingw64_fflags}"; export FCFLAGS; \
LDFLAGS="${MINGW64_LDFLAGS:-%mingw64_ldflags}"; export LDFLAGS; \ LDFLAGS="${MINGW64_LDFLAGS:-%mingw64_ldflags}"; export LDFLAGS; \
RUSTFLAGS="${MINGW64_RUSTFLAGS:-%mingw64_rustflags}"; export RUSTFLAGS; \
for i in `ls %{mingw64_bindir}/*|grep -- "-config\$"` ; do \ for i in `ls %{mingw64_bindir}/*|grep -- "-config\$"` ; do \
x=`basename $i|tr "a-z+-." "A-ZX_"`; \ x=`basename $i|tr "a-z+-." "A-ZX_"`; \
declare -x $x="$i" ; export $x; \ declare -x $x="$i" ; export $x; \

View File

@ -9,8 +9,8 @@
%global macrosdir %(d=%{_rpmconfigdir}/macros.d; [ -d $d ] || d=%{_sysconfdir}/rpm; echo $d) %global macrosdir %(d=%{_rpmconfigdir}/macros.d; [ -d $d ] || d=%{_sysconfdir}/rpm; echo $d)
Name: mingw-filesystem Name: mingw-filesystem
Version: 145 Version: 146
Release: 2%{?dist} Release: 1%{?dist}
Summary: MinGW cross compiler base filesystem and environment Summary: MinGW cross compiler base filesystem and environment
License: GPL-2.0-or-later License: GPL-2.0-or-later
@ -376,6 +376,9 @@ echo ".so man1/pkgconf.1" > %{buildroot}%{_mandir}/man1/x86_64-w64-mingw32ucrt-p
%dir %{_prefix}/lib/debug/%{_prefix}/x86_64-w64-mingw32ucrt %dir %{_prefix}/lib/debug/%{_prefix}/x86_64-w64-mingw32ucrt
%changelog %changelog
* Wed Apr 05 2023 Sandro Mani <manisandro@gmail.com> - 146-1
- Set RUSTFLAGS in mingw env
* Thu Jan 19 2023 Fedora Release Engineering <releng@fedoraproject.org> - 145-2 * Thu Jan 19 2023 Fedora Release Engineering <releng@fedoraproject.org> - 145-2
- Rebuilt for https://fedoraproject.org/wiki/Fedora_38_Mass_Rebuild - Rebuilt for https://fedoraproject.org/wiki/Fedora_38_Mass_Rebuild