]> git.pld-linux.org Git - packages/crossmingw32-pthreads-w32.git/blame - crossmingw32-pthreads-w32.spec
- new
[packages/crossmingw32-pthreads-w32.git] / crossmingw32-pthreads-w32.spec
CommitLineData
0c2c9674
JB
1Summary: POSIX Threads component implementation for Win32 - MinGW32 cross version
2Summary(pl.UTF-8): Implementacja komponentu POSIX Threads dla Win32 - wersja skrośna dla MinGW32
3Name: crossmingw32-pthreads-w32
4Version: 2.9.1
5%define dver %(echo %{version} | tr . -)
6Release: 1
7License: LGPL v2.1
8Group: Development/Libraries
9Source0: ftp://sourceware.org/pub/pthreads-win32/pthreads-w32-%{dver}-release.tar.gz
10# Source0-md5: 36ba827d6aa0fa9f9ae740a35626e2e3
11URL: http://www.sourceware.org/pthreads-win32/
12BuildRequires: crossmingw32-gcc
13BuildRequires: sed >= 4.0
14Requires: crossmingw32-runtime
15BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
16
17%define no_install_post_strip 1
18
19%define target i386-mingw32
20%define target_platform i386-pc-mingw32
21
22%define _sysprefix /usr
23%define _prefix %{_sysprefix}/%{target}
24%define _libdir %{_prefix}/lib
25%define _dlldir /usr/share/wine/windows/system
26%define __cc %{target}-gcc
27%define __cxx %{target}-g++
28
29%ifarch alpha sparc sparc64 sparcv9
30%define optflags -O2
31%endif
32
33# -z options are invalid for mingw linker, most of -f options are Linux-specific
34%define filterout_ld -Wl,-z,.*
35%define filterout_c -f[-a-z0-9=]*
36
37%description
38Pthreads-win32 is an Open Source Software implementation of the
39Threads component of the POSIX 1003.1c 1995 Standard for Microsoft's
40Win32 environment. Some functions from POSIX 1003.1b are also
41supported including semaphores. Other related functions include the
42set of read-write lock functions. The library also supports some of
43the functionality of the Open Group's Single Unix specification,
44version 2, namely mutex types.
45
46This package contains the cross version for Win32.
47
48%description -l pl.UTF-8
49PThreads-win32 to mająca otwarte źródła implementacja komponentu
50Threads (wątków) ze specyfikacji standardu POSIX 1003.1c z 1995 roku
51dla środowiska Win32 Microsoftu. Obsługiwane są także niektóre funkcje
52z POSIX 1003.1b, w tym semafory. Inne powiązane funkcje to zbiór
53funkcji blokad r/w. Biblioteka obsługuje także część funkcjonalności
54specyfikacji Single Unix w wersji 2 wydanej przez Open Group, a
55konkretnie typy mutex.
56
57Ten pakiet zawiera wersję skrośną dla Win32.
58
59%package static
60Summary: Static POSIX Threads library (cross MinGW32 version)
61Summary(pl.UTF-8): Statyczna biblioteka POSIX Threads (wersja skrośna MinGW32)
62Group: Development/Libraries
63Requires: %{name} = %{version}-%{release}
64
65%description static
66Static POSIX Threads library (cross MinGW32 version).
67
68%description static -l pl.UTF-8
69Statyczna biblioteka POSIX Threads (wersja skrośna MinGW32).
70
71%package dll
72Summary: POSIX Threads - DLL library for Windows
73Summary(pl.UTF-8): POSIX Threads - biblioteka DLL dla Windows
74Group: Applications/Emulators
75Requires: wine
76
77%description dll
78POSIX Threads - DLL library for Windows.
79
80%description dll -l pl.UTF-8
81POSIX Threads - biblioteka DLL dla Windows.
82
83%prep
84%setup -q -n pthreads-w32-%{dver}-release
85
86mkdir lib
87
88%build
89for type in GC-inlined GCE-inlined GC-static ; do
90%{__make} clean
91%{__make} $type \
92 CROSS="%{target}-" \
93 CC="%{__cc}" \
94 CXX="%{__cxx}" \
95 OPT='%{rpmcflags} $(CLEANUP)'
96
97case "$type" in
98 GC-inlined)
99 %{__mv} libpthreadGC2.a lib/libpthreadGC2.dll.a
100 %{__mv} pthreadGC2.dll lib
101 ;;
102 GCE-inlined)
103 %{__mv} libpthreadGCE2.a lib/libpthreadGCE2.dll.a
104 %{__mv} pthreadGCE2.dll lib
105 ;;
106 GC-static)
107 %{__mv} libpthreadGC2.a lib
108esac
109done
110
111%if 0%{!?debug:1}
112%{target}-strip -R.comment -R.note lib/*.dll
113%{target}-strip -g -R.comment -R.note lib/*.a
114%endif
115
116%install
117rm -rf $RPM_BUILD_ROOT
118install -d $RPM_BUILD_ROOT{%{_libdir},%{_includedir},%{_dlldir}}
119
120install lib/*.dll $RPM_BUILD_ROOT%{_dlldir}
121install lib/*.a $RPM_BUILD_ROOT%{_libdir}
122ln -s libpthreadGC2.dll.a $RPM_BUILD_ROOT%{_libdir}/libpthread.dll.a
123ln -s libpthreadGC2.a $RPM_BUILD_ROOT%{_libdir}/libpthread.a
124cp -p pthread.h sched.h semaphore.h $RPM_BUILD_ROOT%{_includedir}
125
126%clean
127rm -rf $RPM_BUILD_ROOT
128
129%files
130%defattr(644,root,root,755)
131%doc ANNOUNCE BUGS CONTRIBUTORS COPYING ChangeLog FAQ MAINTAINERS NEWS PROGRESS README README.CV README.NONPORTABLE TODO
132%{_libdir}/libpthread.dll.a
133%{_libdir}/libpthreadGC2.dll.a
134%{_libdir}/libpthreadGCE2.dll.a
135%{_includedir}/pthread.h
136%{_includedir}/sched.h
137%{_includedir}/semaphore.h
138
139%files static
140%defattr(644,root,root,755)
141%{_libdir}/libpthreadGC2.a
142%{_libdir}/libpthread.a
143
144%files dll
145%defattr(644,root,root,755)
146%{_dlldir}/pthreadGC2.dll
147%{_dlldir}/pthreadGCE2.dll
This page took 0.100204 seconds and 4 git commands to generate.