]>
Commit | Line | Data |
---|---|---|
d9686636 | 1 | # |
2 | # Conditional build: | |
3 | %bcond_without static_libs # don't build static library | |
a9f7cd23 | 4 | |
d9686636 | 5 | Summary: Implementation of W3C DOM |
89960186 | 6 | Summary(pl.UTF-8): Implementacja W3C DOM |
d9686636 | 7 | Name: libdom |
daeb5617 | 8 | Version: 0.3.1 |
f4771f8e | 9 | Release: 1 |
d9686636 | 10 | License: MIT |
11 | Group: Libraries | |
12 | Source0: http://download.netsurf-browser.org/libs/releases/%{name}-%{version}-src.tar.gz | |
daeb5617 | 13 | # Source0-md5: c9dbc908997bb4bd2271b4ee892280aa |
d9686636 | 14 | URL: http://www.netsurf-browser.org/projects/libdom/ |
89960186 | 15 | BuildRequires: expat-devel >= 1.95 |
e57f53fb WF |
16 | BuildRequires: libhubbub-devel >= 0.3.3 |
17 | BuildRequires: libparserutils-devel >= 0.2.3 | |
18 | BuildRequires: libwapcaplet-devel >= 0.3.0 | |
89960186 | 19 | BuildRequires: libxml2-devel >= 2.0 |
e57f53fb | 20 | BuildRequires: netsurf-buildsystem >= 1.5 |
89960186 | 21 | BuildRequires: pkgconfig |
e57f53fb WF |
22 | Requires: libparserutils >= 0.2.3 |
23 | Requires: libwapcaplet >= 0.3.0 | |
d9686636 | 24 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) |
25 | ||
26 | %description | |
27 | LibDOM is an implementation of the W3C DOM, written in C. It is | |
28 | currently in development for use with NetSurf and is intended to be | |
29 | suitable for use in other projects too. | |
30 | ||
89960186 JB |
31 | %description -l pl.UTF-8 |
32 | LibDOM to implementacja W3C DOM, napisana w C. Jest rozwijana do | |
33 | wykorzystania w ramach projektu NetSurf, ale także z myślą o | |
34 | możliwości użycia w innych projektach. | |
35 | ||
d9686636 | 36 | %package devel |
37 | Summary: libdom library headers | |
38 | Summary(pl.UTF-8): Pliki nagłówkowe biblioteki libdom | |
39 | Group: Development/Libraries | |
40 | Requires: %{name} = %{version}-%{release} | |
16a44712 JB |
41 | Requires: expat-devel >= 1.95 |
42 | Requires: libhubbub-devel >= 0.3.1 | |
d9686636 | 43 | |
44 | %description devel | |
89960186 JB |
45 | This package contains the include files and other resources you can |
46 | use to incorporate libdom into applications. | |
d9686636 | 47 | |
48 | %description devel -l pl.UTF-8 | |
49 | Pliki nagłówkowe pozwalające na używanie biblioteki libdom w swoich | |
50 | programach. | |
51 | ||
52 | %package static | |
89960186 JB |
53 | Summary: libdom static library |
54 | Summary(pl.UTF-8): Statyczna biblioteka libdom | |
d9686636 | 55 | Group: Development/Libraries |
56 | Requires: %{name}-devel = %{version}-%{release} | |
57 | ||
58 | %description static | |
89960186 | 59 | This is package with static libdom library. |
d9686636 | 60 | |
61 | %description static -l pl.UTF-8 | |
62 | Statyczna biblioteka libdom. | |
63 | ||
64 | %prep | |
65 | %setup -q | |
66 | ||
67 | %build | |
e57f53fb | 68 | export AR="%{__ar}" |
a9f7cd23 ER |
69 | export CC="%{__cc}" |
70 | export CFLAGS="%{rpmcflags}" | |
71 | export LDFLAGS="%{rpmldflags}" | |
72 | ||
89960186 JB |
73 | %{__make} \ |
74 | Q= \ | |
a9f7cd23 | 75 | PREFIX=%{_prefix} \ |
89960186 | 76 | LIBDIR=%{_lib} \ |
a9f7cd23 | 77 | COMPONENT_TYPE=lib-shared |
d9686636 | 78 | |
d9686636 | 79 | %if %{with static_libs} |
89960186 JB |
80 | %{__make} \ |
81 | Q= \ | |
a9f7cd23 | 82 | PREFIX=%{_prefix} \ |
89960186 | 83 | LIBDIR=%{_lib} \ |
a9f7cd23 | 84 | COMPONENT_TYPE=lib-static |
d9686636 | 85 | %endif |
86 | ||
87 | %install | |
c8590f8b JB |
88 | rm -rf $RPM_BUILD_ROOT |
89 | ||
e57f53fb WF |
90 | export AR="%{__ar}" |
91 | export CC="%{__cc}" | |
92 | export CFLAGS="%{rpmcflags}" | |
93 | export LDFLAGS="%{rpmldflags}" | |
94 | ||
89960186 JB |
95 | %{__make} install \ |
96 | Q= \ | |
d9686636 | 97 | PREFIX=%{_prefix} \ |
89960186 | 98 | LIBDIR=%{_lib} \ |
d9686636 | 99 | COMPONENT_TYPE=lib-shared \ |
a9f7cd23 | 100 | DESTDIR=$RPM_BUILD_ROOT |
d9686636 | 101 | |
102 | %if %{with static_libs} | |
89960186 JB |
103 | %{__make} install \ |
104 | Q= \ | |
d9686636 | 105 | PREFIX=%{_prefix} \ |
89960186 | 106 | LIBDIR=%{_lib} \ |
d9686636 | 107 | COMPONENT_TYPE=lib-static \ |
a9f7cd23 | 108 | DESTDIR=$RPM_BUILD_ROOT |
d9686636 | 109 | %endif |
110 | ||
111 | %clean | |
112 | rm -rf $RPM_BUILD_ROOT | |
113 | ||
114 | %post -p /sbin/ldconfig | |
115 | %postun -p /sbin/ldconfig | |
116 | ||
117 | %files | |
118 | %defattr(644,root,root,755) | |
89960186 | 119 | %doc COPYING README |
e1de32bc | 120 | %attr(755,root,root) %{_libdir}/libdom.so.*.*.* |
89960186 | 121 | %attr(755,root,root) %ghost %{_libdir}/libdom.so.0 |
d9686636 | 122 | |
123 | %files devel | |
124 | %defattr(644,root,root,755) | |
89960186 | 125 | %attr(755,root,root) %{_libdir}/libdom.so |
d9686636 | 126 | %{_includedir}/dom |
e1de32bc | 127 | %{_pkgconfigdir}/libdom.pc |
d9686636 | 128 | |
129 | %if %{with static_libs} | |
130 | %files static | |
131 | %defattr(644,root,root,755) | |
e1de32bc | 132 | %{_libdir}/libdom.a |
d9686636 | 133 | %endif |