source: spec/trunk/SPECS/libcx.spec@ 1010

Last change on this file since 1010 was 929, checked in by dmik, 9 years ago

spec: libcx: Release version 0.4.1-1.

File size: 3.3 KB
Line 
1Name: libcx
2Summary: kLIBC Extension Library
3Version: 0.4.1
4Release: 1%{?dist}
5License: LGPLv2.1+
6Group: System/Libraries
7Vendor: bww bitwise works GmbH
8URL: https://github.com/bitwiseworks/libcx
9
10%define github_name libcx
11%define github_url https://github.com/bitwiseworks/%{github_name}/archive
12%define github_rev %{version}
13
14Source: %{github_name}-%{github_rev}.zip
15
16BuildRequires: gcc make curl zip
17
18Obsoletes: libpoll
19Provides: libpoll
20
21%description
22The kLIBC Extension Library extends the functionality of the kLIBC library
23by adding a number of high demand features required by modern applications.
24
25%package devel
26Summary: Development package for %{name}
27Requires: %{name} = %{version}-%{release}
28Requires: libc-devel exceptq-devel
29Requires: pkgconfig
30
31Obsoletes: libpoll-devel
32Provides: libpoll-devel
33
34%description devel
35Libraries, header files and documentation for %{name}.
36
37%debug_package
38
39%prep
40%if %(sh -c 'if test -f "%{_sourcedir}/%{github_name}-%{github_rev}.zip" ; then echo 1 ; else echo 0 ; fi')
41%setup -n "%{github_name}-%{github_rev}" -q
42%else
43%setup -n "%{github_name}-%{github_rev}" -Tc
44rm -f "%{_sourcedir}/%{github_name}-%{github_rev}.zip"
45curl -sSL "%{github_url}/%{github_rev}.zip" -o "%{_sourcedir}/%{github_name}-%{github_rev}.zip"
46unzip "%{_sourcedir}/%{github_name}-%{github_rev}.zip" -d ..
47%endif
48
49%define kmk_env \
50 KMK_FLAGS="\
51 KBUILD_VERBOSE=2 \
52 BUILD_TYPE=release \
53 INST_PREFIX=%{_prefix}"
54
55%build
56CFLAGS="$RPM_OPT_FLAGS"
57LDFLAGS="-Zhigh-mem"
58%{kmk_env}
59kmk $KMK_FLAGS CFLAGS="$CFLAGS" LDFLAGS="$LDFLAGS"
60
61%install
62rm -rf %{buildroot}
63%{kmk_env}
64kmk $KMK_FLAGS DESTDIR="%{buildroot}" install
65# Remove tests as we don't need them now
66rm -rf %{buildroot}%{_bindir}/tst-*.exe
67# Copy headers (@todo move it to Makefile.kmk)
68mkdir -p %{buildroot}%{_includedir}/sys
69echo "#include <sys/poll.h>" > nosys_poll.h
70install -m 644 nosys_poll.h %{buildroot}%{_includedir}/poll.h
71install -m 644 src/poll/poll.h %{buildroot}%{_includedir}/sys
72install -m 644 src/mmap/sys/mman.h %{buildroot}%{_includedir}/sys
73
74%clean
75rm -rf %{buildroot}
76
77%files
78%defattr(-,root,root)
79%doc LICENSE README.md CHANGELOG.md
80%{_libdir}/libcx*.dll
81
82%files devel
83%defattr(-,root,root)
84%{_libdir}/libcx*.a
85%{_bindir}/libcx-stats.exe
86%{_includedir}/poll.h
87%{_includedir}/sys/poll.h
88%{_includedir}/sys/mman.h
89
90%changelog
91* Wed Jan 18 2017 Dmitriy Kuminov <coding@dmik.org> 0.4.1-1
92- Release version 0.4.1
93 (https://github.com/bitwiseworks/libcx/blob/0.4.1/CHANGELOG.md).
94
95* Thu Nov 24 2016 Dmitriy Kuminov <coding@dmik.org> 0.4-1
96- Release version 0.4
97 (https://github.com/bitwiseworks/libcx/blob/0.4/CHANGELOG.md).
98
99* Mon Sep 26 2016 Dmitriy Kuminov <coding@dmik.org> 0.3.1-1
100- Release version 0.3.1
101 (https://github.com/bitwiseworks/libcx/blob/0.3.1/CHANGELOG.md).
102
103* Thu Sep 22 2016 Dmitriy Kuminov <coding@dmik.org> 0.3-1
104- Release version 0.3
105 (https://github.com/bitwiseworks/libcx/blob/0.3/CHANGELOG.md).
106
107* Fri Aug 19 2016 Dmitriy Kuminov <coding@dmik.org> 0.2.1-1
108- Release version 0.2.1
109 (https://github.com/bitwiseworks/libcx/blob/0.2.1/CHANGELOG.md).
110
111* Mon Jul 18 2016 Dmitriy Kuminov <coding@dmik.org> 0.2-1
112- Release version 0.2
113 (https://github.com/bitwiseworks/libcx/blob/0.2/CHANGELOG.md).
114
115* Fri Jun 10 2016 Dmitriy Kuminov <coding@dmik.org> 0.1-1
116- Initial package for version 0.1.
Note: See TracBrowser for help on using the repository browser.