Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 262019 - www-misc/zoneminder-1.24.1 version bump
Summary: www-misc/zoneminder-1.24.1 version bump
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: New packages (show other bugs)
Hardware: All Linux
: High enhancement (vote)
Assignee: Thomas Anderson (tanderson) (RETIRED)
URL: http://www.zoneminder.com/downloads.html
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2009-03-10 19:31 UTC by Michele Schiavo
Modified: 2010-01-30 06:06 UTC (History)
12 users (show)

See Also:
Package list:
Runtime testing required: ---


Attachments
zoneminder-1.24.1.ebuild (zoneminder-1.24.1.ebuild,3.66 KB, text/plain)
2009-03-10 19:36 UTC, Michele Schiavo
Details
zoneminder-1.24.1.ebuild (zoneminder-1.24.1.ebuild,3.44 KB, text/plain)
2009-03-23 15:11 UTC, Gary Richards
Details
Patch the zm.conf.in otherwise it points to /var/tmp/portage/.... once installed (db_upgrade_script_location.patch,412 bytes, patch)
2009-03-23 15:12 UTC, Gary Richards
Details | Diff
zoneminder-1.24.1.ebuild (zoneminder-1.24.1.ebuild,3.69 KB, text/plain)
2009-03-24 06:57 UTC, Gary Richards
Details
zoneminder-1.24.1.ebuild (zoneminder-1.24.1.ebuild,3.74 KB, text/plain)
2009-03-26 13:13 UTC, Gary Richards
Details
Basically same patch as 1.23.3, but new line numbers (zm_create.sql.in.patch,16.36 KB, patch)
2009-03-26 14:42 UTC, Josh Stephanoff
Details | Diff
Basically same patch as 1.23.3, but new line numbers and updated for new file (zm_remote_camera_http.patch,1.53 KB, patch)
2009-03-26 14:48 UTC, Josh Stephanoff
Details | Diff
Ebuild based on 1.23.3, with new ffmpeg, non-parallel build (thanks Gary!), updated epatch/sed, localhost (zoneminder-1.24.1.ebuild,3.87 KB, text/plain)
2009-03-26 15:17 UTC, Josh Stephanoff
Details
Added Gary's zm.conf.in.patch (zoneminder-1.24.1.ebuild,3.92 KB, text/plain)
2009-03-26 16:02 UTC, Josh Stephanoff
Details
The db_upgrade patch applies to more than 1.24.1, so made it exactly like Gary's (zoneminder-1.24.1.ebuild,3.92 KB, text/plain)
2009-03-26 16:36 UTC, Josh Stephanoff
Details
Updated version of my ebuild. Including Josh's updated patches. (zoneminder-1.24.1.ebuild,3.96 KB, text/plain)
2009-03-28 14:23 UTC, Gary Richards
Details
emerge log (www-misc:zoneminder-1.24.1:20090422-173141.log,133.42 KB, text/plain)
2009-04-22 17:35 UTC, Neil Bothwick
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Michele Schiavo 2009-03-10 19:31:53 UTC
new version

Reproducible: Always
Comment 1 Michele Schiavo 2009-03-10 19:33:59 UTC
please update package.mask to mash < 1.24.0
Comment 2 Michele Schiavo 2009-03-10 19:36:03 UTC
Created attachment 184589 [details]
zoneminder-1.24.1.ebuild
Comment 3 Lars Wendler (Polynomial-C) (RETIRED) gentoo-dev 2009-03-11 05:13:03 UTC
Whoops, an obsolete attachment without any reason why...

Anyway, reassigning to maintainer, CCing web-apps herd.
Comment 4 Dennis Schridde 2009-03-16 23:47:00 UTC
Duplicate of bug #236517. (See also: bug #259372)
Comment 5 Gary Richards 2009-03-23 15:11:16 UTC
Created attachment 185992 [details]
zoneminder-1.24.1.ebuild
Comment 6 Gary Richards 2009-03-23 15:12:33 UTC
Created attachment 185993 [details, diff]
Patch the zm.conf.in otherwise it points to /var/tmp/portage/.... once installed
Comment 7 Gary Richards 2009-03-23 15:15:09 UTC
New Ebuild for 1.24.1 attached.

It's a modified 1.23.3 ebuild with a couple of mods:

- Added 'mmap' use flag to allow user to enable new mmap support if required
- Patched zm.conf.in so that it creates a zm.conf that points to the correct location for the db upgrade scripts
- Forced make opts to -j1 as I couldn't make it to compile otherwise.
Comment 8 Gary Richards 2009-03-24 06:57:18 UTC
Created attachment 186075 [details]
zoneminder-1.24.1.ebuild

It turns out that mmap support requires Sys::Mmap which isn't currently in portage (but I had installed via g-cpan when I tested the ebuild).

I've commented out the part for mmap so that the ebuild works fine, but anyone requiring mmap support can easily uncomment the mmap parts if they want to install Sys::Mmap themselves.
Comment 9 Sebastian Flothow 2009-03-26 00:44:30 UTC
I just gave the ebuild a try on a freshly installed Gentoo box (amd64), and while it got through the compile stage, it failed upon installing:

make  install-data-hook
make[3]: Entering directory `/var/tmp/portage/www-misc/zoneminder-1.24.1/work/ZoneMinder-1.24.1'
( cd /var/tmp/portage/www-misc/zoneminder-1.24.1/image//etc; chown apache:apache zm.conf; chmod 600 zm.conf )
( if ! test -e /var/run; then mkdir /var/run; fi )
( if ! test -e /var/run/zm; then mkdir /var/run/zm; fi; chown apache:apache /var/run/zm; chmod u+w /var/run/zm )
ACCESS DENIED  mkdir:     /var/run/zm
mkdir: cannot create directory `/var/run/zm': Permission denied
chown: cannot access `/var/run/zm': No such file or directory
chmod: cannot access `/var/run/zm': No such file or directory
make[3]: *** [install-data-hook] Error 1
make[3]: Leaving directory `/var/tmp/portage/www-misc/zoneminder-1.24.1/work/ZoneMinder-1.24.1'
make[2]: *** [install-data-am] Error 2
make[2]: Leaving directory `/var/tmp/portage/www-misc/zoneminder-1.24.1/work/ZoneMinder-1.24.1'
make[1]: *** [install-am] Error 2
make[1]: Leaving directory `/var/tmp/portage/www-misc/zoneminder-1.24.1/work/ZoneMinder-1.24.1'
make: *** [install-recursive] Error 1
 *
 * ERROR: www-misc/zoneminder-1.24.1 failed.
 * Call stack:
 *               ebuild.sh, line   49:  Called src_install
 *             environment, line 3419:  Called die
 * The specific snippet of code:
 *       emake -j1 DESTDIR="${D}" install || die "emake install failed";
 *  The die message:
 *   emake install failed
 *
 * If you need support, post the topmost build error, and the call stack if relevant.
 * A complete build log is located at '/var/tmp/portage/www-misc/zoneminder-1.24.1/temp/build.log'.
 * The ebuild environment file is located at '/var/tmp/portage/www-misc/zoneminder-1.24.1/temp/environment'.
 * This ebuild is from an overlay: '/usr/local/portage/'
 *
--------------------------- ACCESS VIOLATION SUMMARY ---------------------------
LOG FILE = "/var/log/sandbox/sandbox-22657.log"

mkdir:     /var/run/zm
--------------------------------------------------------------------------------


Any suggestions on how to fix this?
Comment 10 Sebastian Flothow 2009-03-26 13:03:27 UTC
After some poking around, I discovered the sandbox violation can be avoided simply by running "mkdir /var/run/zm" manually before emerging zoneminder.
Comment 11 Gary Richards 2009-03-26 13:13:53 UTC
Created attachment 186318 [details]
zoneminder-1.24.1.ebuild

Ah i'd missed out the makefile patch used in the previous 1.23.3 ebuild. It's still required to fix the sandbox problem.

Please try this new ebuild. It relies on the files/1.23.1/Makefile.am.patch
Comment 12 Josh Stephanoff 2009-03-26 14:42:05 UTC
Created attachment 186320 [details, diff]
Basically same patch as 1.23.3, but new line numbers
Comment 13 Josh Stephanoff 2009-03-26 14:48:42 UTC
Created attachment 186321 [details, diff]
Basically same patch as 1.23.3, but new line numbers and updated for new file
Comment 14 Josh Stephanoff 2009-03-26 15:17:30 UTC
Created attachment 186322 [details]
Ebuild based on 1.23.3, with new ffmpeg, non-parallel build (thanks Gary!), updated epatch/sed, localhost

diff /usr/portage/www-misc/zoneminder/zoneminder-1.23.3.ebuild www-misc/zoneminder/zoneminder-1.24.1.ebuild
10c10
< PATCH_PV="1.23.1"
---
> PATCH_PV="1.24.1"
17c17
< KEYWORDS="~amd64 ~x86"
---
> KEYWORDS="~amd64 ~x86 ~ppc"
20a21,23
> # ZoneMinder does not seem to parallel build
> MAKEOPTS="${MAKEOPTS} -j1"
> 
43c46
<       ffmpeg? ( >=media-video/ffmpeg-0.4.9_p20080326 )
---
>       ffmpeg? ( >=media-video/ffmpeg-0.5-r1 )
63c66
<       epatch "${FILESDIR}"/${PATCH_PV}/zm_remote_camera.patch
---
>       epatch "${FILESDIR}"/${PATCH_PV}/zm_remote_camera_http.patch
67c70,73
<               src/zm_mpeg.h || die "404. File not found sedding src/zmpeg.h"
---
>               src/zm_ffmpeg.h || die "404. File not found sedding src/zm_ffmpeg.h"
>       sed -i \
>               -e 's:avformat_alloc_context:av_alloc_format_context:' \
>               src/zm_rtsp.cpp || die "404. File not found sedding src/zm_rtsp.cpp"
130c136
<       elog "3. Finally point your browser to http://localhos/${PN}"
---
>       elog "3. Finally point your browser to http://localhost/${PN}"
Comment 15 Gary Richards 2009-03-26 15:54:18 UTC
Hrm, using this old ebuild and just making it work means that some things are being missed:

MMAP support has been added to 1.24.1, it would be nice to have the ability to enable/disable this (as suggested in previous comments it would require Sys::Mmap to also be added into portage which is why the lines in my ebuilds were commented out in the hope that someone would also add Sys::Mmap to the portage tree).

The db_upgrade_script_location.patch attached fixes the default zm.conf so that ZM_PATH_BUILD=/usr/share/zoneminder by default, which is the correct location using the ebuild. Without this it defaults to some crazy directory that we built zoneminder in and stops things like zmupdate from working, complaining that it cannot find the sql update files.

I added the Module::Load as a dependency because otherwise you cannot control PTZ cameras apparently (during configure it says):
configure: WARNING: Module::Load is required for PTZ camera control

Is the remote camera patch even required now? Hasn't remote camera stuff been greatly improved in 1.24.1?

Why does the sedding happen? I looks to me as thought it was used so that the previous zoneminder compiled on an older ffmpeg? Whereas if we're depending on the newest ffmpeg, it compiles fine, whereas after the sedding happens you see these message when compiling:
zm_rtsp.cpp:183: warning: 'av_alloc_format_context' is deprecated (declared at /usr/include/libavformat/avformat.h:873)
zm_rtsp.cpp:183: warning: 'av_alloc_format_context' is deprecated (declared at /usr/include/libavformat/avformat.h:873)
Comment 16 Josh Stephanoff 2009-03-26 16:02:34 UTC
Created attachment 186327 [details]
Added Gary's zm.conf.in.patch
Comment 17 Josh Stephanoff 2009-03-26 16:36:19 UTC
Created attachment 186330 [details]
The db_upgrade patch applies to more than 1.24.1, so made it exactly like Gary's

The db_upgrade patch applies to more than 1.24.1, so made it exactly like Gary's

< epatch "${FILESDIR}"/${PATCH_PV}/zm.conf.in.patch
---
> epatch "${FILESDIR}"/db_upgrade_script_location.patch
Comment 18 Josh Stephanoff 2009-03-26 17:45:35 UTC
(In reply to comment #15)

Sorry Gary, somehow I missed your comment #15, or I would not have posted my 2 updated ebuilds.


About the remote cameras: I am not sure if the MPEG -> JPEG content is still needed.

You are completely right on all fronts. I had this ebuild almost working a while ago, and the sed was to get it to compile with ffmpeg 0.4.9.

Your make opts to -j1 was the ticket to get my ebuild working. In my excitement, I submitted my ebuild, when I should have only submitted the updated patches.
Comment 19 Sebastian Flothow 2009-03-27 00:09:49 UTC
I probably won't be able to test further ebuilds as I'll put my setup into testing tomorrow (and then on into production at some point in time). I'd just like to point out that the ebuild I used (attachment id 186075) does not install an initscript - this is not a showstopper, as I can simply call zmpkg.pl directly, but providing an initscript would certainly be desirable.

Apart from that, everything seems to be working well. (I'm testing right now with a single Mobotix M22M IP camera, I'll hook up another few tomorrow. A capture card for some old analog cameras is planned, but still some way off, so I can't vouch for the V4L stuff yet.)
Comment 20 Josh Stephanoff 2009-03-27 12:37:30 UTC
The zm_create.sql.in.patch is still needed. It makes logs and sockets go to /var/log/zoneminder and /var/run/zm instead of /tmp, and makes it look for /usr/bin/ffmpeg instead of /usr/local/bin/ffmpeg.

This patch is basically for new installs of zoneminder, as old ones being upgraded already had these settings changed in the past, by previous sql patches.
Comment 21 Gary Richards 2009-03-28 14:23:06 UTC
Created attachment 186550 [details]
Updated version of my ebuild. Including Josh's updated patches.

Incorporates everything discussed in previous posts.

Requires: Makefile.am.patch from files/1.23.1 in files/1.24.1
- Seems to fix sandbox violations during install
Requires: Attached zm_create.sql.in.patch in files/1.24.1
- For the reasons Josh suggested in comment #20
Requires: Attached db_upgrade_script_location.patch in files/
- For the reasons I mention in comment #15

Requires: Attached zm_remote_camera_http.patch in files/1.24.1
- Unsure if this patch is still required, it doesn't really cause any harm


MMAP functionality contained in ebuild but commented out. Need to request Perl's Sys::Mmap added to portage so that we can add a dependency for it and then uncomment the various lines in the ebuild. MMAP functionality tested as working by installing Sys::Mmap using g-cpan.

How do we go about having Sys::Mmap added to portage and how to we request that this is considered for portage? Or do we try to get this into the Sunrise overlay first?
Comment 22 Thomas Anderson (tanderson) (RETIRED) gentoo-dev 2009-03-28 15:11:18 UTC
I'm working on this, probably get to this after I get some council stuff done.
Comment 23 Frank Eichentopf 2009-04-22 09:19:23 UTC
(In reply to comment #21)
> Requires: Attached zm_remote_camera_http.patch in files/1.24.1
> - Unsure if this patch is still required, it doesn't really cause any harm

these patch are still required because some cams like cas861 send a wrong mimetype while fetch jpeg images
Comment 24 Neil Bothwick 2009-04-22 17:34:12 UTC
I can't get this to compile, it fails like this:

zm_timer.o: In function `Timer::TimerThread::run()':
zm_timer.cpp:(.text+0x8b): undefined reference to `ThreadData<bool>::setValue(bool)'
zm_timer.cpp:(.text+0xa1): undefined reference to `ThreadData<bool>::getUpdatedValue(int) const'
zm_timer.o: In function `Timer::TimerThread::reset()':
zm_timer.cpp:(.text+0x1d3): undefined reference to `ThreadData<bool>::updateValueSignal(bool)'
zm_timer.o: In function `Timer::TimerThread::cancel()':
zm_timer.cpp:(.text+0x2ad): undefined reference to `ThreadData<bool>::updateValueSignal(bool)'
zm_timer.o: In function `Timer::TimerThread::TimerThread(Timer&, int, bool)':
zm_timer.cpp:(.text+0x56a): undefined reference to `ThreadData<bool>::ThreadData(bool)'
zm_timer.o: In function `Timer::TimerThread::TimerThread(Timer&, int, bool)':
zm_timer.cpp:(.text+0x76a): undefined reference to `ThreadData<bool>::ThreadData(bool)'
zm_utils.o: In function `startsWith(std::basic_string<char, std::char_traits<char>, std::allocator<char> > const&, std::basic_string<char, std::char_traits<char>, std::allocator<char> > const&)':
zm_utils.cpp:(.text+0x1f8): undefined reference to `__gnu_cxx::__enable_if<std::__is_char<char>::__value, bool>::__type std::operator==<char>(std::basic_string<char, std::char_traits<char>, std::allocator<char> > const&, std::basic_string<char, std::char_traits<char>, std::allocator<char> > const&)'
zm_utils.o: In function `split(std::basic_string<char, std::char_traits<char>, std::allocator<char> > const&, std::basic_string<char, std::char_traits<char>, std::allocator<char> >)':
zm_utils.cpp:(.text+0x24f): undefined reference to `std::vector<std::basic_string<char, std::char_traits<char>, std::allocator<char> >, std::allocator<std::basic_string<char, std::char_traits<char>, std::allocator<char> > > >::vector()'
zm_utils.cpp:(.text+0x2ba): undefined reference to `std::vector<std::basic_string<char, std::char_traits<char>, std::allocator<char> >, std::allocator<std::basic_string<char, std::char_traits<char>, std::allocator<char> > > >::push_back(std::basic_string<char, std::char_traits<char>, std::allocator<char> > const&)'
zm_utils.cpp:(.text+0x2f5): undefined reference to `std::vector<std::basic_string<char, std::char_traits<char>, std::allocator<char> >, std::allocator<std::basic_string<char, std::char_traits<char>, std::allocator<char> > > >::~vector()'
collect2: ld returned 1 exit status
make[2]: *** [zmc] Error 1
make[2]: Leaving directory `/var/tmp/portage/www-misc/zoneminder-1.24.1/work/ZoneMinder-1.24.1/src'
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory `/var/tmp/portage/www-misc/zoneminder-1.24.1/work/ZoneMinder-1.24.1'
make: *** [all] Error 2
 *
 * ERROR: www-misc/zoneminder-1.24.1 failed.
 * Call stack:
 *               ebuild.sh, line   49:  Called src_compile
 *             environment, line 3507:  Called die
 * The specific snippet of code:
 *       emake -j1 || die "emake failed"
 *  The die message:
 *   emake failed
 *
 * If you need support, post the topmost build error, and the call stack if relevant.
 * A complete build log is located at '/var/log/portage/www-misc:zoneminder-1.24.1:20090422-173141.log'.
 * The ebuild environment file is located at '/var/tmp/portage/www-misc/zoneminder-1.24.1/temp/environment'.
 * This ebuild is from an overlay named 'digimed': '/mnt/portage/local/'
 *

Portage 2.2_rc31 (default/linux/amd64/2008.0/desktop, gcc-4.3.3, glibc-2.9_p20081201-r2, 2.6.29-gentoo-r1_1 x86_64)
=================================================================
System uname: Linux-2.6.29-gentoo-r1_1-x86_64-Intel-R-_Core-TM-2_CPU_6600_@_2.40GHz-with-gentoo-2.0.0
Timestamp of tree: Wed, 22 Apr 2009 14:15:02 +0000
distcc 3.1 x86_64-pc-linux-gnu [disabled]
ccache version 2.4 [enabled]
app-shells/bash:     4.0_p17-r1
dev-java/java-config: 1.3.7-r1, 2.1.7
dev-lang/python:     2.6.2
dev-util/ccache:     2.4-r8
dev-util/cmake:      2.6.3-r1
sys-apps/baselayout: 2.0.0
sys-apps/openrc:     0.4.3-r2
sys-apps/sandbox:    1.9
sys-devel/autoconf:  2.13, 2.63-r1
sys-devel/automake:  1.5, 1.7.9-r1, 1.8.5-r3, 1.9.6-r2, 1.10.2
sys-devel/binutils:  2.19.1-r1
sys-devel/gcc-config: 1.4.1
sys-devel/libtool:   2.2.6a
virtual/os-headers:  2.6.28-r1
ACCEPT_KEYWORDS="amd64 ~amd64"
CBUILD="x86_64-pc-linux-gnu"
CFLAGS="-march=core2 -O2 -pipe"
CHOST="x86_64-pc-linux-gnu"
CONFIG_PROTECT="/etc /etc/env.d /usr/kde/3.5/env /usr/kde/3.5/share/config /usr/kde/3.5/shutdown /usr/kde/4.2/env /usr/kde/4.2/share/config /usr/kde/4.2/shutdown /usr/share/config /var/lib/hsqldb"
CONFIG_PROTECT_MASK="/etc/ca-certificates.conf /etc/env.d /etc/env.d/java/ /etc/fonts/fonts.conf /etc/gconf /etc/gentoo-release /etc/init.d /etc/php/apache2-php5/ext-active/ /etc/php/cgi-php5/ext-active/ /etc/php/cli-php5/ext-active/ /etc/revdep-rebuild /etc/sandbox.d /etc/terminfo /etc/texmf/language.dat.d /etc/texmf/language.def.d /etc/texmf/updmap.d /etc/texmf/web2c /etc/udev/rules.d"
CXXFLAGS="-march=core2 -O2 -pipe"
DISTDIR="/mnt/portage/distfiles"
EMERGE_DEFAULT_OPTS="--alphabetical"
FEATURES="buildpkg ccache distlocks fixpackages metadata-transfer parallel-fetch preserve-libs protect-owned sandbox sfperms strict unmerge-orphans userfetch"
GENTOO_MIRRORS="ftp://ftp.heanet.ie/pub/gentoo/ ftp://ftp.belnet.be/mirror/rsync.gentoo.org/gentoo/ ftp://ftp.easynet.nl/mirror/gentoo/"
LANG="en_GB"
LDFLAGS="-Wl,-O1"
LINGUAS="en_GB"
MAKEOPTS="-j3"
PKGDIR="/mnt/portage/packages/zaphod"
PORTAGE_CONFIGROOT="/"
PORTAGE_RSYNC_OPTS="--recursive --links --safe-links --perms --times --compress --force --whole-file --delete --stats --timeout=180 --exclude=/distfiles --exclude=/local --exclude=/packages"
PORTAGE_TMPDIR="/var/tmp"
PORTDIR="/usr/portage"
PORTDIR_OVERLAY="/mnt/portage/layman/sunrise /mnt/portage/local"
SYNC="rsync://desiato/gentoo"
USE="X a52 aac aalib acl acpi alsa amd64 apache2 audiofile berkdb bluetooth branding bzip2 cairo cddb cdr cli cracklib crypt cups curl dbus directfb dv dvb dvd dvdr dvdread encode exif fam ffmpeg flac foomaticdb gdbm gif gimp gphoto2 gpm gtk hal htmlhandbook iconv id3 ieee1394 imagemagick imap isdnlog jabber java jbig jpeg jpeg2k kde kdeenablefinal kdehiddenvisibility kdeprefix kipi libnotify libwww lirc lm_sensors mad mailwrapper midi mmx mmxext mng mp3 mp4 mpeg mplayer mudflap multilib musicbrainz mysql ncurses nptl nptlonly nsplugin ntfs nvidia offensive ogg opengl openmp oss pcre pda pdf png ppds pppd python qt3 qt3support qt4 quicktime readline reflection reiserfs samba scanner sdl session slp spell spl sse sse2 ssl ssse3 startup-notification svg sysfs tcpd theora threads tiff truetype unicode usb v4l v4l2 vnc vorbis webkit x264 xcb xcomposite xfs xinerama xml xorg xscreensaver xulrunner xv xvid xvmc zlib zsh-completion zvbi" ALSA_CARDS="ali5451 als4000 atiixp atiixp-modem bt87x ca0106 cmipci emu10k1x ens1370 ens1371 es1938 es1968 fm801 hda-intel intel8x0 intel8x0m maestro3 trident usb-audio via82xx via82xx-modem ymfpci" ALSA_PCM_PLUGINS="adpcm alaw asym copy dmix dshare dsnoop empty extplug file hooks iec958 ioplug ladspa lfloat linear meter mmap_emul mulaw multi null plug rate route share shm softvol" APACHE2_MODULES="actions alias auth_basic auth_digest authn_anon authn_dbd authn_dbm authn_default authn_file authz_dbm authz_default authz_groupfile authz_host authz_owner authz_user autoindex cache dav dav_fs dav_lock dbd deflate dir disk_cache env expires ext_filter file_cache filter headers ident imagemap include info log_config logio mem_cache mime mime_magic negotiation proxy proxy_ajp proxy_balancer proxy_connect proxy_http rewrite setenvif so speling status unique_id userdir usertrack vhost_alias" CAMERAS="canon nikon" ELIBC="glibc" INPUT_DEVICES="keyboard mouse aiptek" KERNEL="linux" LCD_DEVICES="bayrad cfontz cfontz633 glk hd44780 lb216 lcdm001 mtxorb ncurses text" LINGUAS="en_GB" LIRC_DEVICES="devinput mceusb mceusb2" USERLAND="GNU" VIDEO_CARDS="vesa nv nvidia"
Unset:  CPPFLAGS, CTARGET, FFLAGS, INSTALL_MASK, LC_ALL, PORTAGE_COMPRESS, PORTAGE_COMPRESS_FLAGS, PORTAGE_RSYNC_EXTRA_OPTS

Comment 25 Neil Bothwick 2009-04-22 17:35:22 UTC
Created attachment 189188 [details]
emerge log
Comment 26 Ronny Bull 2009-05-11 12:11:14 UTC
Having the same issue on x86

zm_utils.cpp:(.text+0x299): undefined reference to `std::vector<std::basic_string<char, std::char_traits<char>, std::allocator<char> >, std::allocator<std::basic_string<char, std::char_traits<char>, std::allocator<char> > > >::vector()'
zm_utils.cpp:(.text+0x323): undefined reference to `std::vector<std::basic_string<char, std::char_traits<char>, std::allocator<char> >, std::allocator<std::basic_string<char, std::char_traits<char>, std::allocator<char> > > >::push_back(std::basic_string<char, std::char_traits<char>, std::allocator<char> > const&)'
zm_utils.cpp:(.text+0x35c): undefined reference to `std::vector<std::basic_string<char, std::char_traits<char>, std::allocator<char> >, std::allocator<std::basic_string<char, std::char_traits<char>, std::allocator<char> > > >::~vector()'
collect2: ld returned 1 exit status
make[2]: *** [zmc] Error 1
make[2]: Leaving directory `/var/tmp/portage/www-misc/zoneminder-1.24.1/work/ZoneMinder-1.24.1/src'
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory `/var/tmp/portage/www-misc/zoneminder-1.24.1/work/ZoneMinder-1.24.1'
make: *** [all] Error 2
 * 
 * ERROR: www-misc/zoneminder-1.24.1 failed.
 * Call stack:
 *               ebuild.sh, line   48:  Called src_compile
 *             environment, line 3377:  Called die
 * The specific snippet of code:
 *       emake -j1 || die "emake failed"
 *  The die message:
 *   emake failed
 * 
 * If you need support, post the topmost build error, and the call stack if relevant.
 * A complete build log is located at '/var/tmp/portage/www-misc/zoneminder-1.24.1/temp/build.log'.
 * The ebuild environment file is located at '/var/tmp/portage/www-misc/zoneminder-1.24.1/temp/environment'.
 * This ebuild is from an overlay: '/usr/local/portage/'
 * 

>>> Failed to emerge www-misc/zoneminder-1.24.1, Log file:

>>>  '/var/tmp/portage/www-misc/zoneminder-1.24.1/temp/build.log'


emerge --info
Portage 2.1.6.11 (hardened/linux/x86/2008.0/server, gcc-4.3.3, glibc-2.8_p20080602-r1, 2.6.26-hardened-r9 i686)
=================================================================
System uname: Linux-2.6.26-hardened-r9-i686-Intel-R-_Celeron-R-_CPU_2.66GHz-with-glibc2.1.3
Timestamp of tree: Sat, 09 May 2009 07:45:01 +0000
ccache version 2.4 [enabled]
app-shells/bash:     3.2_p39
dev-lang/python:     2.5.4-r2
dev-util/ccache:     2.4-r7
dev-util/cmake:      2.6.4
sys-apps/baselayout: 1.12.11.1
sys-apps/sandbox:    1.6-r2
sys-devel/autoconf:  2.63
sys-devel/automake:  1.7.9-r1, 1.9.6-r2, 1.10.2
sys-devel/binutils:  2.18-r3
sys-devel/gcc-config: 1.4.0-r4
sys-devel/libtool:   1.5.26
virtual/os-headers:  2.6.27-r2
ACCEPT_KEYWORDS="x86"
CBUILD="i686-pc-linux-gnu"
CFLAGS="-march=pentium4 -O2 -pipe -fomit-frame-pointer -fforce-addr"
CHOST="i686-pc-linux-gnu"
CONFIG_PROTECT="/etc"
CONFIG_PROTECT_MASK="/etc/ca-certificates.conf /etc/env.d /etc/fonts/fonts.conf /etc/gconf /etc/php/apache2-php5/ext-active/ /etc/php/cgi-php5/ext-active/ /etc/php/cli-php5/ext-active/ /etc/revdep-rebuild /etc/sandbox.d /etc/terminfo /etc/udev/rules.d"
CXXFLAGS="-march=pentium4 -O2 -pipe -fomit-frame-pointer -fforce-addr"
DISTDIR="/usr/portage/distfiles"
FEATURES="ccache distlocks fixpackages parallel-fetch protect-owned sandbox sfperms strict unmerge-orphans userfetch"
GENTOO_MIRRORS="http://gentoo.osuosl.org/ http://www.gtlib.gatech.edu/pub/gentoo http://gentoo.mirrors.pair.com/ "
LDFLAGS="-Wl,-O1"
LINGUAS="en"
MAKEOPTS="-j2"
PKGDIR="/usr/portage/packages"
PORTAGE_CONFIGROOT="/"
PORTAGE_RSYNC_OPTS="--recursive --links --safe-links --perms --times --compress --force --whole-file --delete --stats --timeout=180 --exclude=/distfiles --exclude=/local --exclude=/packages"
PORTAGE_TMPDIR="/var/tmp"
PORTDIR="/usr/portage"
PORTDIR_OVERLAY="/usr/local/portage"
SYNC="rsync://rsync.namerica.gentoo.org/gentoo-portage"
USE="acl apache2 berkdb bzip2 cdr cli cracklib crypt cups dri dvd gdbm gpm hardened iconv ldap mailwrapper midi mmx mudflap mysql ncurses nptl nptlonly pam pcre perl pic pni pppd python readline reflection session snmp spl sse sse2 ssl sysfs tcpd truetype urandom x86 xml zlib" APACHE2_MODULES="actions alias auth_basic authn_alias authn_anon authn_dbm authn_default authn_file authz_dbm authz_default authz_groupfile authz_host authz_owner authz_user autoindex cache dav dav_fs dav_lock deflate dir disk_cache env expires ext_filter file_cache filter headers include info log_config logio mem_cache mime mime_magic negotiation rewrite setenvif speling status unique_id userdir usertrack vhost_alias" ELIBC="glibc" INPUT_DEVICES="keyboard mouse" KERNEL="linux" LINGUAS="en" USERLAND="GNU" VIDEO_CARDS="nvidia"
Unset:  CPPFLAGS, CTARGET, EMERGE_DEFAULT_OPTS, FFLAGS, INSTALL_MASK, LANG, LC_ALL, PORTAGE_COMPRESS, PORTAGE_COMPRESS_FLAGS, PORTAGE_RSYNC_EXTRA_OPTS

Comment 27 Matt B 2009-05-22 09:46:18 UTC
Bump again.

Any chance of having an updated ebuild added to the portage tree, please?(In reply to comment #26)
> Having the same issue on x86
> 
> zm_utils.cpp:(.text+0x299): undefined reference to
> `std::vector<std::basic_string<char, std::char_traits<char>,
> std::allocator<char> >, std::allocator<std::basic_string<char,
> std::char_traits<char>, std::allocator<char> > > >::vector()'
> zm_utils.cpp:(.text+0x323): undefined reference to
> `std::vector<std::basic_string<char, std::char_traits<char>,
> std::allocator<char> >, std::allocator<std::basic_string<char,
> std::char_traits<char>, std::allocator<char> > >
> >::push_back(std::basic_string<char, std::char_traits<char>,
> std::allocator<char> > const&)'
> zm_utils.cpp:(.text+0x35c): undefined reference to
> `std::vector<std::basic_string<char, std::char_traits<char>,
> std::allocator<char> >, std::allocator<std::basic_string<char,
> std::char_traits<char>, std::allocator<char> > > >::~vector()'
> collect2: ld returned 1 exit status
> make[2]: *** [zmc] Error 1
> make[2]: Leaving directory
> `/var/tmp/portage/www-misc/zoneminder-1.24.1/work/ZoneMinder-1.24.1/src'
> make[1]: *** [all-recursive] Error 1
> make[1]: Leaving directory
> `/var/tmp/portage/www-misc/zoneminder-1.24.1/work/ZoneMinder-1.24.1'
> make: *** [all] Error 2
>  * 
>  * ERROR: www-misc/zoneminder-1.24.1 failed.
>  * Call stack:
>  *               ebuild.sh, line   48:  Called src_compile
>  *             environment, line 3377:  Called die
>  * The specific snippet of code:
>  *       emake -j1 || die "emake failed"
>  *  The die message:
>  *   emake failed
>  * 
>  * If you need support, post the topmost build error, and the call stack if
> relevant.
>  * A complete build log is located at
> '/var/tmp/portage/www-misc/zoneminder-1.24.1/temp/build.log'.
>  * The ebuild environment file is located at
> '/var/tmp/portage/www-misc/zoneminder-1.24.1/temp/environment'.
>  * This ebuild is from an overlay: '/usr/local/portage/'
>  * 
> 
> >>> Failed to emerge www-misc/zoneminder-1.24.1, Log file:
> 
> >>>  '/var/tmp/portage/www-misc/zoneminder-1.24.1/temp/build.log'
> 
> 
> emerge --info
> Portage 2.1.6.11 (hardened/linux/x86/2008.0/server, gcc-4.3.3,
> glibc-2.8_p20080602-r1, 2.6.26-hardened-r9 i686)
> =================================================================
> System uname:
> Linux-2.6.26-hardened-r9-i686-Intel-R-_Celeron-R-_CPU_2.66GHz-with-glibc2.1.3
> Timestamp of tree: Sat, 09 May 2009 07:45:01 +0000
> ccache version 2.4 [enabled]
> app-shells/bash:     3.2_p39
> dev-lang/python:     2.5.4-r2
> dev-util/ccache:     2.4-r7
> dev-util/cmake:      2.6.4
> sys-apps/baselayout: 1.12.11.1
> sys-apps/sandbox:    1.6-r2
> sys-devel/autoconf:  2.63
> sys-devel/automake:  1.7.9-r1, 1.9.6-r2, 1.10.2
> sys-devel/binutils:  2.18-r3
> sys-devel/gcc-config: 1.4.0-r4
> sys-devel/libtool:   1.5.26
> virtual/os-headers:  2.6.27-r2
> ACCEPT_KEYWORDS="x86"
> CBUILD="i686-pc-linux-gnu"
> CFLAGS="-march=pentium4 -O2 -pipe -fomit-frame-pointer -fforce-addr"
> CHOST="i686-pc-linux-gnu"
> CONFIG_PROTECT="/etc"
> CONFIG_PROTECT_MASK="/etc/ca-certificates.conf /etc/env.d /etc/fonts/fonts.conf
> /etc/gconf /etc/php/apache2-php5/ext-active/ /etc/php/cgi-php5/ext-active/
> /etc/php/cli-php5/ext-active/ /etc/revdep-rebuild /etc/sandbox.d /etc/terminfo
> /etc/udev/rules.d"
> CXXFLAGS="-march=pentium4 -O2 -pipe -fomit-frame-pointer -fforce-addr"
> DISTDIR="/usr/portage/distfiles"
> FEATURES="ccache distlocks fixpackages parallel-fetch protect-owned sandbox
> sfperms strict unmerge-orphans userfetch"
> GENTOO_MIRRORS="http://gentoo.osuosl.org/
> http://www.gtlib.gatech.edu/pub/gentoo http://gentoo.mirrors.pair.com/ "
> LDFLAGS="-Wl,-O1"
> LINGUAS="en"
> MAKEOPTS="-j2"
> PKGDIR="/usr/portage/packages"
> PORTAGE_CONFIGROOT="/"
> PORTAGE_RSYNC_OPTS="--recursive --links --safe-links --perms --times --compress
> --force --whole-file --delete --stats --timeout=180 --exclude=/distfiles
> --exclude=/local --exclude=/packages"
> PORTAGE_TMPDIR="/var/tmp"
> PORTDIR="/usr/portage"
> PORTDIR_OVERLAY="/usr/local/portage"
> SYNC="rsync://rsync.namerica.gentoo.org/gentoo-portage"
> USE="acl apache2 berkdb bzip2 cdr cli cracklib crypt cups dri dvd gdbm gpm
> hardened iconv ldap mailwrapper midi mmx mudflap mysql ncurses nptl nptlonly
> pam pcre perl pic pni pppd python readline reflection session snmp spl sse sse2
> ssl sysfs tcpd truetype urandom x86 xml zlib" APACHE2_MODULES="actions alias
> auth_basic authn_alias authn_anon authn_dbm authn_default authn_file authz_dbm
> authz_default authz_groupfile authz_host authz_owner authz_user autoindex cache
> dav dav_fs dav_lock deflate dir disk_cache env expires ext_filter file_cache
> filter headers include info log_config logio mem_cache mime mime_magic
> negotiation rewrite setenvif speling status unique_id userdir usertrack
> vhost_alias" ELIBC="glibc" INPUT_DEVICES="keyboard mouse" KERNEL="linux"
> LINGUAS="en" USERLAND="GNU" VIDEO_CARDS="nvidia"
> Unset:  CPPFLAGS, CTARGET, EMERGE_DEFAULT_OPTS, FFLAGS, INSTALL_MASK, LANG,
> LC_ALL, PORTAGE_COMPRESS, PORTAGE_COMPRESS_FLAGS, PORTAGE_RSYNC_EXTRA_OPTS
> 

Comment 28 Sebastian Flothow 2009-05-23 15:15:20 UTC
I just rebuilt (as I was starting over with my configuration anyway), using the following files:

zoneminder-1.24.1.ebuild (ID 186550)
zm_create.sql.in.patch (ID 186320)
zm_remote_camera_http.patch (ID 186321)
db_upgrade_script_location.patch (ID 185993)
Makefile.am.patch (from /usr/portage/www-misc/zoneminder/files/1.23.1)

Building and installing went completely smooth. 

The postinst message tells me to run /etc/init.d/zoneminder start, but /etc/init.d/zoneminder doesn't exist. However, the existing /usr/portage/www-misc/zoneminder/files/{conf.d,init.d} work just fine. (I suppose this is simply an issue of ${FILESDIR} pointing the wrong way due to the ebuild being in an overlay, but shouldn't this result in an error?)

I still can't use the streaming URL of my Mobotix cameras, so it seems there is some other problem than the MIME type issue addressed by zm_remote_camera_http.patch. OTOH fetching individual JPEGs works perfectly well, so I don't care much.

(Also, that capture card I'm waiting for is supposed to arrive Real Soon Now, so I can then test local cameras as well.)
Comment 29 Sebastian Flothow 2009-06-07 15:51:08 UTC
I've got 4 V4L devices now, working fine as well. Are there any reasons left not to put this ebuild into the portage tree?
Comment 30 Eric Westbrook 2009-06-09 23:17:38 UTC
The primary problems I see with this ebuild (and with the older ebuild as well) are httpd and webapp related:

* The ebuild has a hard dependency on apache (unnecessarily);
* The ebuild doesn't honor/use the gentoo webapp vhosts framework.

Personally, I can't use apache and I need to use vhosts.  Not a gripe, since I'm working on an overlay ebuild to do it right myself, I just thought I'd make the observation here.  Maybe "inherit webapp" wasn't around when the first version of this ebuild came out, I don't know.

Anyway, I just wanted to point out that I, for one, can't use a cgi-related ebuild that isn't httpd-agnostic and webapp-compliant.  I would think there are (or will be) others in this boat.

I don't think an ebuild with these problems should be in the tree as it is.  Even if it gets there, I would hope it would not be made stable in this condition.

Just my $0.02.
Comment 31 Sebastian Flothow 2009-06-10 21:18:59 UTC
That's a good point, I hadn't thought about that. OTOH, I presume we have existing users of ZoneMinder, and the only ebuilds currently in the tree are hardmasked for security issues. For this reason I still think we should put the current ebuild in the tree (unstable, yes) - given that the older ebuilds are not webapp-aware either, it will be useful for most or all existing users of ZoneMinder on Gentoo, and it won't hurt anyone.

Regarding the ebuild you're working on - care to attach it here?
Comment 32 Eric Westbrook 2009-06-10 22:33:21 UTC
> Regarding the ebuild you're working on - care to attach it here?

I'll do more than that, and happily so.

I've put it here:
http://code.google.com/p/gentoo-zoneminder/

All collaboration welcome.

It doesn't compile yet (despite the fact I can configure and compile it outside of ebuild, using what I think are [but must not be] the same configure options), but it's coming along.  I made my changes with the webapp dev guide in front of me, so I hope those parts are close to correct.  I also haven't gotten far enough yet to look at other patches like those in this thread.
Comment 33 Eric Westbrook 2009-06-11 00:13:12 UTC
Also, I think the point about hardmasking and security awareness is also well taken, and that does indeed serve the right purpose, so, cool.
Comment 34 Per Öberg 2009-07-02 11:47:51 UTC
Any updates?

Is it worth testing, I don't have that much experience on ebuilds that i can help but i can test.
 

(In reply to comment #32)
> > Regarding the ebuild you're working on - care to attach it here?
> 
> I'll do more than that, and happily so.
> 
> I've put it here:
> http://code.google.com/p/gentoo-zoneminder/
> 
> All collaboration welcome.
> 
> It doesn't compile yet (despite the fact I can configure and compile it outside
> of ebuild, using what I think are [but must not be] the same configure
> options), but it's coming along.  I made my changes with the webapp dev guide
> in front of me, so I hope those parts are close to correct.  I also haven't
> gotten far enough yet to look at other patches like those in this thread.
> 

Comment 35 Eric Westbrook 2009-07-03 20:49:42 UTC
No news here yet, sorry.  Sadly I've been busy with other things.  Let you know the first chance I have to get back to it.  Meantime, anyone who wants to help is still welcome, what I'm working with remains open for participation.
Comment 36 Ronny Bull 2009-07-09 16:55:58 UTC
Zoneminder is up to version 1.24.2 now as per the downloads page

http://www.zoneminder.com/downloads.html

Any news on an updated ebuild?

Comment 37 Thomas Anderson (tanderson) (RETIRED) gentoo-dev 2009-08-03 11:19:54 UTC
+*zoneminder-1.24.2 (03 Aug 2009)
+
+  03 Aug 2009; Thomas Anderson <gentoofan23@gentoo.org>
+  +files/1.24.2/Makefile.am.patch, +zoneminder-1.24.2.ebuild,
+  +files/1.24.2/db_upgrade_script_location.patch,
+  +files/1.24.2/zm_create.sql.in.patch,
+  +files/1.24.2/zm_remote_camera_http.patch:
+  Add www-misc/zoneminder-1.24.2; fixes bug #262019 and security bug
+  #236517.
+
Comment 38 Oo.et.oO 2009-11-03 00:19:30 UTC
i had to do two things to get this to compile/merge.

perl module load requires perl 5.10 which is masked.
i removed that requirement from the ebuild.

i also could not get this to compile, having the same issues as #26 without disabling ccache in make.conf
Comment 39 Oo.et.oO 2010-01-30 06:06:31 UTC
i'm still having the build issues with ccache turned on on amd64 and 1.24.2-r2

i don't see a different bug for that.  i'd like this re-opened