From 03172af921d8906cd3c155db147c1823171942b3 Mon Sep 17 00:00:00 2001 From: Andrew Bauer Date: Mon, 14 Sep 2015 13:51:48 -0500 Subject: [PATCH] link to cambozola pacakge, rather than download during build --- distros/redhat/CMakeLists.txt | 20 ++++++++++++-------- distros/redhat/zoneminder.el6.spec | 4 ++-- distros/redhat/zoneminder.el7.spec | 4 ++-- 3 files changed, 16 insertions(+), 12 deletions(-) diff --git a/distros/redhat/CMakeLists.txt b/distros/redhat/CMakeLists.txt index 057b827d55..74aa5641fe 100644 --- a/distros/redhat/CMakeLists.txt +++ b/distros/redhat/CMakeLists.txt @@ -26,15 +26,16 @@ else(download_jsc EQUAL 0) message(STATUS "Unable to download optional jscalander. Skipping...") endif(download_jsc EQUAL 0) +# Cambozola is now packaged in zmrepo # Download cambozola & move files into position -file(DOWNLOAD http://www.andywilcock.com/code/cambozola/cambozola-0.931.tar.gz ${CMAKE_CURRENT_SOURCE_DIR}/cambozola-0.931.tar.gz STATUS download_camb) -if(download_camb EQUAL 0) - message(STATUS "Cambozola successfully downloaded. Installing...") - execute_process(COMMAND ${CMAKE_CURRENT_SOURCE_DIR}/cambozola.sh WORKING_DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR} ERROR_VARIABLE untar_camb) - message(STATUS "Status of cambozola script was: ${untar_camb}") -else(download_camb EQUAL 0) - message(STATUS "Unable to download optional Cambozola. Skipping...") -endif(download_camb EQUAL 0) +#file(DOWNLOAD http://www.andywilcock.com/code/cambozola/cambozola-0.931.tar.gz ${CMAKE_CURRENT_SOURCE_DIR}/cambozola-0.931.tar.gz STATUS download_camb) +#if(download_camb EQUAL 0) +# message(STATUS "Cambozola successfully downloaded. Installing...") +# execute_process(COMMAND ${CMAKE_CURRENT_SOURCE_DIR}/cambozola.sh WORKING_DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR} ERROR_VARIABLE untar_camb) +# message(STATUS "Status of cambozola script was: ${untar_camb}") +#else(download_camb EQUAL 0) +# message(STATUS "Unable to download optional Cambozola. Skipping...") +#endif(download_camb EQUAL 0) # Create several empty folders file(MAKE_DIRECTORY sock swap zoneminder zoneminder-upload events images temp) @@ -53,6 +54,9 @@ install(CODE "execute_process(COMMAND ln -sf ../../../../var/lib/zoneminder/imag install(CODE "execute_process(COMMAND ln -sf ../../../../var/lib/zoneminder/temp \"\$ENV{DESTDIR}${CMAKE_INSTALL_PREFIX}/${CMAKE_INSTALL_DATAROOTDIR}/zoneminder/www/temp\")") install(CODE "execute_process(COMMAND ln -sf ../../../../../../var/lib/zoneminder/temp \"\$ENV{DESTDIR}${CMAKE_INSTALL_PREFIX}/${CMAKE_INSTALL_DATAROOTDIR}/zoneminder/www/api/app/tmp\")") +# Link to Cambozola, which is now packaged in zmrepo +install(CODE "execute_process(COMMAND ln -sf ../../java/cambozola.jar \"\$ENV{DESTDIR}${CMAKE_INSTALL_PREFIX}/${CMAKE_INSTALL_DATAROOTDIR}/zoneminder/www/cambozola.jar\")") + # Install auxillary files required to run zoneminder on CentOS install(FILES redalert.wav DESTINATION ${CMAKE_INSTALL_PREFIX}/${CMAKE_INSTALL_DATAROOTDIR}/zoneminder/www/sounds PERMISSIONS OWNER_WRITE OWNER_READ OWNER_EXECUTE GROUP_READ GROUP_EXECUTE WORLD_READ WORLD_EXECUTE) if(ZM_TARGET_DISTRO STREQUAL "el7") diff --git a/distros/redhat/zoneminder.el6.spec b/distros/redhat/zoneminder.el6.spec index d9487e4808..890d7bece9 100644 --- a/distros/redhat/zoneminder.el6.spec +++ b/distros/redhat/zoneminder.el6.spec @@ -30,7 +30,7 @@ BuildRequires: libcurl-devel vlc-devel ffmpeg-devel polkit-devel # cmake needs the following installed at build time due to the way it auto-detects certain parameters BuildRequires: httpd ffmpeg -Requires: httpd php php-gd php-mysql mysql-server libjpeg-turbo polkit net-tools mod_ssl +Requires: httpd php php-gd php-mysql mysql-server libjpeg-turbo cambozola polkit net-tools mod_ssl Requires: psmisc perl(:MODULE_COMPAT_%(eval "`%{__perl} -V:version`"; echo $version)) Requires: perl(DBD::mysql) perl(Archive::Tar) perl(Archive::Zip) Requires: perl(MIME::Entity) perl(MIME::Lite) perl(Net::SMTP) perl(Net::FTP) @@ -131,7 +131,7 @@ rm -rf %{_docdir}/%{name}-%{version} %files %defattr(-,root,root,-) %doc AUTHORS BUGS ChangeLog COPYING LICENSE NEWS README.md distros/redhat/README.CentOS distros/redhat/jscalendar-doc -%doc distros/redhat/cambozola-doc distros/redhat/local_zoneminder.te +%doc distros/redhat/local_zoneminder.te %config %attr(640,root,%{zmgid_final}) %{_sysconfdir}/zm.conf %config(noreplace) %attr(644,root,root) %{_sysconfdir}/httpd/conf.d/zoneminder.conf %config(noreplace) /etc/logrotate.d/%{name} diff --git a/distros/redhat/zoneminder.el7.spec b/distros/redhat/zoneminder.el7.spec index d4ab8c3af1..f283c6a3cb 100644 --- a/distros/redhat/zoneminder.el7.spec +++ b/distros/redhat/zoneminder.el7.spec @@ -32,7 +32,7 @@ BuildRequires: ffmpeg ffmpeg-devel perl(X10::ActiveHome) perl(Astro::SunTime) # cmake needs the following installed at build time due to the way it auto-detects certain parameters BuildRequires: httpd polkit-devel -Requires: httpd php php-gd php-mysql mariadb-server polkit net-tools mod_ssl +Requires: httpd php php-gd php-mysql mariadb-server cambozola polkit net-tools mod_ssl Requires: psmisc libjpeg-turbo vlc-core libcurl Requires: perl(:MODULE_COMPAT_%(eval "`%{__perl} -V:version`"; echo $version)) Requires: perl(DBD::mysql) perl(Archive::Tar) perl(Archive::Zip) @@ -138,7 +138,7 @@ fi %files %defattr(-,root,root,-) %doc AUTHORS BUGS ChangeLog COPYING LICENSE NEWS README.md distros/redhat/README.Centos7 distros/redhat/jscalendar-doc -%doc distros/redhat/cambozola-doc distros/redhat/local_zoneminder.te +%doc distros/redhat/local_zoneminder.te %config %attr(640,root,%{zmgid_final}) /etc/zm/zm.conf %config(noreplace) %attr(644,root,root) /etc/httpd/conf.d/zoneminder.conf %config(noreplace) /etc/tmpfiles.d/zoneminder.conf