|
|
|
@@ -48,33 +48,31 @@ Guest-Client SDK files
|
|
|
|
|
#find . -name "*.tgz"
|
|
|
|
|
#echo `pwd`
|
|
|
|
|
# Build for guest-client package
|
|
|
|
|
cd guest-client-3.0.1
|
|
|
|
|
make clean
|
|
|
|
|
make build sysconfdir=%{_sysconfdir}
|
|
|
|
|
make sample
|
|
|
|
|
make tar ARCHIVE_NAME=wrs-guest-heartbeat-%{version}
|
|
|
|
|
find build
|
|
|
|
|
cd ..
|
|
|
|
|
|
|
|
|
|
# Install for guest-client package
|
|
|
|
|
%install
|
|
|
|
|
install -m 750 -d %{buildroot}/usr
|
|
|
|
|
install -m 750 -d %{buildroot}%{_includedir}
|
|
|
|
|
install -m 750 -d %{buildroot}%{_includedir}/guest-client
|
|
|
|
|
install -m 640 -p -D %{name}-%{version}/guest_client/src/heartbeat/guest_heartbeat_msg_defs.h %{buildroot}%{_includedir}/guest-client/guest_heartbeat_msg_defs.h
|
|
|
|
|
install -m 640 -p -D guest_client/src/heartbeat/guest_heartbeat_msg_defs.h %{buildroot}%{_includedir}/guest-client/guest_heartbeat_msg_defs.h
|
|
|
|
|
install -d %{buildroot}%{cgcs_sdk_deploy_dir}
|
|
|
|
|
install -m 640 %{name}-%{version}/build/wrs-guest-heartbeat-%{version}.tgz %{buildroot}%{cgcs_sdk_deploy_dir}
|
|
|
|
|
install -m 640 build/wrs-guest-heartbeat-%{version}.tgz %{buildroot}%{cgcs_sdk_deploy_dir}
|
|
|
|
|
%if %{with systemd}
|
|
|
|
|
install -m 644 -p -D %{name}-%{version}/guest_client/scripts/guest-client.service %{buildroot}%{_unitdir}/guest-client.service
|
|
|
|
|
install -m 744 -p -D %{name}-%{version}/guest_client/scripts/guest-client.systemd %{buildroot}%{_sysconfdir}/guest-client/guest-client.systemd
|
|
|
|
|
install -m 644 -p -D guest_client/scripts/guest-client.service %{buildroot}%{_unitdir}/guest-client.service
|
|
|
|
|
install -m 744 -p -D guest_client/scripts/guest-client.systemd %{buildroot}%{_sysconfdir}/guest-client/guest-client.systemd
|
|
|
|
|
%endif
|
|
|
|
|
install -m 750 -d %{buildroot}%{_sysconfdir}/guest-client/heartbeat
|
|
|
|
|
install -m 755 -p -D %{name}-%{version}/guest_client/scripts/guest_heartbeat.conf %{buildroot}%{_sysconfdir}/guest-client/heartbeat/guest_heartbeat.conf
|
|
|
|
|
install -m 755 -p -D %{name}-%{version}/guest_client/scripts/sample_event_handling_script %{buildroot}%{_sysconfdir}/guest-client/heartbeat/sample_event_handling_script
|
|
|
|
|
install -m 755 -p -D %{name}-%{version}/guest_client/scripts/sample_health_check_script %{buildroot}%{_sysconfdir}/guest-client/heartbeat/sample_health_check_script
|
|
|
|
|
install -m 640 -p -D %{name}-%{version}/build/guest-client %{buildroot}/usr/local/bin/guest-client
|
|
|
|
|
install -m 640 -p -D %{name}-%{version}/build/libguest_common_api.so.%{version} %{buildroot}/usr/local/lib/libguest_common_api.so.%{version}
|
|
|
|
|
install -m 640 -p -D %{name}-%{version}/build/libguest_heartbeat_api.so.%{version} %{buildroot}/usr/local/lib/libguest_heartbeat_api.so.%{version}
|
|
|
|
|
install -m 755 -p -D guest_client/scripts/guest_heartbeat.conf %{buildroot}%{_sysconfdir}/guest-client/heartbeat/guest_heartbeat.conf
|
|
|
|
|
install -m 755 -p -D guest_client/scripts/sample_event_handling_script %{buildroot}%{_sysconfdir}/guest-client/heartbeat/sample_event_handling_script
|
|
|
|
|
install -m 755 -p -D guest_client/scripts/sample_health_check_script %{buildroot}%{_sysconfdir}/guest-client/heartbeat/sample_health_check_script
|
|
|
|
|
install -m 640 -p -D build/guest-client %{buildroot}/usr/local/bin/guest-client
|
|
|
|
|
install -m 640 -p -D build/libguest_common_api.so.%{version} %{buildroot}/usr/local/lib/libguest_common_api.so.%{version}
|
|
|
|
|
install -m 640 -p -D build/libguest_heartbeat_api.so.%{version} %{buildroot}/usr/local/lib/libguest_heartbeat_api.so.%{version}
|
|
|
|
|
|
|
|
|
|
%files
|
|
|
|
|
%defattr(755,root,root,-)
|
|
|
|
|