system tests: add basic crash report sanity test
[platform/core/system/crash-worker.git] / packaging / crash-worker_system-tests.spec
1 %global __debug_package 1
2 # because of this is debug package, there are source files (kenny.cpp and
3 # btee.c) that will be copied to the destination directory, but we don't want
4 # them in the rpm package so this flag is to avoid RPM build error:
5 %define _unpackaged_files_terminate_build 0
6
7 Name:          crash-worker_system-tests
8 Summary:       Package with binaries and scripts for crash-worker system tests
9 Version:       5.5.8
10 Release:       1
11 Group:         Framework/system
12 License:       Apache-2.0 and BSD
13 Source0:       %{name}-%{version}.tar.gz
14 Source1001:    crash-worker_system-tests.manifest
15 BuildRequires: pkgconfig(glib-2.0)
16 BuildRequires: pkgconfig(rpm)
17 BuildRequires: cmake
18
19 Requires:      diff
20 Requires:      gdb
21 Requires:      coreutils
22 Requires:      tlm
23 Requires:      /bin/bash
24 Requires:      /usr/bin/unzip
25
26 Requires:      crash-worker
27 Requires:      %{_sbindir}/minicoredumper
28
29 %description
30 This package contains installable tests in Bash.
31
32 %prep
33 %setup -q
34
35
36 %build
37 cp %{SOURCE1001} .
38
39 export CFLAGS+=" -Werror"
40
41 cd tests/system
42 %cmake . -DCRASH_SYSTEM_TESTS_PATH=%{_libdir}/crash-worker_system-tests
43
44 make %{?jobs:-j%jobs}
45
46 %install
47 rm -rf %{buildroot}
48 cd tests/system
49 %make_install
50
51 %files -f debugfiles.list
52 %manifest %{name}.manifest
53 %defattr(0750,system_fw,system_fw)
54 %{_libdir}/crash-worker_system-tests/check_minicore_mem/check_minicore_mem.sh
55 %{_libdir}/crash-worker_system-tests/check_minicore_mem/cp.sh
56 %{_libdir}/crash-worker_system-tests/cmp_backtraces/cmp_backtraces.sh
57 %{_libdir}/crash-worker_system-tests/cmp_backtraces/cp.sh
58 %{_libdir}/crash-worker_system-tests/critical_process/critical_process.sh
59 %{_libdir}/crash-worker_system-tests/time_test/time_test.sh
60 %{_libdir}/crash-worker_system-tests/time_test/cp.sh
61 %{_libdir}/crash-worker_system-tests/wait_for_opt_usr/wait_for_opt_usr.sh
62 %{_libdir}/crash-worker_system-tests/info_file/info_file.sh
63 %{_libdir}/crash-worker_system-tests/log_dump_normal/log_dump_normal.sh
64 %{_libdir}/crash-worker_system-tests/log_dump_short/log_dump_short.sh
65 %{_libdir}/crash-worker_system-tests/log_file/log_file.sh
66 %{_libdir}/crash-worker_system-tests/so_info_file/so_info_file.sh
67 %{_libdir}/crash-worker_system-tests/report_basic/report_basic.sh
68 %{_libdir}/crash-worker_system-tests/report_type_info/report_type_info.sh
69 %{_libdir}/crash-worker_system-tests/without_core/without_core.sh
70 %{_libdir}/crash-worker_system-tests/crash_root_path/crash_root_path.sh
71 %{_libdir}/crash-worker_system-tests/utils/btee
72 %{_libdir}/crash-worker_system-tests/utils/kenny
73 %{_libdir}/crash-worker_system-tests/utils/minicore-utils.sh
74 %{_libdir}/crash-worker_system-tests/run.sh
75 %defattr(-,root,root)
76
77 # %post
78 # /usr/bin/chsmack -a "_" -e "SSSystem::Privileged" -r %{_libdir}/crash-worker_system-tests/
79