Compare commits

...

No commits in common. "c8" and "imports/c9/mingw-filesystem-119-2.el9" have entirely different histories.

9 changed files with 250 additions and 109 deletions

View File

@ -62,10 +62,10 @@ run_mingw_configure
run_mingw_make() \ run_mingw_make() \
{ \ { \
%if 0%{?mingw_build_win32} == 1 \ %if 0%{?mingw_build_win32} == 1 \
make -C build_win32$MINGW_BUILDDIR_SUFFIX "$@" $MINGW32_MAKE_ARGS \ %{__make} -C build_win32$MINGW_BUILDDIR_SUFFIX "$@" $MINGW32_MAKE_ARGS \
%endif \ %endif \
%if 0%{?mingw_build_win64} == 1 \ %if 0%{?mingw_build_win64} == 1 \
make -C build_win64$MINGW_BUILDDIR_SUFFIX "$@" $MINGW64_MAKE_ARGS \ %{__make} -C build_win64$MINGW_BUILDDIR_SUFFIX "$@" $MINGW64_MAKE_ARGS \
%endif \ %endif \
} \ } \
run_mingw_make run_mingw_make
@ -172,5 +172,18 @@ ninja -C build_win64$MINGW_BUILDDIR_SUFFIX "$@" $MINGW64_NINJA_ARGS \
} \ } \
run_mingw_ninja run_mingw_ninja
# Deprecated: %mingw_ninja_install \
%mingw_make_install %mingw_make install run_mingw_ninja_install() \
{ \
%if 0%{?mingw_build_win32} == 1 \
DESTDIR=%{buildroot} ninja -C build_win32$MINGW_BUILDDIR_SUFFIX install \
%endif \
%if 0%{?mingw_build_win64} == 1 \
DESTDIR=%{buildroot} ninja -C build_win64$MINGW_BUILDDIR_SUFFIX install \
%endif \
} \
run_mingw_ninja_install
%mingw_make_build %mingw_make %{_make_output_sync} %{?_smp_mflags} %{_make_verbose}
%mingw_make_install %mingw_make install DESTDIR=%{?buildroot} INSTALL="%{__install} -p"

View File

@ -25,7 +25,7 @@
%mingw32_cflags %{mingw32_cppflags} -O2 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions --param=ssp-buffer-size=4 %mingw32_cflags %{mingw32_cppflags} -O2 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions --param=ssp-buffer-size=4
%mingw32_cppflags %{nil} %mingw32_cppflags %{nil}
%mingw32_ldflags %{nil} %mingw32_ldflags -fstack-protector -lssp
%mingw32_cc %{mingw32_target}-gcc %mingw32_cc %{mingw32_target}-gcc
%mingw32_cxx %{mingw32_target}-g++ %mingw32_cxx %{mingw32_target}-g++
@ -81,6 +81,7 @@
unset x i unset x i
%mingw32_pkg_config %{mingw32_target}-pkg-config %mingw32_pkg_config %{mingw32_target}-pkg-config
%mingw32_pkgconfig_personalitydir %{mingw32_datadir}/pkgconfig/personality.d
%mingw32_configure %{mingw32_env} ; \ %mingw32_configure %{mingw32_env} ; \
__mingw32_topdir=.; if ! test -x configure; then __mingw32_topdir=..; fi; \\\ __mingw32_topdir=.; if ! test -x configure; then __mingw32_topdir=..; fi; \\\
@ -152,7 +153,9 @@
%mingw32_meson %{mingw32_env} ; \ %mingw32_meson %{mingw32_env} ; \
unset CC CFLAGS CPPFLAGS CXX CXXFLAGS LD LDFLAGS; \\\ unset CC CFLAGS CPPFLAGS CXX CXXFLAGS LD LDFLAGS; \\\
export CFLAGS="%{mingw32_cflags}" CXXFLAGS="%{mingw32_cflags}" LDFLAGS="%{mingw32_ldflags}"; \\\ CFLAGS="${MINGW32_CFLAGS-%mingw32_cflags}"; export CFLAGS; \\\
CPPFLAGS="${MINGW32_CPPFLAGS-%mingw32_cppflags}"; export CPPFLAGS; \\\
LDFLAGS="${MINGW32_LDFLAGS:-%mingw32_ldflags}"; export LDFLAGS; \\\
if test -f meson.build; then __mingw32_topdir=.; \\\ if test -f meson.build; then __mingw32_topdir=.; \\\
elif test -f ../meson.build; then __mingw32_topdir=..; \\\ elif test -f ../meson.build; then __mingw32_topdir=..; \\\
else __mingw32_topdir=""; fi; \\\ else __mingw32_topdir=""; fi; \\\

View File

@ -25,7 +25,7 @@
%mingw64_cflags %{mingw64_cppflags} -O2 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions --param=ssp-buffer-size=4 %mingw64_cflags %{mingw64_cppflags} -O2 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions --param=ssp-buffer-size=4
%mingw64_cppflags %{nil} %mingw64_cppflags %{nil}
%mingw64_ldflags %{nil} %mingw64_ldflags -fstack-protector -lssp
%mingw64_cc %{mingw64_target}-gcc %mingw64_cc %{mingw64_target}-gcc
%mingw64_cxx %{mingw64_target}-g++ %mingw64_cxx %{mingw64_target}-g++
@ -81,6 +81,7 @@
unset x i unset x i
%mingw64_pkg_config %{mingw64_target}-pkg-config %mingw64_pkg_config %{mingw64_target}-pkg-config
%mingw64_pkgconfig_personalitydir %{mingw32_datadir}/pkgconfig/personality.d
%mingw64_configure %{mingw64_env} ; \ %mingw64_configure %{mingw64_env} ; \
__mingw64_topdir=.; if ! test -x configure; then __mingw64_topdir=..; fi; \\\ __mingw64_topdir=.; if ! test -x configure; then __mingw64_topdir=..; fi; \\\
@ -152,7 +153,9 @@
%mingw64_meson %{mingw64_env} ; \ %mingw64_meson %{mingw64_env} ; \
unset CC CFLAGS CPPFLAGS CXX CXXFLAGS LD LDFLAGS; \\\ unset CC CFLAGS CPPFLAGS CXX CXXFLAGS LD LDFLAGS; \\\
export CFLAGS="%{mingw64_cflags}" CXXFLAGS="%{mingw64_cflags}" LDFLAGS="%{mingw64_ldflags}"; \\\ CFLAGS="${MINGW64_CFLAGS-%mingw64_cflags}"; export CFLAGS; \\\
CPPFLAGS="${MINGW64_CPPFLAGS-%mingw64_cppflags}"; export CPPFLAGS; \\\
LDFLAGS="${MINGW64_LDFLAGS:-%mingw64_ldflags}"; export LDFLAGS; \\\
if test -f meson.build; then __mingw64_topdir=.; \\\ if test -f meson.build; then __mingw64_topdir=.; \\\
elif test -f ../meson.build; then __mingw64_topdir=..; \\\ elif test -f ../meson.build; then __mingw64_topdir=..; \\\
else __mingw64_topdir=""; fi; \\\ else __mingw64_topdir=""; fi; \\\

View File

@ -1,4 +1,4 @@
#!/bin/sh #!/usr/bin/sh
# mingw-find-debuginfo.sh - automagically generate debug info and file list # mingw-find-debuginfo.sh - automagically generate debug info and file list
# for inclusion in an rpm spec file for mingw-* packages. # for inclusion in an rpm spec file for mingw-* packages.
@ -33,7 +33,7 @@ do
done done
for target in $@; do for target in $@; do
prefix=`rpm --eval "%{${target}_prefix}"` prefix=`rpm --eval "%{_prefix}/%{${target}_target}"`
if [ ! -d $RPM_BUILD_ROOT$prefix ] ; then if [ ! -d $RPM_BUILD_ROOT$prefix ] ; then
continue continue
fi fi

View File

@ -11,10 +11,10 @@ fi
filelist=`sed "s/['\"]/\\\&/g"` filelist=`sed "s/['\"]/\\\&/g"`
dlls=$(echo $filelist | tr [:blank:] '\n' | grep '\.dll$') dlls=$(echo $filelist | tr '[:blank:]' '\n' | grep '\.dll$')
for f in $dlls; do for f in $dlls; do
basename=`basename $f | tr [:upper:] [:lower:]` basename=`basename $f | tr '[:upper:]' '[:lower:]'`
for target in $targets; do for target in $targets; do
host_triplet=`rpm --eval "%{${target}_target}"` host_triplet=`rpm --eval "%{${target}_target}"`
[[ $f =~ .*$host_triplet.* ]] && echo "$target($basename)" [[ $f =~ .*$host_triplet.* ]] && echo "$target($basename)"

View File

@ -15,8 +15,8 @@ fi
filelist=`sed "s/['\"]/\\\&/g"` filelist=`sed "s/['\"]/\\\&/g"`
dlls=$(echo $filelist | tr [:blank:] '\n' | grep -Ei '\.(dll|exe)$') dlls=$(echo $filelist | tr '[:blank:]' '\n' | grep -Ei '\.(dll|exe)$')
pkgconfig_files=$(echo $filelist | tr [:blank:] '\n' | grep -Ei '\.(pc)$') pkgconfig_files=$(echo $filelist | tr '[:blank:]' '\n' | grep -Ei '\.(pc)$')
for target in $targets; do for target in $targets; do
dll_found=false dll_found=false
@ -24,7 +24,7 @@ for target in $targets; do
for f in $dlls; do for f in $dlls; do
if [[ $f =~ .*$host_triplet.* ]]; then if [[ $f =~ .*$host_triplet.* ]]; then
$OBJDUMP -p $f | grep 'DLL Name' | grep -Eio '[-._\+[:alnum:]]+\.dll' | $OBJDUMP -p $f | grep 'DLL Name' | grep -Eio '[-._\+[:alnum:]]+\.dll' |
tr [:upper:] [:lower:] | grep -v 'api-ms-win' | tr '[:upper:]' '[:lower:]' |
sed "s/\(.*\)/$target(\1)/" sed "s/\(.*\)/$target(\1)/"
dll_found=true dll_found=true
fi fi

View File

@ -0,0 +1,6 @@
# MinGW 32-bit x86 Windows target
Triplet: i686-w64-mingw32
SysrootDir: /usr/i686-w64-mingw32/sys-root/mingw
DefaultSearchPaths: /usr/i686-w64-mingw32/sys-root/mingw/lib/pkgconfig:/usr/i686-w64-mingw32/sys-root/mingw/share/pkgconfig
SystemIncludePaths: /usr/i686-w64-mingw32/sys-root/mingw/include
SystemLibraryPaths: /usr/i686-w64-mingw32/sys-root/mingw/lib

View File

@ -0,0 +1,6 @@
# MinGW 64-bit x86 Windows target
Triplet: x86_64-w64-mingw32
SysrootDir: /usr/x86_64-w64-mingw32/sys-root/mingw
DefaultSearchPaths: /usr/x86_64-w64-mingw32/sys-root/mingw/lib/pkgconfig:/usr/x86_64-w64-mingw32/sys-root/mingw/share/pkgconfig
SystemIncludePaths: /usr/x86_64-w64-mingw32/sys-root/mingw/include
SystemLibraryPaths: /usr/x86_64-w64-mingw32/sys-root/mingw/lib

View File

@ -6,11 +6,10 @@
%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: 104 Version: 119
Release: 3%{?dist} Release: 2%{?dist}
Summary: MinGW cross compiler base filesystem and environment Summary: MinGW cross compiler base filesystem and environment
Group: Development/Libraries
License: GPLv2+ License: GPLv2+
URL: http://fedoraproject.org/wiki/MinGW URL: http://fedoraproject.org/wiki/MinGW
BuildArch: noarch BuildArch: noarch
@ -38,37 +37,56 @@ Source16: standard-dlls-mingw32
Source17: standard-dlls-mingw64 Source17: standard-dlls-mingw64
Source18: toolchain-mingw32.meson Source18: toolchain-mingw32.meson
Source19: toolchain-mingw64.meson Source19: toolchain-mingw64.meson
Source20: pkgconf-personality-mingw32
Source21: pkgconf-personality-mingw64
# Taken from the Fedora filesystem package # Taken from the Fedora filesystem package
Source101: https://fedorahosted.org/filesystem/browser/lang-exceptions Source101: https://fedorahosted.org/filesystem/browser/lang-exceptions
Source102: iso_639.sed Source102: iso_639.sed
Source103: iso_3166.sed Source103: iso_3166.sed
BuildRequires: make
BuildRequires: iso-codes BuildRequires: iso-codes
BuildRequires: pkgconf
%description %description
This package contains the base filesystem layout, RPM macros and This package contains the base filesystem layout, RPM macros and
environment for all MinGW packages. environment for all Fedora MinGW packages.
This environment is maintained by the Fedora MinGW SIG at:
http://fedoraproject.org/wiki/SIGs/MinGW
%package base %package base
Summary: Generic files which are needed for both mingw32-filesystem and mingw64-filesystem Summary: Generic files which are needed for both mingw32-filesystem and mingw64-filesystem
Requires: redhat-rpm-config
# Obsolete the packages from the test repo # Obsolete the packages from the test repo
Obsoletes: cross-filesystem < 67-2 Obsoletes: cross-filesystem < 67-2
Obsoletes: cross-filesystem-scripts < 67-2 Obsoletes: cross-filesystem-scripts < 67-2
Obsoletes: mingw-filesystem < 75-2 Obsoletes: mingw-filesystem < 75-2
Obsoletes: mingw-filesystem-scripts < 75-2 Obsoletes: mingw-filesystem-scripts < 75-2
# For using pkgconf with MinGW
Requires: pkgconf
%description base %description base
This package contains the base filesystem layout, RPM macros and This package contains the base filesystem layout, RPM macros and
environment for all MinGW packages. environment for all Fedora MinGW packages.
This environment is maintained by the Fedora MinGW SIG at:
http://fedoraproject.org/wiki/SIGs/MinGW
%package -n mingw32-filesystem %package -n mingw32-filesystem
Summary: MinGW cross compiler base filesystem and environment for the win32 target Summary: MinGW cross compiler base filesystem and environment for the win32 target
Requires: %{name}-base = %{version}-%{release} Requires: %{name}-base = %{version}-%{release}
# Replace mingw32-pkg-config
Conflicts: mingw32-pkg-config < 0.28-17
Obsoletes: mingw32-pkg-config < 0.28-17
Provides: mingw32-pkg-config = 0.28-17
# Note about 'Provides: mingw32(foo.dll)' # Note about 'Provides: mingw32(foo.dll)'
# ------------------------------------------------------------ # ------------------------------------------------------------
@ -89,19 +107,31 @@ Provides: mingw32(mscoree.dll)
%description -n mingw32-filesystem %description -n mingw32-filesystem
This package contains the base filesystem layout, RPM macros and This package contains the base filesystem layout, RPM macros and
environment for all MinGW packages. environment for all Fedora MinGW packages.
This environment is maintained by the Fedora MinGW SIG at:
http://fedoraproject.org/wiki/SIGs/MinGW
%package -n mingw64-filesystem %package -n mingw64-filesystem
Summary: MinGW cross compiler base filesystem and environment for the win64 target Summary: MinGW cross compiler base filesystem and environment for the win64 target
Requires: %{name}-base = %{version}-%{release} Requires: %{name}-base = %{version}-%{release}
# Replace mingw64-pkg-config
Conflicts: mingw64-pkg-config < 0.28-17
Obsoletes: mingw64-pkg-config < 0.28-17
Provides: mingw64-pkg-config = 0.28-17
Provides: %(sed "s/\(.*\)/mingw64(\1) /g" %{SOURCE17} | tr "\n" " ") Provides: %(sed "s/\(.*\)/mingw64(\1) /g" %{SOURCE17} | tr "\n" " ")
Provides: mingw64(mscoree.dll) Provides: mingw64(mscoree.dll)
%description -n mingw64-filesystem %description -n mingw64-filesystem
This package contains the base filesystem layout, RPM macros and This package contains the base filesystem layout, RPM macros and
environment for all MinGW packages. environment for all Fedora MinGW packages.
This environment is maintained by the Fedora MinGW SIG at:
http://fedoraproject.org/wiki/SIGs/MinGW
%prep %prep
@ -114,60 +144,64 @@ cp %{SOURCE0} COPYING
%install %install
mkdir -p $RPM_BUILD_ROOT mkdir -p %{buildroot}
mkdir -p $RPM_BUILD_ROOT%{_libexecdir} mkdir -p %{buildroot}%{_libexecdir}
install -m 755 %{SOURCE9} $RPM_BUILD_ROOT%{_libexecdir}/mingw-scripts install -m 755 %{SOURCE9} %{buildroot}%{_libexecdir}/mingw-scripts
mkdir -p $RPM_BUILD_ROOT%{_bindir} mkdir -p %{buildroot}%{_bindir}
pushd $RPM_BUILD_ROOT%{_bindir} pushd %{buildroot}%{_bindir}
for i in mingw32-configure mingw32-cmake mingw32-make mingw32-meson mingw32-pkg-config \ for i in mingw32-configure mingw32-cmake mingw32-make mingw32-meson mingw32-pkg-config \
mingw64-configure mingw64-cmake mingw64-make mingw64-meson mingw64-pkg-config ; do mingw64-configure mingw64-cmake mingw64-make mingw64-meson mingw64-pkg-config ; do
ln -s %{_libexecdir}/mingw-scripts $i ln -s %{_libexecdir}/mingw-scripts $i
done done
for i in i686-w64-mingw32-pkg-config \
x86_64-w64-mingw32-pkg-config ; do
ln -s %{_bindir}/pkgconf $i
done
popd popd
mkdir -p $RPM_BUILD_ROOT%{_sysconfdir}/profile.d mkdir -p %{buildroot}%{_sysconfdir}/profile.d
install -m 644 %{SOURCE4} $RPM_BUILD_ROOT%{_sysconfdir}/profile.d/ install -m 644 %{SOURCE4} %{buildroot}%{_sysconfdir}/profile.d/
install -m 644 %{SOURCE5} $RPM_BUILD_ROOT%{_sysconfdir}/profile.d/ install -m 644 %{SOURCE5} %{buildroot}%{_sysconfdir}/profile.d/
mkdir -p $RPM_BUILD_ROOT%{macrosdir} mkdir -p %{buildroot}%{macrosdir}
install -m 644 %{SOURCE1} $RPM_BUILD_ROOT%{macrosdir}/macros.mingw install -m 644 %{SOURCE1} %{buildroot}%{macrosdir}/macros.mingw
install -m 644 %{SOURCE2} $RPM_BUILD_ROOT%{macrosdir}/macros.mingw32 install -m 644 %{SOURCE2} %{buildroot}%{macrosdir}/macros.mingw32
install -m 644 %{SOURCE3} $RPM_BUILD_ROOT%{macrosdir}/macros.mingw64 install -m 644 %{SOURCE3} %{buildroot}%{macrosdir}/macros.mingw64
mkdir -p $RPM_BUILD_ROOT%{_sysconfdir}/rpmlint mkdir -p %{buildroot}%{_sysconfdir}/rpmlint
install -m 644 %{SOURCE10} $RPM_BUILD_ROOT%{_sysconfdir}/rpmlint/ install -m 644 %{SOURCE10} %{buildroot}%{_sysconfdir}/rpmlint/
# Create the folders required for gcc and binutils # Create the folders required for gcc and binutils
mkdir -p $RPM_BUILD_ROOT%{_prefix}/i686-w64-mingw32 mkdir -p %{buildroot}%{_prefix}/i686-w64-mingw32
mkdir -p $RPM_BUILD_ROOT%{_prefix}/i686-w64-mingw32/bin mkdir -p %{buildroot}%{_prefix}/i686-w64-mingw32/bin
mkdir -p $RPM_BUILD_ROOT%{_prefix}/i686-w64-mingw32/lib mkdir -p %{buildroot}%{_prefix}/i686-w64-mingw32/lib
mkdir -p $RPM_BUILD_ROOT%{_prefix}/x86_64-w64-mingw32 mkdir -p %{buildroot}%{_prefix}/x86_64-w64-mingw32
mkdir -p $RPM_BUILD_ROOT%{_prefix}/x86_64-w64-mingw32/bin mkdir -p %{buildroot}%{_prefix}/x86_64-w64-mingw32/bin
mkdir -p $RPM_BUILD_ROOT%{_prefix}/x86_64-w64-mingw32/lib mkdir -p %{buildroot}%{_prefix}/x86_64-w64-mingw32/lib
# The MinGW system root which will contain Windows native binaries # The MinGW system root which will contain Windows native binaries
# and Windows-specific header files, pkgconfig, etc. # and Windows-specific header files, pkgconfig, etc.
mkdir -p $RPM_BUILD_ROOT%{_prefix}/i686-w64-mingw32/sys-root/mingw mkdir -p %{buildroot}%{_prefix}/i686-w64-mingw32/sys-root/mingw
mkdir -p $RPM_BUILD_ROOT%{_prefix}/i686-w64-mingw32/sys-root/mingw/bin mkdir -p %{buildroot}%{_prefix}/i686-w64-mingw32/sys-root/mingw/bin
mkdir -p $RPM_BUILD_ROOT%{_prefix}/i686-w64-mingw32/sys-root/mingw/etc mkdir -p %{buildroot}%{_prefix}/i686-w64-mingw32/sys-root/mingw/etc
mkdir -p $RPM_BUILD_ROOT%{_prefix}/i686-w64-mingw32/sys-root/mingw/include mkdir -p %{buildroot}%{_prefix}/i686-w64-mingw32/sys-root/mingw/include
mkdir -p $RPM_BUILD_ROOT%{_prefix}/i686-w64-mingw32/sys-root/mingw/include/sys mkdir -p %{buildroot}%{_prefix}/i686-w64-mingw32/sys-root/mingw/include/sys
mkdir -p $RPM_BUILD_ROOT%{_prefix}/i686-w64-mingw32/sys-root/mingw/lib mkdir -p %{buildroot}%{_prefix}/i686-w64-mingw32/sys-root/mingw/lib
mkdir -p $RPM_BUILD_ROOT%{_prefix}/i686-w64-mingw32/sys-root/mingw/lib/pkgconfig mkdir -p %{buildroot}%{_prefix}/i686-w64-mingw32/sys-root/mingw/lib/pkgconfig
mkdir -p $RPM_BUILD_ROOT%{_prefix}/i686-w64-mingw32/sys-root/mingw/lib/cmake mkdir -p %{buildroot}%{_prefix}/i686-w64-mingw32/sys-root/mingw/lib/cmake
mkdir -p $RPM_BUILD_ROOT%{_prefix}/i686-w64-mingw32/sys-root/mingw/sbin mkdir -p %{buildroot}%{_prefix}/i686-w64-mingw32/sys-root/mingw/sbin
mkdir -p $RPM_BUILD_ROOT%{_prefix}/x86_64-w64-mingw32/sys-root/mingw mkdir -p %{buildroot}%{_prefix}/x86_64-w64-mingw32/sys-root/mingw
mkdir -p $RPM_BUILD_ROOT%{_prefix}/x86_64-w64-mingw32/sys-root/mingw/bin mkdir -p %{buildroot}%{_prefix}/x86_64-w64-mingw32/sys-root/mingw/bin
mkdir -p $RPM_BUILD_ROOT%{_prefix}/x86_64-w64-mingw32/sys-root/mingw/etc mkdir -p %{buildroot}%{_prefix}/x86_64-w64-mingw32/sys-root/mingw/etc
mkdir -p $RPM_BUILD_ROOT%{_prefix}/x86_64-w64-mingw32/sys-root/mingw/include mkdir -p %{buildroot}%{_prefix}/x86_64-w64-mingw32/sys-root/mingw/include
mkdir -p $RPM_BUILD_ROOT%{_prefix}/x86_64-w64-mingw32/sys-root/mingw/include mkdir -p %{buildroot}%{_prefix}/x86_64-w64-mingw32/sys-root/mingw/include
mkdir -p $RPM_BUILD_ROOT%{_prefix}/x86_64-w64-mingw32/sys-root/mingw/lib mkdir -p %{buildroot}%{_prefix}/x86_64-w64-mingw32/sys-root/mingw/lib
mkdir -p $RPM_BUILD_ROOT%{_prefix}/x86_64-w64-mingw32/sys-root/mingw/lib/pkgconfig mkdir -p %{buildroot}%{_prefix}/x86_64-w64-mingw32/sys-root/mingw/lib/pkgconfig
mkdir -p $RPM_BUILD_ROOT%{_prefix}/x86_64-w64-mingw32/sys-root/mingw/lib/cmake mkdir -p %{buildroot}%{_prefix}/x86_64-w64-mingw32/sys-root/mingw/lib/cmake
mkdir -p $RPM_BUILD_ROOT%{_prefix}/x86_64-w64-mingw32/sys-root/mingw/sbin mkdir -p %{buildroot}%{_prefix}/x86_64-w64-mingw32/sys-root/mingw/sbin
# We don't normally package manual pages and info files, except # We don't normally package manual pages and info files, except
# where those are not supplied by a Fedora native package. So we # where those are not supplied by a Fedora native package. So we
@ -177,36 +211,36 @@ mkdir -p $RPM_BUILD_ROOT%{_prefix}/x86_64-w64-mingw32/sys-root/mingw/sbin
# /usr/x86_64-pc-mingw32/sys-root/man and # /usr/x86_64-pc-mingw32/sys-root/man and
# /usr/x86_64-pc-mingw32/sys-root/doc # /usr/x86_64-pc-mingw32/sys-root/doc
# but those are both packaging bugs. # but those are both packaging bugs.
mkdir -p $RPM_BUILD_ROOT%{_prefix}/i686-w64-mingw32/sys-root/mingw/share mkdir -p %{buildroot}%{_prefix}/i686-w64-mingw32/sys-root/mingw/share
mkdir -p $RPM_BUILD_ROOT%{_prefix}/i686-w64-mingw32/sys-root/mingw/share/doc mkdir -p %{buildroot}%{_prefix}/i686-w64-mingw32/sys-root/mingw/share/doc
mkdir -p $RPM_BUILD_ROOT%{_prefix}/i686-w64-mingw32/sys-root/mingw/share/info mkdir -p %{buildroot}%{_prefix}/i686-w64-mingw32/sys-root/mingw/share/info
mkdir -p $RPM_BUILD_ROOT%{_prefix}/i686-w64-mingw32/sys-root/mingw/share/man mkdir -p %{buildroot}%{_prefix}/i686-w64-mingw32/sys-root/mingw/share/man
mkdir -p $RPM_BUILD_ROOT%{_prefix}/i686-w64-mingw32/sys-root/mingw/share/man/man{1,2,3,4,5,6,7,8,l,n} mkdir -p %{buildroot}%{_prefix}/i686-w64-mingw32/sys-root/mingw/share/man/man{1,2,3,4,5,6,7,8,l,n}
mkdir -p $RPM_BUILD_ROOT%{_prefix}/i686-w64-mingw32/sys-root/mingw/share/aclocal mkdir -p %{buildroot}%{_prefix}/i686-w64-mingw32/sys-root/mingw/share/aclocal
mkdir -p $RPM_BUILD_ROOT%{_prefix}/i686-w64-mingw32/sys-root/mingw/share/themes mkdir -p %{buildroot}%{_prefix}/i686-w64-mingw32/sys-root/mingw/share/themes
mkdir -p $RPM_BUILD_ROOT%{_prefix}/i686-w64-mingw32/sys-root/mingw/share/cmake mkdir -p %{buildroot}%{_prefix}/i686-w64-mingw32/sys-root/mingw/share/cmake
mkdir -p $RPM_BUILD_ROOT%{_prefix}/i686-w64-mingw32/sys-root/mingw/share/locale mkdir -p %{buildroot}%{_prefix}/i686-w64-mingw32/sys-root/mingw/share/locale
mkdir -p $RPM_BUILD_ROOT%{_prefix}/i686-w64-mingw32/sys-root/mingw/share/pkgconfig mkdir -p %{buildroot}%{_prefix}/i686-w64-mingw32/sys-root/mingw/share/pkgconfig
mkdir -p $RPM_BUILD_ROOT%{_prefix}/i686-w64-mingw32/sys-root/mingw/share/xml mkdir -p %{buildroot}%{_prefix}/i686-w64-mingw32/sys-root/mingw/share/xml
mkdir -p $RPM_BUILD_ROOT%{_prefix}/x86_64-w64-mingw32/sys-root/mingw/share mkdir -p %{buildroot}%{_prefix}/x86_64-w64-mingw32/sys-root/mingw/share
mkdir -p $RPM_BUILD_ROOT%{_prefix}/x86_64-w64-mingw32/sys-root/mingw/share/doc mkdir -p %{buildroot}%{_prefix}/x86_64-w64-mingw32/sys-root/mingw/share/doc
mkdir -p $RPM_BUILD_ROOT%{_prefix}/x86_64-w64-mingw32/sys-root/mingw/share/info mkdir -p %{buildroot}%{_prefix}/x86_64-w64-mingw32/sys-root/mingw/share/info
mkdir -p $RPM_BUILD_ROOT%{_prefix}/x86_64-w64-mingw32/sys-root/mingw/share/man mkdir -p %{buildroot}%{_prefix}/x86_64-w64-mingw32/sys-root/mingw/share/man
mkdir -p $RPM_BUILD_ROOT%{_prefix}/x86_64-w64-mingw32/sys-root/mingw/share/man/man{1,2,3,4,5,6,7,8,l,n} mkdir -p %{buildroot}%{_prefix}/x86_64-w64-mingw32/sys-root/mingw/share/man/man{1,2,3,4,5,6,7,8,l,n}
mkdir -p $RPM_BUILD_ROOT%{_prefix}/x86_64-w64-mingw32/sys-root/mingw/share/aclocal mkdir -p %{buildroot}%{_prefix}/x86_64-w64-mingw32/sys-root/mingw/share/aclocal
mkdir -p $RPM_BUILD_ROOT%{_prefix}/x86_64-w64-mingw32/sys-root/mingw/share/themes mkdir -p %{buildroot}%{_prefix}/x86_64-w64-mingw32/sys-root/mingw/share/themes
mkdir -p $RPM_BUILD_ROOT%{_prefix}/x86_64-w64-mingw32/sys-root/mingw/share/cmake mkdir -p %{buildroot}%{_prefix}/x86_64-w64-mingw32/sys-root/mingw/share/cmake
mkdir -p $RPM_BUILD_ROOT%{_prefix}/x86_64-w64-mingw32/sys-root/mingw/share/locale mkdir -p %{buildroot}%{_prefix}/x86_64-w64-mingw32/sys-root/mingw/share/locale
mkdir -p $RPM_BUILD_ROOT%{_prefix}/x86_64-w64-mingw32/sys-root/mingw/share/pkgconfig mkdir -p %{buildroot}%{_prefix}/x86_64-w64-mingw32/sys-root/mingw/share/pkgconfig
mkdir -p $RPM_BUILD_ROOT%{_prefix}/x86_64-w64-mingw32/sys-root/mingw/share/xml mkdir -p %{buildroot}%{_prefix}/x86_64-w64-mingw32/sys-root/mingw/share/xml
# Own folders for all locales # Own folders for all locales
# Snippet taken from the Fedora filesystem package # Snippet taken from the Fedora filesystem package
sed -n -f %{SOURCE102} /usr/share/xml/iso-codes/iso_639.xml > $RPM_BUILD_ROOT/iso_639.tab sed -n -f %{SOURCE102} /usr/share/xml/iso-codes/iso_639.xml > %{buildroot}/iso_639.tab
sed -n -f %{SOURCE103} /usr/share/xml/iso-codes/iso_3166.xml > $RPM_BUILD_ROOT/iso_3166.tab sed -n -f %{SOURCE103} /usr/share/xml/iso-codes/iso_3166.xml > %{buildroot}/iso_3166.tab
grep -v "^$" $RPM_BUILD_ROOT/iso_639.tab | grep -v "^#" | while read a b c d ; do grep -v "^$" %{buildroot}/iso_639.tab | grep -v "^#" | while read a b c d ; do
[[ "$d" =~ "^Reserved" ]] && continue [[ "$d" =~ "^Reserved" ]] && continue
[[ "$d" =~ "^No linguistic" ]] && continue [[ "$d" =~ "^No linguistic" ]] && continue
@ -229,39 +263,48 @@ cat %{SOURCE101} | grep -v "^#" | grep -v "^$" | while read loc ; do
# If the locality is not official, skip it # If the locality is not official, skip it
if [ -n "$locality" ]; then if [ -n "$locality" ]; then
grep -q "^$locality" $RPM_BUILD_ROOT/iso_3166.tab || continue grep -q "^$locality" %{buildroot}/iso_3166.tab || continue
fi fi
# If the locale is not official and not special, skip it # If the locale is not official and not special, skip it
if [ -z "$special" ]; then if [ -z "$special" ]; then
egrep -q "[[:space:]]${locale%%_*}[[:space:]]" $RPM_BUILD_ROOT/iso_639.tab || continue egrep -q "[[:space:]]${locale%%_*}[[:space:]]" %{buildroot}/iso_639.tab || continue
fi fi
echo "%lang(${locale}) %{_prefix}/i686-w64-mingw32/sys-root/mingw/share/locale/${loc}" >> filelist_mingw32 echo "%lang(${locale}) %{_prefix}/i686-w64-mingw32/sys-root/mingw/share/locale/${loc}" >> filelist_mingw32
echo "%lang(${locale}) %{_prefix}/x86_64-w64-mingw32/sys-root/mingw/share/locale/${loc}" >> filelist_mingw64 echo "%lang(${locale}) %{_prefix}/x86_64-w64-mingw32/sys-root/mingw/share/locale/${loc}" >> filelist_mingw64
done done
rm -f $RPM_BUILD_ROOT/iso_639.tab rm -f %{buildroot}/iso_639.tab
rm -f $RPM_BUILD_ROOT/iso_3166.tab rm -f %{buildroot}/iso_3166.tab
cat filelist_mingw32 filelist_mingw64 | grep "locale" | while read a b ; do cat filelist_mingw32 filelist_mingw64 | grep "locale" | while read a b ; do
mkdir -p -m 755 %{buildroot}/$b/LC_MESSAGES mkdir -p -m 755 %{buildroot}/$b/LC_MESSAGES
done done
# NB. NOT _libdir # NB. NOT _libdir
mkdir -p $RPM_BUILD_ROOT/usr/lib/rpm mkdir -p %{buildroot}/usr/lib/rpm
install -m 0755 %{SOURCE6} $RPM_BUILD_ROOT%{_rpmconfigdir} install -m 0755 %{SOURCE6} %{buildroot}%{_rpmconfigdir}
install -m 0755 %{SOURCE7} $RPM_BUILD_ROOT%{_rpmconfigdir} install -m 0755 %{SOURCE7} %{buildroot}%{_rpmconfigdir}
install -m 0755 %{SOURCE8} $RPM_BUILD_ROOT%{_rpmconfigdir} install -m 0755 %{SOURCE8} %{buildroot}%{_rpmconfigdir}
install -m 0755 %{SOURCE13} $RPM_BUILD_ROOT%{_rpmconfigdir} install -m 0755 %{SOURCE13} %{buildroot}%{_rpmconfigdir}
mkdir -p $RPM_BUILD_ROOT/usr/lib/rpm/fileattrs mkdir -p %{buildroot}/usr/lib/rpm/fileattrs
install -m 0644 %{SOURCE14} $RPM_BUILD_ROOT%{_rpmconfigdir}/fileattrs/ install -m 0644 %{SOURCE14} %{buildroot}%{_rpmconfigdir}/fileattrs/
install -m 0644 %{SOURCE15} $RPM_BUILD_ROOT%{_rpmconfigdir}/fileattrs/ install -m 0644 %{SOURCE15} %{buildroot}%{_rpmconfigdir}/fileattrs/
mkdir -p $RPM_BUILD_ROOT%{_datadir}/mingw mkdir -p %{buildroot}%{_datadir}/mingw
install -m 0644 %{SOURCE11} $RPM_BUILD_ROOT%{_datadir}/mingw/ install -m 0644 %{SOURCE11} %{buildroot}%{_datadir}/mingw/
install -m 0644 %{SOURCE12} $RPM_BUILD_ROOT%{_datadir}/mingw/ install -m 0644 %{SOURCE12} %{buildroot}%{_datadir}/mingw/
install -m 0644 %{SOURCE18} $RPM_BUILD_ROOT%{_datadir}/mingw/ install -m 0644 %{SOURCE18} %{buildroot}%{_datadir}/mingw/
install -m 0644 %{SOURCE19} $RPM_BUILD_ROOT%{_datadir}/mingw/ install -m 0644 %{SOURCE19} %{buildroot}%{_datadir}/mingw/
mkdir -p %{buildroot}%{pkgconfig_personalitydir}
install -m 0644 %{SOURCE20} %{buildroot}%{pkgconfig_personalitydir}/i686-w64-mingw32.personality
install -m 0644 %{SOURCE21} %{buildroot}%{pkgconfig_personalitydir}/x86_64-w64-mingw32.personality
# Link mingw-pkg-config man pages to pkgconf(1)
mkdir -p %{buildroot}%{_mandir}/man1/
echo ".so man1/pkgconf.1" > %{buildroot}%{_mandir}/man1/i686-w64-mingw32-pkg-config.1
echo ".so man1/pkgconf.1" > %{buildroot}%{_mandir}/man1/x86_64-w64-mingw32-pkg-config.1
%files base %files base
@ -281,10 +324,15 @@ install -m 0644 %{SOURCE19} $RPM_BUILD_ROOT%{_datadir}/mingw/
%{_bindir}/mingw32-make %{_bindir}/mingw32-make
%{_bindir}/mingw32-meson %{_bindir}/mingw32-meson
%{_bindir}/mingw32-pkg-config %{_bindir}/mingw32-pkg-config
%{_bindir}/i686-w64-mingw32-pkg-config
%{_mandir}/man1/i686-w64-mingw32-pkg-config.1*
%{_prefix}/i686-w64-mingw32 %{_prefix}/i686-w64-mingw32
%{_rpmconfigdir}/fileattrs/mingw32.attr %{_rpmconfigdir}/fileattrs/mingw32.attr
%{_datadir}/mingw/toolchain-mingw32.cmake %{_datadir}/mingw/toolchain-mingw32.cmake
%{_datadir}/mingw/toolchain-mingw32.meson %{_datadir}/mingw/toolchain-mingw32.meson
%{pkgconfig_personalitydir}/i686-w64-mingw32.personality
%{_mandir}/man1/i686-w64-mingw32-pkg-config.1*
%files -n mingw64-filesystem %files -n mingw64-filesystem
%{macrosdir}/macros.mingw64 %{macrosdir}/macros.mingw64
@ -294,21 +342,83 @@ install -m 0644 %{SOURCE19} $RPM_BUILD_ROOT%{_datadir}/mingw/
%{_bindir}/mingw64-make %{_bindir}/mingw64-make
%{_bindir}/mingw64-meson %{_bindir}/mingw64-meson
%{_bindir}/mingw64-pkg-config %{_bindir}/mingw64-pkg-config
%{_bindir}/x86_64-w64-mingw32-pkg-config
%{_mandir}/man1/x86_64-w64-mingw32-pkg-config.1*
%{_prefix}/x86_64-w64-mingw32 %{_prefix}/x86_64-w64-mingw32
%{_rpmconfigdir}/fileattrs/mingw64.attr %{_rpmconfigdir}/fileattrs/mingw64.attr
%{_datadir}/mingw/toolchain-mingw64.cmake %{_datadir}/mingw/toolchain-mingw64.cmake
%{_datadir}/mingw/toolchain-mingw64.meson %{_datadir}/mingw/toolchain-mingw64.meson
%{pkgconfig_personalitydir}/x86_64-w64-mingw32.personality
%{_mandir}/man1/x86_64-w64-mingw32-pkg-config.1*
%changelog %changelog
* Thu Aug 05 2021 Uri Lublin <uril@redhat.com> * Mon Aug 09 2021 Mohan Boddu <mboddu@redhat.com>
- Update package description - Rebuilt for IMA sigs, glibc 2.34, aarch64 flags
Resolves: rhbz#1932299 Related: rhbz#1991688
* Thu Feb 04 2021 Uri Lublin <uril@redhat.com> - 104-2 * Sat Jun 12 2021 Neal Gompa <ngompa13@gmail.com> - 119-1
- Fix building with meson >= 0.54 - Use pkgconf for pkgconfig
Resolves: rhbz#1918306
Related: rhbz#1872692 * Mon Jun 07 2021 Sandro Mani <manisandro@gmail.com> - 118-1
- Allow overriding CFLAGS/CXXFLAGS/LDFLAGS for %%mingw_meson
* Fri Apr 16 2021 Mohan Boddu <mboddu@redhat.com>
- Rebuilt for RHEL 9 BETA on Apr 15th 2021. Related: rhbz#1947937
* Mon Feb 01 2021 Sandro Mani <manisandro@gmail.com> - 117-1
- Filter Windows API umbrella libraries from requires
* Tue Jan 26 2021 Fedora Release Engineering <releng@fedoraproject.org> 116-2
- Rebuilt for https://fedoraproject.org/wiki/Fedora_34_Mass_Rebuild
* Mon Jul 27 2020 Sandro Mani <manisandro@gmail.com> - 116-1
- Add -lssp to LDFLAGS
* Thu Jul 23 2020 Sandro Mani <manisandro@gmail.com> - 115-1
- Add -fstack-protector to LDFLAGS (since we carry -D_FORTIFY_SOURCE=2 in cflags, see https://sourceforge.net/p/mingw-w64/bugs/818/)
* Tue Jul 14 2020 Daniel P. Berrangé <berrange@redhat.com> - 114-1
- Add meson hint for libgcrypt-config on mingw cross builds (#1856446)
* Sat May 23 2020 Sandro Mani <manisandro@gmail.com> - 113-1
- Add %%mingw_make_build and %%mingw_make_install
* Fri May 22 2020 Sandro Mani <manisandro@gmail.com> - 112-1
- Fix %%mingw_meson resulting in ERROR: Unable to determine dynamic linker
* Fri May 01 2020 David Woodhouse <dwmw2@infradead.org> - 111-1
- Quote tr sequences like '[blank]' to prevent the shell from doing so (#1830233)
* Wed Jan 29 2020 Fedora Release Engineering <releng@fedoraproject.org>
- Rebuilt for https://fedoraproject.org/wiki/Fedora_32_Mass_Rebuild
* Thu Nov 07 2019 Marc-André Lureau <marcandre.lureau@redhat.com> - 110-1
- Add redhat-rpm-config dependency. Fixes rhbz#1769792
* Thu Aug 29 2019 Sandro Mani <manisandro@gmail.com> - 109-1
- Add dlltool to toolchain-mingw{32,64}.meson
* Mon Aug 12 2019 Sandro Mani <manisandro@gmail.com> - 108-1
- Fix mingw-find-debuginfo.sh to pick up strippable binaries also in %%{_prefix}/%%{mingw32,64_target}
* Thu Jul 25 2019 Fedora Release Engineering <releng@fedoraproject.org>
- Rebuilt for https://fedoraproject.org/wiki/Fedora_31_Mass_Rebuild
* Wed Jun 19 2019 Fabiano Fidêncio <fidencio@redhat.com> - 107-1
- Add %%mingw_ninja_install macro
* Thu Feb 14 2019 Sandro Mani <manisandro@gmail.com> - 106-1
- Revert "Remove redundant $@ in mingw_cmake and mingw_meson", it causes no arguments at all to be passed to cmake
* Tue Feb 05 2019 Elliott Sales de Andrade <quantum.analyst@gmail.com> - 105-1
- Remove redundant $@ in mingw_cmake and mingw_meson, breaking wrapper scripts
* Fri Feb 01 2019 Fedora Release Engineering <releng@fedoraproject.org>
- Rebuilt for https://fedoraproject.org/wiki/Fedora_30_Mass_Rebuild
* Fri Jul 13 2018 Fedora Release Engineering <releng@fedoraproject.org>
- Rebuilt for https://fedoraproject.org/wiki/Fedora_29_Mass_Rebuild
* Fri Apr 20 2018 Elliott Sales de Andrade <quantum.analyst@gmail.com> - 104-1 * Fri Apr 20 2018 Elliott Sales de Andrade <quantum.analyst@gmail.com> - 104-1
- Add macros for meson and ninja - Add macros for meson and ninja