Adding spec file for gbs build.
[platform/upstream/dbus.git] / packaging / com.samsung.dbus.spec
1 Name:           com.samsung.dbus
2 Summary:        D-Bus message bus with kdbus support
3 Version:        1.7.5
4 Release:        0
5 Group:          System/Libraries
6 License:        GPLv2+ or AFL
7 Source0:        %{name}-%{version}.tar.gz
8 BuildRequires:  which
9 BuildRequires:  expat-devel
10 BuildRequires:  libtool
11 BuildRequires:  openssl-devel
12 BuildRequires:  pkgconfig(x11)
13
14
15 %description
16 D-Bus message bus with kdbus support
17
18 %prep
19 %setup -q -n %{name}-%{version}
20
21
22 %build
23 ./autogen.sh --enable-abstract-sockets --enable-x11-autolaunch --with-x
24
25 # When compiled using gbs with --enable-abstract-sockets param autogen.sh creates a config.h in
26 # /GBS-ROOT/local/BUILD-ROOTS/scratch.armv7l.0 with # /* #undef HAVE_ABSTRACT_SOCKETS */.
27 # Code changes it to #define HAVE_ABSTRACT_SOCKETS 1.
28 if grep -q "#define HAVE_ABSTRACT_SOCKETS\s1" config.h; then
29         echo HAVE_ABSTRACT_SOCKETS found.
30 else
31         echo HAVE_ABSTRACT_SOCKETS not found. Adding it.
32         sed -i 's/\/\* #undef HAVE_ABSTRACT_SOCKETS \*\//#define HAVE_ABSTRACT_SOCKETS 1/' config.h
33 fi
34
35 make %{?jobs:-j%jobs}
36
37 %install
38
39 %post
40 mkdir -p /opt/var/lib/dbus
41
42
43 %files
44