1 Summary: POSIX Threads component implementation for Win32 - MinGW32 cross version
2 Summary(pl.UTF-8): Implementacja komponentu POSIX Threads dla Win32 - wersja skrośna dla MinGW32
3 Name: crossmingw32-pthreads-w32
5 %define dver %(echo %{version} | tr . -)
8 Group: Development/Libraries
9 Source0: ftp://sourceware.org/pub/pthreads-win32/pthreads-w32-%{dver}-release.tar.gz
10 # Source0-md5: 36ba827d6aa0fa9f9ae740a35626e2e3
11 Patch0: %{name}-timespec.patch
12 URL: http://www.sourceware.org/pthreads-win32/
13 BuildRequires: crossmingw32-gcc
14 BuildRequires: sed >= 4.0
15 Requires: crossmingw32-runtime
16 BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
18 %define no_install_post_strip 1
20 %define target i386-mingw32
21 %define target_platform i386-pc-mingw32
23 %define _sysprefix /usr
24 %define _prefix %{_sysprefix}/%{target}
25 %define _libdir %{_prefix}/lib
26 %define _dlldir /usr/share/wine/windows/system
27 %define __cc %{target}-gcc
28 %define __cxx %{target}-g++
30 %ifarch alpha sparc sparc64 sparcv9
34 # -z options are invalid for mingw linker, most of -f options are Linux-specific
35 %define filterout_ld -Wl,-z,.*
36 %define filterout_c -f[-a-z0-9=]*
39 Pthreads-win32 is an Open Source Software implementation of the
40 Threads component of the POSIX 1003.1c 1995 Standard for Microsoft's
41 Win32 environment. Some functions from POSIX 1003.1b are also
42 supported including semaphores. Other related functions include the
43 set of read-write lock functions. The library also supports some of
44 the functionality of the Open Group's Single Unix specification,
45 version 2, namely mutex types.
47 This package contains the cross version for Win32.
49 %description -l pl.UTF-8
50 PThreads-win32 to mająca otwarte źródła implementacja komponentu
51 Threads (wątków) ze specyfikacji standardu POSIX 1003.1c z 1995 roku
52 dla środowiska Win32 Microsoftu. Obsługiwane są także niektóre funkcje
53 z POSIX 1003.1b, w tym semafory. Inne powiązane funkcje to zbiór
54 funkcji blokad r/w. Biblioteka obsługuje także część funkcjonalności
55 specyfikacji Single Unix w wersji 2 wydanej przez Open Group, a
56 konkretnie typy mutex.
58 Ten pakiet zawiera wersję skrośną dla Win32.
61 Summary: Static POSIX Threads library (cross MinGW32 version)
62 Summary(pl.UTF-8): Statyczna biblioteka POSIX Threads (wersja skrośna MinGW32)
63 Group: Development/Libraries
64 Requires: %{name} = %{version}-%{release}
67 Static POSIX Threads library (cross MinGW32 version).
69 %description static -l pl.UTF-8
70 Statyczna biblioteka POSIX Threads (wersja skrośna MinGW32).
73 Summary: POSIX Threads - DLL library for Windows
74 Summary(pl.UTF-8): POSIX Threads - biblioteka DLL dla Windows
75 Group: Applications/Emulators
79 POSIX Threads - DLL library for Windows.
81 %description dll -l pl.UTF-8
82 POSIX Threads - biblioteka DLL dla Windows.
85 %setup -q -n pthreads-w32-%{dver}-release
91 for type in GC-inlined GCE-inlined GC-static ; do
97 OPT='%{rpmcflags} $(CLEANUP)'
101 %{__mv} libpthreadGC2.a lib/libpthreadGC2.dll.a
102 %{__mv} pthreadGC2.dll lib
105 %{__mv} libpthreadGCE2.a lib/libpthreadGCE2.dll.a
106 %{__mv} pthreadGCE2.dll lib
109 %{__mv} libpthreadGC2.a lib
114 %{target}-strip -R.comment -R.note lib/*.dll
115 %{target}-strip -g -R.comment -R.note lib/*.a
119 rm -rf $RPM_BUILD_ROOT
120 install -d $RPM_BUILD_ROOT{%{_libdir},%{_includedir},%{_dlldir}}
122 install lib/*.dll $RPM_BUILD_ROOT%{_dlldir}
123 install lib/*.a $RPM_BUILD_ROOT%{_libdir}
124 ln -s libpthreadGC2.dll.a $RPM_BUILD_ROOT%{_libdir}/libpthread.dll.a
125 ln -s libpthreadGC2.a $RPM_BUILD_ROOT%{_libdir}/libpthread.a
126 cp -p pthread.h sched.h semaphore.h $RPM_BUILD_ROOT%{_includedir}
129 rm -rf $RPM_BUILD_ROOT
132 %defattr(644,root,root,755)
133 %doc ANNOUNCE BUGS CONTRIBUTORS COPYING ChangeLog FAQ MAINTAINERS NEWS PROGRESS README README.CV README.NONPORTABLE TODO
134 %{_libdir}/libpthread.dll.a
135 %{_libdir}/libpthreadGC2.dll.a
136 %{_libdir}/libpthreadGCE2.dll.a
137 %{_includedir}/pthread.h
138 %{_includedir}/sched.h
139 %{_includedir}/semaphore.h
142 %defattr(644,root,root,755)
143 %{_libdir}/libpthreadGC2.a
144 %{_libdir}/libpthread.a
147 %defattr(644,root,root,755)
148 %{_dlldir}/pthreadGC2.dll
149 %{_dlldir}/pthreadGCE2.dll