From: Richard W.M. Jones <"Richard W.M. Jones "> Date: Thu, 4 Sep 2008 18:03:56 +0000 (+0100) Subject: Use mingw filesystem macros. X-Git-Url: http://git.annexia.org/?a=commitdiff_plain;h=c57d35634489fbdf11cf98438b935b8a32dca4e7;p=fedora-mingw.git Use mingw filesystem macros. --- diff --git a/runtime/mingw-runtime.spec b/runtime/mingw-runtime.spec index c8f6168..1078fe9 100644 --- a/runtime/mingw-runtime.spec +++ b/runtime/mingw-runtime.spec @@ -1,8 +1,8 @@ -%define __os_install_post /usr/lib/rpm/brp-compress %{nil} +%include /usr/lib/rpm/mingw-defs Name: mingw-runtime Version: 3.14 -Release: 2%{?dist} +Release: 4%{?dist} Summary: MinGW Windows cross-compiler runtime and root filesystem License: Public Domain @@ -13,9 +13,11 @@ BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) BuildArch: noarch +BuildRequires: mingw-filesystem >= 9 BuildRequires: mingw-binutils BuildRequires: mingw-gcc +Requires: mingw-filesystem >= 9 Requires: mingw-binutils Requires: mingw-gcc @@ -23,22 +25,19 @@ Requires: mingw-gcc # longer needed. Obsoletes: mingw-bootstrap -#%define _use_internal_dependency_generator 0 -#%define __debug_install_post %{nil} - %description -MinGW Windows cross-compiler runtime, base libraries and root filesystem. +MinGW Windows cross-compiler runtime, base libraries. %prep %setup -q %build -CFLAGS="-I%{_prefix}/i686-pc-mingw32/sys-root/mingw/include" \ +CFLAGS="-I%{_mingw_includedir}" \ ./configure \ --build=%_build \ - --host=i686-pc-mingw32 + --host=%{_mingw_host} make @@ -46,7 +45,13 @@ make %install rm -rf $RPM_BUILD_ROOT -make prefix=$RPM_BUILD_ROOT%{_prefix}/i686-pc-mingw32/sys-root/mingw install +make prefix=$RPM_BUILD_ROOT%{_mingw_prefix} install + +# make install places these in nonstandard locations, so move them. +mkdir -p $RPM_BUILD_ROOT%{_mingw_docdir} +mv $RPM_BUILD_ROOT%{_mingw_prefix}/doc/* $RPM_BUILD_ROOT%{_mingw_docdir}/ +mkdir -p $RPM_BUILD_ROOT%{_mingw_mandir} +mv $RPM_BUILD_ROOT%{_mingw_prefix}/man/* $RPM_BUILD_ROOT%{_mingw_mandir}/ %clean @@ -55,13 +60,16 @@ rm -rf $RPM_BUILD_ROOT %files %defattr(-,root,root) -%{_prefix}/i686-pc-mingw32/sys-root/mingw/bin/* -%{_prefix}/i686-pc-mingw32/sys-root/mingw/doc/mingw-runtime/* -%{_prefix}/i686-pc-mingw32/sys-root/mingw/include/* -%{_prefix}/i686-pc-mingw32/sys-root/mingw/lib/* -%{_prefix}/i686-pc-mingw32/sys-root/mingw/man/man3/* +%{_mingw_bindir}/* +%{_mingw_docdir}/* +%{_mingw_includedir}/* +%{_mingw_libdir}/* +%{_mingw_mandir}/man3/* %changelog -* Mon Jul 7 2008 Richard W.M. Jones - 4.3.1-2 +* Thu Sep 4 2008 Richard W.M. Jones - 3.14-4 +- Use RPM macros from mingw-filesystem. + +* Mon Jul 7 2008 Richard W.M. Jones - 3.14-2 - Initial RPM release, largely based on earlier work from several sources. diff --git a/w32api/mingw-w32api.spec b/w32api/mingw-w32api.spec index c4752a4..49db041 100644 --- a/w32api/mingw-w32api.spec +++ b/w32api/mingw-w32api.spec @@ -1,8 +1,8 @@ -%define __os_install_post /usr/lib/rpm/brp-compress %{nil} +%include /usr/lib/rpm/mingw-defs Name: mingw-w32api Version: 3.11 -Release: 1%{?dist} +Release: 3%{?dist} Summary: MinGW Windows cross-compiler Win32 header files License: Public Domain @@ -13,10 +13,12 @@ BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) BuildArch: noarch +BuildRequires: mingw-filesystem >= 3 BuildRequires: mingw-binutils BuildRequires: mingw-gcc BuildRequires: mingw-runtime +Requires: mingw-filesystem >= 3 Requires: mingw-binutils Requires: mingw-gcc Requires: mingw-runtime @@ -37,11 +39,9 @@ MinGW Windows cross-compiler Win32 header files. %setup -q -n w32api-%{version} %build -#CFLAGS="-I%{_prefix}/i686-pc-mingw32/sys-root/mingw/include" \ - ./configure \ --build=%_build \ - --host=i686-pc-mingw32 + --host=%{_mingw_host} make @@ -49,7 +49,7 @@ make %install rm -rf $RPM_BUILD_ROOT -make prefix=$RPM_BUILD_ROOT%{_prefix}/i686-pc-mingw32/sys-root/mingw install +make prefix=$RPM_BUILD_ROOT%{_mingw_prefix} install %clean @@ -58,9 +58,12 @@ rm -rf $RPM_BUILD_ROOT %files %defattr(-,root,root) -%{_prefix}/i686-pc-mingw32/sys-root/mingw/include/* -%{_prefix}/i686-pc-mingw32/sys-root/mingw/lib/* +%{_mingw_includedir}/* +%{_mingw_libdir}/* %changelog -* Mon Jul 7 2008 Richard W.M. Jones - 4.3.1-2 +* Thu Sep 4 2008 Richard W.M. Jones - 3.11-3 +- Use the RPM macros from mingw-filesystem. + +* Mon Jul 7 2008 Richard W.M. Jones - 3.11-2 - Initial RPM release, largely based on earlier work from several sources.