Perl modules will be now be installed in <prefix>/<datadir>/zoneminder/perl5

This commit is contained in:
mastertheknife 2013-10-01 17:38:51 +03:00
parent 9c2e48ca01
commit 5fce4c516b
3 changed files with 3 additions and 1 deletions

View File

@ -330,6 +330,7 @@ set(WEB_PREFIX "${ZM_WEBDIR}")
set(CGI_PREFIX "${ZM_CGIDIR}")
set(WEB_USER "${ZM_WEB_USER}")
set(WEB_GROUP "${ZM_WEB_GROUP}")
set(EXTRA_PERL_LIB "use lib '${CMAKE_INSTALL_PREFIX}/${CMAKE_INSTALL_DATADIR}/zoneminder/perl5';")
# Generate files from the .in files
configure_file(zoneminder-config.cmake config.h @ONLY)

View File

@ -7,7 +7,7 @@ configure_file(lib/ZoneMinder/Memory.pm.in ${CMAKE_CURRENT_SOURCE_DIR}/lib/ZoneM
configure_file(lib/ZoneMinder/ConfigData.pm.in ${CMAKE_CURRENT_SOURCE_DIR}/lib/ZoneMinder/ConfigData.pm @ONLY)
# Add build target for the perl modules
add_custom_target(zmperlmodules ALL perl Makefile.PL FIRST_MAKEFILE=MakefilePerl INSTALL_BASE=output INSTALLPRIVLIB="output/${CMAKE_INSTALL_LIBDIR}/perl5" INSTALLARCHLIB="optout/${CMAKE_INSTALL_LIBDIR}/perl5/arch" INSTALLSITELIB="output/${CMAKE_INSTALL_LIBDIR}/perl5" INSTALLSITEARCH="optout/${CMAKE_INSTALL_LIBDIR}/perl5/arch" COMMAND make --makefile=MakefilePerl COMMAND make --makefile=MakefilePerl pure_install COMMENT "Building ZoneMinder perl modules")
add_custom_target(zmperlmodules ALL perl Makefile.PL FIRST_MAKEFILE=MakefilePerl INSTALL_BASE=output INSTALLPRIVLIB="output/${CMAKE_INSTALL_DATADIR}/zoneminder/perl5" INSTALLARCHLIB="optout/${CMAKE_INSTALL_DATADIR}/zoneminder/perl5/arch" INSTALLSITELIB="output/${CMAKE_INSTALL_DATADIR}/zoneminder/perl5" INSTALLSITEARCH="optout/${CMAKE_INSTALL_DATADIR}/zoneminder/perl5/arch" COMMAND make --makefile=MakefilePerl COMMAND make --makefile=MakefilePerl pure_install COMMENT "Building ZoneMinder perl modules")
# Add install target for the perl modules
install(DIRECTORY output/ DESTINATION "${CMAKE_INSTALL_PREFIX}")

View File

@ -41,6 +41,7 @@ use constant SLEEP_TIME => 10000; # In microseconds
#
# ==========================================================================
@EXTRA_PERL_LIB@
use ZoneMinder;
use DBI;
use POSIX;