ADD_DEFINITIONS("-DEDJDIR=\"${EDJDIR}\"")
ADD_DEFINITIONS("-DLANGDIR=\"${LANGDIR}\"")
+IF(WAYLAND_SUPPORT)
+ ADD_DEFINITIONS("-DWAYLAND")
+ENDIF(WAYLAND_SUPPORT)
+
ADD_LIBRARY(${PROJECT_NAME} SHARED ${SRCS})
SET_TARGET_PROPERTIES(${PROJECT_NAME} PROPERTIES SOVERSION 0.1.0)
TARGET_LINK_LIBRARIES(${PROJECT_NAME} ${pkgs_LDFLAGS})
+%bcond_with wayland
+
Name: ug-setting-location-efl
Summary: UG setting location EFL
Version: 0.3.46
BuildRequires: pkgconfig(capi-location-manager)
BuildRequires: edje-bin
BuildRequires: cmake
-BuildRequires: gettext-tools
+BuildRequires: gettext-tools
Requires(post): /sbin/ldconfig
Requires(post): /usr/bin/vconftool
requires(postun): /sbin/ldconfig
%build
export LDFLAGS+="-Wl,--rpath=%{_prefix}/lib -Wl,--as-needed -Wl,--hash-style=both"
-LDFLAGS="$LDFLAGS" cmake . -DCMAKE_INSTALL_PREFIX=%{_prefix}
+LDFLAGS="$LDFLAGS" %cmake . -DCMAKE_INSTALL_PREFIX=%{_prefix} \
+%if %{with wayland}
+ -DWAYLAND_SUPPORT=On
+%else
+ -DWAYLAND_SUPPORT=Off
+%endif
make %{?jobs:-j%jobs}
%make_install
-%post
+%post
/sbin/ldconfig
mkdir -p /usr/ug/bin/
mkdir -p /usr/ug/res/locale/