Bump to lzo 2.10 69/136469/1 accepted/tizen_4.0_base accepted/tizen_4.0_unified accepted/tizen_base tizen_4.0 tizen_4.0_base tizen_4.0_tv accepted/tizen/4.0/base/20170811.093105 accepted/tizen/4.0/base/20170828.221432 accepted/tizen/4.0/unified/20180618.151157 accepted/tizen/base/20170707.183746 submit/tizen_4.0/20180612.084358 submit/tizen_4.0/20180615.073622 submit/tizen_4.0_base/20170811.071500 submit/tizen_4.0_base/20170828.000000 submit/tizen_4.0_base/20170828.000001 submit/tizen_base/20170703.023449 submit/tizen_base/20170705.023439 tizen_4.0.IoT.p1_release tizen_4.0.IoT.p2_release tizen_4.0.m2_release
authorDongHun Kwak <dh0128.kwak@samsung.com>
Fri, 30 Jun 2017 01:55:11 +0000 (10:55 +0900)
committerDongHun Kwak <dh0128.kwak@samsung.com>
Fri, 30 Jun 2017 01:55:11 +0000 (10:55 +0900)
[Model] All
[BinType] AP
[Customer] OPEN

[Issue#] N/A
[Request] N/A
[Occurrence Version] N/A

[Problem] Open Source version upgrade
[Cause & Measure] Open Source version upgrade
[Checking Method] N/A

[Team] Open Source Management and Setting Part
[Developer] dh0128.kwak
[Solution company] Samsung
[Change Type] N/A

Change-Id: I237917deefeebfbb119643649551f6e77147d830
Signed-off-by: DongHun Kwak <dh0128.kwak@samsung.com>
packaging/lzo.spec
run_test.sh [new file with mode: 0755]

index 08f3804..af8e19f 100644 (file)
@@ -1,5 +1,10 @@
+
+%if "%{run_tests}" == "1"
+    %define check %%check
+%endif
+
 Name:           lzo
-Version:        2.08
+Version:        2.10
 Release:        0
 License:        GPL-2.0+
 Summary:        Data compression library with very fast (de)compression
@@ -75,6 +80,13 @@ rm -f %{buildroot}%{_datadir}/doc/%{name}/COPYING
 
 %postun minilzo -p /sbin/ldconfig
 
+%check
+rm -f /tmp/%{name}_test
+%__make test | tee -i /tmp/%{name}_log
+cat /tmp/%{name}_log | grep "^LZO1" | sed -e 's/^LZO1.*| /TEST: PASS: /g' > /tmp/%{name}_test
+chmod +x ./run_test.sh
+./run_test.sh %{name} %{version}
+rm -f /tmp/%{name}_log
 
 %files
 %manifest %{name}.manifest
@@ -97,3 +109,4 @@ rm -f %{buildroot}%{_datadir}/doc/%{name}/COPYING
 %doc %{_datadir}/doc/%{name}/THANKS
 %{_includedir}/lzo
 %{_libdir}/lib*lzo*.so
+%{_libdir}/pkgconfig/lzo2.pc
diff --git a/run_test.sh b/run_test.sh
new file mode 100755 (executable)
index 0000000..4257d1e
--- /dev/null
@@ -0,0 +1,57 @@
+#!/bin/bash
+
+PACKAGE_NAME=$1
+PACKAGE_VERSION=$2
+
+TEST_LOG="/tmp/${PACKAGE_NAME}_test"
+export TEST_LOG
+
+# Color
+Color_Off='\e[0m'       # Text Reset
+
+# Regular Colors
+Red='\e[0;31m'          # Red
+Green='\e[0;32m'        # Green
+Cyan='\e[0;36m'         # Cyank
+
+# Bold
+BWhite='\e[1;37m'       # White
+
+result_check() {
+    test_case=$1
+    if [ $? -eq 0 ]
+    then
+        echo -e "${Green}PASS${Color_Off}: $test_case"
+        echo "TEST: PASS: $test_case" >> ${TEST_LOG}
+    else
+        echo -e "${Red}FAIL${Color_Off}: $test_case"
+        echo -e "TEST: FAIL: $test_case" >> ${TEST_LOG}
+    fi
+}
+
+skip_test() {
+    test_case=$1
+    echo -e "${Cyan}SKIP${Color_Off}: $test_case"
+    echo "TEST: SKIP: $test_case" >> ${TEST_LOG}
+}
+
+TOTAL_CNT=`grep "TEST:" ${TEST_LOG} | wc -l`
+PASS_CNT=`grep "PASS:" ${TEST_LOG} | wc -l`
+FAIL_CNT=`grep "FAIL:" ${TEST_LOG} | wc -l`
+SKIP_CNT=`grep "SKIP:" ${TEST_LOG} | wc -l`
+
+
+br='==================='; br=$br$br$br$br;
+
+echo -e "${Green}$br ${Color_Off}"
+echo -e "${Green}Testsuite summary for ${PACKAGE_NAME} ${PACKAGE_VERSION}${Color_Off}"
+echo -e "${Green}$br ${Color_Off}"
+echo -e "#${BWhite} TOTAL: $TOTAL_CNT ${Color_Off}"
+echo -e "#${Green} PASS${Color_Off} : $PASS_CNT"
+echo -e "#${Red} FAIL${Color_Off} : $FAIL_CNT"
+echo -e "#${Cyan} SKIP${Color_Off} : $SKIP_CNT"
+echo -e "${Green}$br ${Color_Off}"
+
+rm -f ${TEST_LOG}
+exit 0
+