Merge branch 'tizen_5.0' into tizen_5.5
[platform/core/api/webapi-plugins.git] / packaging / webapi-plugins.spec
index 46a3a04..6ea6edb 100644 (file)
@@ -6,9 +6,11 @@
 %define crosswalk_extensions tizen-extensions-crosswalk
 
 %define crosswalk_extensions_path %{_libdir}/%{crosswalk_extensions}
+%define tizen_ut_build 0
+
 
 Name:       webapi-plugins
-Version:    2.44
+Version:    2.57
 Release:    0
 License:    Apache-2.0 and BSD-3-Clause and MIT
 Group:      Development/Libraries
@@ -689,6 +691,9 @@ GYP_OPTIONS="--depth=. -Dtizen=1 -Dextension_build_type=Debug -Dextension_host_o
 GYP_OPTIONS="$GYP_OPTIONS -Ddisplay_type=%{display_type}"
 GYP_OPTIONS="$GYP_OPTIONS -Dcrosswalk_extensions_path=%{crosswalk_extensions_path}"
 
+# ut flags
+GYP_OPTIONS="$GYP_OPTIONS -Dtizen_ut_build=%{tizen_ut_build}"
+
 # feature flags
 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_account_support=%{?tizen_mobile_feature_account_support}"
 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_alarm_support=%{?tizen_mobile_feature_alarm_support}"
@@ -776,6 +781,9 @@ GYP_OPTIONS="--depth=. -Dtizen=1 -Dextension_build_type=Debug -Dextension_host_o
 GYP_OPTIONS="$GYP_OPTIONS -Ddisplay_type=%{display_type}"
 GYP_OPTIONS="$GYP_OPTIONS -Dcrosswalk_extensions_path=%{crosswalk_extensions_path}"
 
+# ut flags
+GYP_OPTIONS="$GYP_OPTIONS -Dtizen_ut_build=%{tizen_ut_build}"
+
 # feature flags
 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_account_support=%{?tizen_mobile_feature_account_support}"
 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_alarm_support=%{?tizen_mobile_feature_alarm_support}"
@@ -851,6 +859,9 @@ GYP_OPTIONS="--depth=. -Dtizen=1 -Dextension_build_type=Debug -Dextension_host_o
 GYP_OPTIONS="$GYP_OPTIONS -Ddisplay_type=%{display_type}"
 GYP_OPTIONS="$GYP_OPTIONS -Dcrosswalk_extensions_path=%{crosswalk_extensions_path}"
 
+# ut flags
+GYP_OPTIONS="$GYP_OPTIONS -Dtizen_ut_build=%{tizen_ut_build}"
+
 # feature flags
 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_account_support=%{?tizen_wearable_feature_account_support}"
 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_alarm_support=%{?tizen_wearable_feature_alarm_support}"
@@ -933,6 +944,9 @@ GYP_OPTIONS="--depth=. -Dtizen=1 -Dextension_build_type=Debug -Dextension_host_o
 GYP_OPTIONS="$GYP_OPTIONS -Ddisplay_type=%{display_type}"
 GYP_OPTIONS="$GYP_OPTIONS -Dcrosswalk_extensions_path=%{crosswalk_extensions_path}"
 
+# ut flags
+GYP_OPTIONS="$GYP_OPTIONS -Dtizen_ut_build=%{tizen_ut_build}"
+
 # feature flags
 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_account_support=%{?tizen_wearable_feature_account_support}"
 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_alarm_support=%{?tizen_wearable_feature_alarm_support}"
@@ -1008,6 +1022,9 @@ GYP_OPTIONS="--depth=. -Dtizen=1 -Dextension_build_type=Debug -Dextension_host_o
 GYP_OPTIONS="$GYP_OPTIONS -Ddisplay_type=%{display_type}"
 GYP_OPTIONS="$GYP_OPTIONS -Dcrosswalk_extensions_path=%{crosswalk_extensions_path}"
 
+# ut flags
+GYP_OPTIONS="$GYP_OPTIONS -Dtizen_ut_build=%{tizen_ut_build}"
+
 # feature flags
 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_account_support=%{?tizen_tv_feature_account_support}"
 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_alarm_support=%{?tizen_tv_feature_alarm_support}"
@@ -1081,6 +1098,9 @@ GYP_OPTIONS="--depth=. -Dtizen=1 -Dextension_build_type=Debug -Dextension_host_o
 GYP_OPTIONS="$GYP_OPTIONS -Ddisplay_type=%{display_type}"
 GYP_OPTIONS="$GYP_OPTIONS -Dcrosswalk_extensions_path=%{crosswalk_extensions_path}"
 
+# ut flags
+GYP_OPTIONS="$GYP_OPTIONS -Dtizen_ut_build=%{tizen_ut_build}"
+
 # feature flags
 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_account_support=%{?tizen_common_feature_account_support}"
 GYP_OPTIONS="$GYP_OPTIONS -Dtizen_feature_alarm_support=%{?tizen_common_feature_alarm_support}"
@@ -1177,6 +1197,13 @@ install -p -m 644 plugins.json %{buildroot}%{crosswalk_extensions_path}/common/p
 
 %if "%{?unified_build}" == "1" || "%{?profile}" == "mobile"
 mkdir -p %{buildroot}%{crosswalk_extensions_path}/mobile
+
+# tizen ut mobile
+%if "%{?tizen_ut_build}"  == "1"
+mkdir -p %{buildroot}/usr/bin
+install -p -m 755 out/bin_mobile/webapi_common_tests %{buildroot}/usr/bin/
+%endif
+
 install -p -m 644 out/bin_mobile/libtizen*.so %{buildroot}%{crosswalk_extensions_path}/mobile
 # execute desc_gentool
 LD_LIBRARY_PATH=$LD_LIBRARY_PATH:%{buildroot}%{crosswalk_extensions_path}/mobile out/Default/desc_gentool \
@@ -1253,9 +1280,9 @@ install -p -m 644 plugins.json %{buildroot}%{crosswalk_extensions_path}/ivi/plug
 
 # devel files
 mkdir -p %{buildroot}%{_libdir}/pkgconfig
-sed -i s,__LIB_DIR__,%{crosswalk_extensions_path},g packaging/%{name}.pc.in
-sed -i s,__INCLUDE_DIR__,%{_includedir}/%{name}/src,g packaging/%{name}.pc.in
 cp packaging/%{name}.pc.in %{buildroot}%{_libdir}/pkgconfig/%{name}.pc
+sed -i s,__LIB_DIR__,%{crosswalk_extensions_path},g %{buildroot}%{_libdir}/pkgconfig/%{name}.pc
+sed -i s,__INCLUDE_DIR__,%{_includedir}/%{name}/src,g %{buildroot}%{_libdir}/pkgconfig/%{name}.pc
 mkdir -p %{buildroot}%{_includedir}/%{name}/src/common
 mkdir -p %{buildroot}%{_includedir}/%{name}/src/common/filesystem
 install -p -m 644 src/common/*.h %{buildroot}%{_includedir}/%{name}/src/common
@@ -1265,7 +1292,6 @@ install -p -m 644 src/common/XW_Extension.cc %{buildroot}%{_includedir}/%{name}/
 mkdir -p %{buildroot}%{_includedir}/%{name}/tools
 install -p -m 644 tools/generate_api.py %{buildroot}%{_includedir}/%{name}/tools
 install -p -m 644 tools/mergejs.py %{buildroot}%{_includedir}/%{name}/tools
-install -p -m 644 tools/js_minimize.py %{buildroot}%{_includedir}/%{name}/tools
 cp -a tools/gyp %{buildroot}%{_includedir}/%{name}/tools/gyp
 cp -a tools/slimit %{buildroot}%{_includedir}/%{name}/tools/slimit
 cp -a out/Default/desc_gentool %{buildroot}%{_includedir}/%{name}/tools/desc_gentool
@@ -1309,6 +1335,12 @@ fi
 %{crosswalk_extensions_path}/mobile/plugins.json
 %manifest webapi-plugins.manifest
 
+# UT files
+%if "%{?tizen_ut_build}" == "1"
+%license GTEST.BSD-3-Clause
+/usr/bin/webapi_common_tests
+%endif
+
 # mobile-extension-emulator
 %ifarch %{ix86} x86_64
 %post mobile-extension-emulator