!3 升级mingw-winpthreads版本到9.0.0
From: @niko_yhc Reviewed-by: @jianminw Signed-off-by: @jianminw
This commit is contained in:
commit
2f8d5fbac6
Binary file not shown.
@ -1,18 +1,45 @@
|
|||||||
%?mingw_package_header
|
%{?mingw_package_header}
|
||||||
|
|
||||||
|
#%%global snapshot_date 20160204
|
||||||
|
#%%global snapshot_rev 38410ad06264949efcb331f7a63575c6be31c5e4
|
||||||
|
#%%global snapshot_rev_short %(echo %snapshot_rev | cut -c1-6)
|
||||||
|
#%%global branch trunk
|
||||||
|
|
||||||
|
#%%global pre rc2
|
||||||
|
|
||||||
|
# Run the testsuite
|
||||||
%global enable_tests 0
|
%global enable_tests 0
|
||||||
|
|
||||||
|
%global enable_pthread_shared 0
|
||||||
|
|
||||||
Name: mingw-winpthreads
|
Name: mingw-winpthreads
|
||||||
Version: 6.0.0
|
Version: 9.0.0
|
||||||
Release: 4
|
Release: 3
|
||||||
Summary: MinGW pthread library
|
Summary: MinGW pthread library
|
||||||
|
|
||||||
|
# The main license of winpthreads is MIT, but parts of this library
|
||||||
|
# are derived from the "Posix Threads library for Microsoft Windows"
|
||||||
|
# http://locklessinc.com/articles/pthreads_on_windows/
|
||||||
License: MIT and BSD
|
License: MIT and BSD
|
||||||
URL: http://mingw-w64.sourceforge.net/
|
URL: http://mingw-w64.sourceforge.net/
|
||||||
Source0: http://downloads.sourceforge.net/mingw-w64/mingw-w64-v%{version}.tar.bz2
|
%if 0%{?snapshot_date}
|
||||||
|
# To regenerate a snapshot:
|
||||||
|
# Use your regular webbrowser to open https://sourceforge.net/p/mingw-w64/mingw-w64/ci/%{snapshot_rev}/tarball
|
||||||
|
# This triggers the SourceForge instructure to generate a snapshot
|
||||||
|
# After that you can pull in the archive with:
|
||||||
|
# spectool -g mingw-headers.spec
|
||||||
|
Source0: http://sourceforge.net/code-snapshots/git/m/mi/mingw-w64/mingw-w64.git/mingw-w64-mingw-w64-%{snapshot_rev}.zip
|
||||||
|
%else
|
||||||
|
Source0: http://downloads.sourceforge.net/mingw-w64/mingw-w64-v%{version}%{?pre:-%{pre}}.tar.bz2
|
||||||
|
%endif
|
||||||
|
|
||||||
BuildArch: noarch
|
BuildArch: noarch
|
||||||
BuildRequires: mingw32-filesystem >= 95 mingw64-filesystem >= 95
|
|
||||||
BuildRequires: mingw32-gcc-c++ mingw64-gcc-c++
|
BuildRequires: make
|
||||||
BuildRequires: mingw32-crt mingw64-crt
|
BuildRequires: mingw32-filesystem >= 95
|
||||||
|
BuildRequires: mingw64-filesystem >= 95
|
||||||
|
BuildRequires: mingw32-gcc-c++
|
||||||
|
BuildRequires: mingw64-gcc-c++
|
||||||
|
|
||||||
%if 0%{?enable_tests}
|
%if 0%{?enable_tests}
|
||||||
BuildRequires: wine-wow
|
BuildRequires: wine-wow
|
||||||
@ -33,6 +60,7 @@ Win32 does not, and is unlikely to ever, support pthreads
|
|||||||
natively. This project seeks to provide a freely available and
|
natively. This project seeks to provide a freely available and
|
||||||
high-quality solution to this problem.
|
high-quality solution to this problem.
|
||||||
|
|
||||||
|
# Win32
|
||||||
%package -n mingw32-winpthreads
|
%package -n mingw32-winpthreads
|
||||||
Summary: MinGW pthread library for the win32 target
|
Summary: MinGW pthread library for the win32 target
|
||||||
Obsoletes: mingw32-pthreads < 2.8.0-25.20110511cvs
|
Obsoletes: mingw32-pthreads < 2.8.0-25.20110511cvs
|
||||||
@ -62,6 +90,7 @@ Provides: mingw32-pthreads-static = 2.8.0-25.20110511cvs
|
|||||||
%description -n mingw32-winpthreads-static
|
%description -n mingw32-winpthreads-static
|
||||||
Static version of the MinGW Windows pthreads library.
|
Static version of the MinGW Windows pthreads library.
|
||||||
|
|
||||||
|
# Win64
|
||||||
%package -n mingw64-winpthreads
|
%package -n mingw64-winpthreads
|
||||||
Summary: MinGW pthread library for the win64 target
|
Summary: MinGW pthread library for the win64 target
|
||||||
Obsoletes: mingw64-pthreads < 2.8.0-25.20110511cvs
|
Obsoletes: mingw64-pthreads < 2.8.0-25.20110511cvs
|
||||||
@ -91,32 +120,46 @@ Provides: mingw64-pthreads-static = 2.8.0-25.20110511cvs
|
|||||||
%description -n mingw64-winpthreads-static
|
%description -n mingw64-winpthreads-static
|
||||||
Static version of the MinGW Windows pthreads library.
|
Static version of the MinGW Windows pthreads library.
|
||||||
|
|
||||||
|
%if 0%{enable_pthread_shared} == 1
|
||||||
%?mingw_debug_package
|
%?mingw_debug_package
|
||||||
|
%endif
|
||||||
|
|
||||||
%prep
|
%prep
|
||||||
%autosetup -p1 -n mingw-w64-v%{version}
|
%if 0%{?snapshot_date}
|
||||||
|
rm -rf mingw-w64-v%{version}
|
||||||
|
mkdir mingw-w64-v%{version}
|
||||||
|
cd mingw-w64-v%{version}
|
||||||
|
unzip %{S:0}
|
||||||
|
%autosetup -p1 -D -T -n mingw-w64-v%{version}/mingw-w64-mingw-w64-%{snapshot_rev}
|
||||||
|
%else
|
||||||
|
%autosetup -p1 -n mingw-w64-v%{version}%{?pre:-%{pre}}
|
||||||
|
%endif
|
||||||
|
|
||||||
|
|
||||||
%build
|
%build
|
||||||
pushd mingw-w64-libraries/winpthreads
|
pushd mingw-w64-libraries/winpthreads
|
||||||
%mingw_configure
|
%mingw_configure \
|
||||||
%mingw_make %{?smp_mflags}
|
%if 0%{enable_pthread_shared} == 0
|
||||||
|
--enable-shared=no
|
||||||
|
%endif
|
||||||
|
%mingw_make_build
|
||||||
popd
|
popd
|
||||||
|
|
||||||
|
|
||||||
%if 0%{?enable_tests}
|
%if 0%{?enable_tests}
|
||||||
|
|
||||||
%check
|
%check
|
||||||
|
# Prepare a wine prefix
|
||||||
export WINEPREFIX=/tmp/wine-winpthreads
|
export WINEPREFIX=/tmp/wine-winpthreads
|
||||||
mkdir $WINEPREFIX
|
mkdir $WINEPREFIX
|
||||||
winecfg || :
|
winecfg || :
|
||||||
|
|
||||||
|
# Run the tests
|
||||||
pushd mingw-w64-libraries/winpthreads
|
pushd mingw-w64-libraries/winpthreads
|
||||||
%mingw_make check -k || :
|
%mingw_make check -k || :
|
||||||
popd
|
popd
|
||||||
|
|
||||||
|
# Clean up the wine prefix
|
||||||
wineserver --kill || :
|
wineserver --kill || :
|
||||||
rm -rf /tmp/wine-winpthreads
|
rm -rf /tmp/wine-winpthreads
|
||||||
|
|
||||||
@ -125,17 +168,21 @@ rm -rf /tmp/wine-winpthreads
|
|||||||
|
|
||||||
%install
|
%install
|
||||||
pushd mingw-w64-libraries/winpthreads
|
pushd mingw-w64-libraries/winpthreads
|
||||||
%mingw_make install DESTDIR=$RPM_BUILD_ROOT
|
%mingw_make_install DESTDIR=%{buildroot}
|
||||||
popd
|
popd
|
||||||
|
|
||||||
|
# Drop all .la files
|
||||||
find $RPM_BUILD_ROOT -name "*.la" -delete
|
find $RPM_BUILD_ROOT -name "*.la" -delete
|
||||||
|
|
||||||
|
|
||||||
|
# Win32
|
||||||
%files -n mingw32-winpthreads
|
%files -n mingw32-winpthreads
|
||||||
%license COPYING
|
%license COPYING
|
||||||
|
%if 0%{enable_pthread_shared} == 1
|
||||||
%{mingw32_bindir}/libwinpthread-1.dll
|
%{mingw32_bindir}/libwinpthread-1.dll
|
||||||
%{mingw32_libdir}/libwinpthread.dll.a
|
%{mingw32_libdir}/libwinpthread.dll.a
|
||||||
%{mingw32_libdir}/libpthread.dll.a
|
%{mingw32_libdir}/libpthread.dll.a
|
||||||
|
%endif
|
||||||
%{mingw32_includedir}/pthread.h
|
%{mingw32_includedir}/pthread.h
|
||||||
%{mingw32_includedir}/pthread_compat.h
|
%{mingw32_includedir}/pthread_compat.h
|
||||||
%{mingw32_includedir}/pthread_signal.h
|
%{mingw32_includedir}/pthread_signal.h
|
||||||
@ -148,11 +195,14 @@ find $RPM_BUILD_ROOT -name "*.la" -delete
|
|||||||
%{mingw32_libdir}/libwinpthread.a
|
%{mingw32_libdir}/libwinpthread.a
|
||||||
%{mingw32_libdir}/libpthread.a
|
%{mingw32_libdir}/libpthread.a
|
||||||
|
|
||||||
|
# Win64
|
||||||
%files -n mingw64-winpthreads
|
%files -n mingw64-winpthreads
|
||||||
%license COPYING
|
%license COPYING
|
||||||
|
%if 0%{enable_pthread_shared} == 1
|
||||||
%{mingw64_bindir}/libwinpthread-1.dll
|
%{mingw64_bindir}/libwinpthread-1.dll
|
||||||
%{mingw64_libdir}/libwinpthread.dll.a
|
%{mingw64_libdir}/libwinpthread.dll.a
|
||||||
%{mingw64_libdir}/libpthread.dll.a
|
%{mingw64_libdir}/libpthread.dll.a
|
||||||
|
%endif
|
||||||
%{mingw64_includedir}/pthread.h
|
%{mingw64_includedir}/pthread.h
|
||||||
%{mingw64_includedir}/pthread_compat.h
|
%{mingw64_includedir}/pthread_compat.h
|
||||||
%{mingw64_includedir}/pthread_signal.h
|
%{mingw64_includedir}/pthread_signal.h
|
||||||
@ -167,6 +217,9 @@ find $RPM_BUILD_ROOT -name "*.la" -delete
|
|||||||
|
|
||||||
|
|
||||||
%changelog
|
%changelog
|
||||||
|
* Wed Feb 21 2024 yinhongchang <yinhongchang@kylinsec.com.cn> - 9.0.0-3
|
||||||
|
- update version to 9.0.0
|
||||||
|
|
||||||
* Wed Nov 04 2020 Zhiyi Weng <zhiyi@iscas.ac.cn> - 6.0.0-4
|
* Wed Nov 04 2020 Zhiyi Weng <zhiyi@iscas.ac.cn> - 6.0.0-4
|
||||||
- Add build require mingw-crt for bootstrap.
|
- Add build require mingw-crt for bootstrap.
|
||||||
|
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user