Apply directory macros
authorSung-Jin Park <sj76.park@samsung.com>
Fri, 11 Mar 2016 02:47:07 +0000 (11:47 +0900)
committerSung-Jin Park <sj76.park@samsung.com>
Fri, 20 Oct 2017 04:28:22 +0000 (13:28 +0900)
Change-Id: I2e082b618708edaf8a5558bc423ae30b8ec321ef

packaging/libevdev.spec

index 31c3602acd512f9e95681a65a0cd7c7868883dfb..541b0f2307596faee22ccb65c9e12546ae6b334c 100644 (file)
@@ -12,6 +12,7 @@ BuildRequires:  doxygen
 BuildRequires:  make
 BuildRequires:  python
 
+%global TZ_SYS_RO_SHARE  %{?TZ_SYS_RO_SHARE:%TZ_SYS_RO_SHARE}%{!?TZ_SYS_RO_SHARE:/usr/share}
 
 %description
 libevdev is a wrapper library for evdev devices. it moves the common
@@ -41,6 +42,10 @@ make %{?jobs:-j%jobs} V=1
 %make_install
 #%fdupes %{buildroot}
 
+# for license notification
+mkdir -p %{buildroot}/%{TZ_SYS_RO_SHARE}/license
+cp -a %{_builddir}/%{buildsubdir}/COPYING %{buildroot}/%{TZ_SYS_RO_SHARE}/license/%{name}
+
 %post -p /sbin/ldconfig
 
 %postun -p /sbin/ldconfig
@@ -49,6 +54,7 @@ make %{?jobs:-j%jobs} V=1
 %files
 %manifest %{name}.manifest
 %defattr(-,root,root)
+%{TZ_SYS_RO_SHARE}/license/%{name}
 %{_bindir}/touchpad-edge-detector
 %{_libdir}/*.so.*
 %{_datadir}/*