source: spec/trunk/SPECS/libkai.spec@ 587

Last change on this file since 587 was 576, checked in by dmik, 10 years ago

spec: libkai: Release 1.1.4-1.

File size: 2.6 KB
Line 
1# The default OS/2 Toolkit path, use --define to override on the command line
2%if %{undefined os2_toolkit_path}
3%define os2_toolkit_path D:/Tools/OS2TK45
4%endif
5
6Summary: K Audio Interface library for OS/2 multimedia subsystem
7Name: libkai
8Version: 1.1.4
9Release: 1%{?dist}
10License: LGPLv2+
11Group: System Environment/Libraries
12
13%define github_name kai
14%define github_url https://github.com/komh/%{github_name}/archive
15%define github_rev kai-%{version}
16
17Source: %{github_name}-%{github_rev}.zip
18
19BuildRequires: gcc make curl zip
20
21%description
22K Audio Interface is a frontend library that simplifies access to OS/2
23audio hardware making it easier to write programs that play sounds.
24Currently, it supports playing sounds through the standard OS/2
25MMPM/DART subsystem and through the UNIAUD driver directly.
26
27%package devel
28Summary: K Audio Interface developer package
29Group: Development/Libraries
30Requires: libkai = %{version}-%{release}
31
32%description devel
33Contains headers and libraries necessary to compile audio-enabled
34applications that use K Audio Interface.
35
36%package static
37Summary: K Audio Interface static library
38Group: Development/Libraries
39Requires: libkai-devel = %{version}-%{release}
40
41%description static
42Contains headers the static K Audio Interface library.
43
44%package debug
45Summary: HLL debug data for libkai
46Requires: libkai = %{version}-%{release}
47
48%description debug
49Contains symbol files necessary to generate proper crash reports
50in applications using the libkai package.
51
52%prep
53%if %(sh -c 'if test -f "%{_sourcedir}/%{github_name}-%{github_rev}.zip" ; then echo 1 ; else echo 0 ; fi')
54%setup -n "%{github_name}-%{github_rev}" -q
55%else
56%setup -n "%{github_name}-%{github_rev}" -Tc
57rm -f "%{_sourcedir}/%{github_name}-%{github_rev}.zip"
58curl -sSL "%{github_url}/%{github_rev}.zip" -o "%{_sourcedir}/%{github_name}-%{github_rev}.zip"
59unzip "%{_sourcedir}/%{github_name}-%{github_rev}.zip" -d ..
60%endif
61
62%build
63make PREFIX=%{_prefix} CC="gcc -idirafter %{os2_toolkit_path}/h -DOS2EMX_PLAIN_CHAR"
64
65%install
66make PREFIX=%{_prefix} INSTALL=%{_bindir}/install DESTDIR=%{buildroot} install
67# No need in .a once we have .lib
68rm -f %{buildroot}/%{_libdir}/*.a
69
70%clean
71rm -rf %{buildroot}
72
73%files
74%defattr(-,root,root)
75%{_libdir}/*.dll
76
77%files devel
78%defattr(-,root,root)
79%{_includedir}/*.h
80%{_libdir}/*_dll.lib
81
82%files static
83%defattr(-,root,root)
84%exclude %{_libdir}/*_dll.lib
85%{_libdir}/*.lib
86
87%files debug
88%defattr(-,root,root)
89%{_libdir}/*.dbg
90
91%changelog
92* Wed Jul 1 2015 Dmitriy Kuminov <coding@dmik.org> 1.1.4-1
93- Initial package for version 1.1.4.
Note: See TracBrowser for help on using the repository browser.