summaryrefslogtreecommitdiff
path: root/packaging/libeom.spec
blob: 8e385efd8c2924008affc1441d722494d775d054 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
%bcond_with utest

Name: libeom
Summary: External Output Manager Library
Version: 1.0.5
Release: 1
Group: Graphics & UI Framework/Wayland Window System
License: MIT
Source0: %{name}-%{version}.tar.gz
Source1001:	%name.manifest

BuildRequires:  pkgconfig(wayland-client)
BuildRequires:  pkgconfig(ecore-wayland)
BuildRequires:  pkgconfig(xdg-shell-client)
BuildRequires:  pkgconfig(xdg-shell-server)
BuildRequires:  pkgconfig(dlog)
BuildRequires:  pkgconfig(glib-2.0)
BuildRequires:  pkgconfig(gio-unix-2.0)
BuildRequires:  pkgconfig(capi-base-common)
BuildRequires:  pkgconfig(elementary)

%if %{with utest}
BuildRequires:  gtest-devel
%endif

%description
This package provides the runtime library to manage External Output

%package devel
Summary: EOM Library development package
Group: Development/Libraries
Requires: %{name} = %{version}-%{release}
Requires: pkgconfig(capi-base-common)

%description devel
External Output Manager Library development package

%package -n libeom-server
Summary: EOM Server Library
Group: Development/Libraries

%description -n libeom-server
External Output Manager Server Library

%package -n libeom-server-devel
Summary: EOM Server Library development package
Group: Development/Libraries
Requires: libeom-server = %{version}

%description -n libeom-server-devel
External Output Manager Server Library development package

%global TZ_SYS_RO_SHARE  %{?TZ_SYS_RO_SHARE:%TZ_SYS_RO_SHARE}%{!?TZ_SYS_RO_SHARE:/usr/share}

%prep
%setup -q
cp %{SOURCE1001} .

%build
export CFLAGS="-g -O0 -Wall -Werror -Wno-error=deprecated-declarations"
export LDFLAGS="$LDFLAGS -Wl,--hash-style=both -Wl,--as-needed"
UTEST="no"

%if %{with utest}
UTEST="yes"
%endif

%reconfigure --disable-dlog --disable-static --with-utest=${UTEST}

make %{?_smp_mflags}

%if %{with utest}
make -C ut check
%endif

%install
rm -rf %{buildroot}
mkdir -p %{buildroot}/usr/include
cp src/eom-server-protocol.h %{buildroot}/usr/include
%make_install

%remove_docs

%post -p /sbin/ldconfig
%postun -p /sbin/ldconfig

%post -n libeom-server -p /sbin/ldconfig
%postun -n libeom-server -p /sbin/ldconfig

%files
%manifest %{name}.manifest
%defattr(-,root,root,-)
%license COPYING
%{_libdir}/libeom.so.*
%if %{with utest}
%{_bindir}/ut
%endif

%files devel
%manifest %{name}.manifest
%dir %{_includedir}/eom/
%{_includedir}/eom/*.h
%{_libdir}/libeom.so
%{_libdir}/pkgconfig/eom.pc

%files -n libeom-server
%manifest %{name}.manifest
%defattr(-,root,root,-)
%license COPYING
%{_includedir}/eom-server-protocol.h
%{_includedir}/eom/eom.h
%{_libdir}/libeom-server-protocol.so.*

%files -n libeom-server-devel
%manifest %{name}.manifest
%dir %{_includedir}/eom/
%{_includedir}/eom-server-protocol.h
%{_includedir}/eom/eom.h
%{_libdir}/libeom-server-protocol.so
%{_libdir}/pkgconfig/eom-server.pc