From 87270b3a3363ce58f9915d103adb6c31faebad66 Mon Sep 17 00:00:00 2001 From: JengHyun Kang Date: Mon, 20 Mar 2017 18:50:15 +0900 Subject: [PATCH] keyrouter: build/enable pepper-keyrouter packaging Change-Id: I86e424c9fbe80db7a020a5ebdd7e2f8407e00ef5 --- Makefile.am | 1 + configure.ac | 16 ++++++++++++++++ packaging/pepper.spec | 32 ++++++++++++++++++++++++++++++++ pkgconfig/pepper-keyrouter.pc.in | 14 ++++++++++++++ src/Makefile.am | 1 + src/lib/keyrouter/Makefile.am | 13 +++++++++++++ 6 files changed, 77 insertions(+) create mode 100644 pkgconfig/pepper-keyrouter.pc.in create mode 100644 src/lib/keyrouter/Makefile.am diff --git a/Makefile.am b/Makefile.am index 8c39810..64f278c 100644 --- a/Makefile.am +++ b/Makefile.am @@ -11,6 +11,7 @@ if ENABLE_TDM pkgconfig_DATA += pkgconfig/pepper-tdm.pc endif pkgconfig_DATA += pkgconfig/pepper-fbdev.pc +pkgconfig_DATA += pkgconfig/pepper-keyrouter.pc pkgconfig_DATA += pkgconfig/pepper-evdev.pc pkgconfig_DATA += pkgconfig/pepper-libinput.pc pkgconfig_DATA += pkgconfig/pepper-wayland.pc diff --git a/configure.ac b/configure.ac index 319b220..42dbefc 100644 --- a/configure.ac +++ b/configure.ac @@ -54,6 +54,20 @@ if test x$enable_socket_fd = xyes; then AC_DEFINE([ENABLE_SOCKET_FD], [1], [Use wl_display_add_socket_fd]) fi +# pepper-keyrouter +PEPPER_KEYROUTER_REQUIRES="tizen-extension-server" +PKG_CHECK_MODULES(PEPPER_KEYROUTER, [$PEPPER_KEYROUTER_REQUIRES]) + +PEPPER_KEYROUTER_DIR="-I\$(top_srcdir)/src/lib/keyrouter" +PEPPER_KEYROUTER_LIB="\$(top_srcdir)/src/lib/keyrouter/libpepper-keyrouter.la" + +PEPPER_KEYROUTER_CFLAGS="$PEPPER_DIR $PEPPER_KEYROUTER_CFLAGS $PEPPER_CFLAGS $PEPPER_KEYROUTER_DIR" +PEPPER_KEYROUTER_LIBS="$PEPPER_LIB $PEPPER_KEYROUTER_LIBS" + +AC_SUBST(PEPPER_KEYROUTER_CFLAGS) +AC_SUBST(PEPPER_KEYROUTER_LIBS) +AC_SUBST(PEPPER_KEYROUTER_REQUIRES) + # pepper-libinput PEPPER_LIBINPUT_REQUIRES="libinput" PKG_CHECK_MODULES(PEPPER_LIBINPUT, [$PEPPER_LIBINPUT_REQUIRES]) @@ -281,6 +295,7 @@ AC_CONFIG_FILES([ Makefile src/Makefile src/lib/pepper/Makefile +src/lib/keyrouter/Makefile src/lib/evdev/Makefile src/lib/libinput/Makefile src/lib/desktop-shell/Makefile @@ -294,6 +309,7 @@ pkgconfig/pepper.pc pkgconfig/pepper-render.pc pkgconfig/pepper-drm.pc pkgconfig/pepper-fbdev.pc +pkgconfig/pepper-keyrouter.pc pkgconfig/pepper-evdev.pc pkgconfig/pepper-libinput.pc pkgconfig/pepper-wayland.pc diff --git a/packaging/pepper.spec b/packaging/pepper.spec index 059e604..2f1eca4 100644 --- a/packaging/pepper.spec +++ b/packaging/pepper.spec @@ -27,6 +27,7 @@ BuildRequires: doxygen BuildRequires: pkgconfig(wayland-tbm-client) BuildRequires: pkgconfig(wayland-tbm-server) BuildRequires: pkgconfig(libtbm) +BuildRequires: pkgconfig(tizen-extension-server) %if "%{ENABLE_TDM}" == "1" BuildRequires: pkgconfig(libtdm) %endif @@ -42,6 +43,21 @@ Requires: %{name} = %{version}-%{release} %description devel This package includes developer files common to all packages. +###### keyrouter +%package keyrouter +Summary: Keyrouter module for pepper package + +%description keyrouter +This package includes keyrouter module files. + +###### keyrouter-devel +%package keyrouter-devel +Summary: Keyrouter development module for pepper package +Requires: pepper-keyrouter = %{version}-%{release} + +%description keyrouter-devel +This package includes keyrouter development module files. + ###### evdev %package evdev Summary: evdev module for pepper package @@ -192,6 +208,9 @@ make %{?_smp_mflags} %post -n %{name} -p /sbin/ldconfig %postun -n %{name} -p /sbin/ldconfig +%post keyrouter -p /sbin/ldconfig +%postun keyrouter -p /sbin/ldconfig + %post evdev -p /sbin/ldconfig %postun evdev -p /sbin/ldconfig @@ -230,6 +249,19 @@ make %{?_smp_mflags} %{_libdir}/pkgconfig/pepper.pc %{_libdir}/libpepper.so +%files keyrouter +%manifest %{name}.manifest +%defattr(-,root,root,-) +%{_libdir}/libpepper-keyrouter.so.* + +%files keyrouter-devel +%manifest %{name}.manifest +%defattr(-,root,root,-) +%{_includedir}/pepper/keyrouter.h +%{_includedir}/pepper/pepper-keyrouter.h +%{_libdir}/pkgconfig/pepper-keyrouter.pc +%{_libdir}/libpepper-keyrouter.so + %files evdev %manifest %{name}.manifest %defattr(-,root,root,-) diff --git a/pkgconfig/pepper-keyrouter.pc.in b/pkgconfig/pepper-keyrouter.pc.in new file mode 100644 index 0000000..3630247 --- /dev/null +++ b/pkgconfig/pepper-keyrouter.pc.in @@ -0,0 +1,14 @@ +prefix=@prefix@ +exec_prefix=@exec_prefix@ +libdir=@libdir@ +includedir=@includedir@ +libexecdir=@libexecdir@ +pkglibexecdir=${libexecdir}/@PACKAGE@ + +Name: Pepper Keyrouter Library +Description: Pepper Keyrouter library header and library files +Version: @PEPPER_KEYROUTER_VERSION@ + +Requires.private: @PEPPER_KEYROUTER_REQUIRES@ +Cflags: -I${includedir}/pepper +Libs: -L${libdir} -lpepper-keyrouter diff --git a/src/Makefile.am b/src/Makefile.am index 9438861..b918f09 100644 --- a/src/Makefile.am +++ b/src/Makefile.am @@ -1,4 +1,5 @@ SUBDIRS = lib/pepper \ + lib/keyrouter \ lib/evdev \ lib/libinput \ lib/desktop-shell \ diff --git a/src/lib/keyrouter/Makefile.am b/src/lib/keyrouter/Makefile.am new file mode 100644 index 0000000..fe36aff --- /dev/null +++ b/src/lib/keyrouter/Makefile.am @@ -0,0 +1,13 @@ +lib_LTLIBRARIES = libpepper-keyrouter.la + +AM_CFLAGS = $(GCC_CFLAGS) + +libpepper_keyrouter_includedir=$(includedir)/pepper +libpepper_keyrouter_include_HEADERS = keyrouter.h pepper-keyrouter.h + +libpepper_keyrouter_la_CFLAGS = $(AM_CFLAGS) $(PEPPER_KEYROUTER_CFLAGS) +libpepper_keyrouter_la_LIBADD = $(PEPPER_KEYROUTER_LIBS) + +libpepper_keyrouter_la_SOURCES = keyrouter-internal.h \ + keyrouter.c \ + pepper-keyrouter.c -- 2.7.4