diff options
author | Mike Frysinger <vapier@gentoo.org> | 2005-10-14 00:36:14 +0000 |
---|---|---|
committer | Mike Frysinger <vapier@gentoo.org> | 2005-10-14 00:36:14 +0000 |
commit | ce02a509daafc531f5e0aa9aa346ea1808efa8d8 (patch) | |
tree | b9a78478317e455938c8edbb2c4b41a60cf79d28 /media-video/SDLcam | |
parent | add support for USE=nls to fix uClibc systems #109143 by Jens Pranaitis (diff) | |
download | gentoo-2-ce02a509daafc531f5e0aa9aa346ea1808efa8d8.tar.gz gentoo-2-ce02a509daafc531f5e0aa9aa346ea1808efa8d8.tar.bz2 gentoo-2-ce02a509daafc531f5e0aa9aa346ea1808efa8d8.zip |
Add tsc fix by Tobias Klausmann #109161.
(Portage version: 2.0.53_rc5)
Diffstat (limited to 'media-video/SDLcam')
-rw-r--r-- | media-video/SDLcam/ChangeLog | 11 | ||||
-rw-r--r-- | media-video/SDLcam/SDLcam-0.7.3-r2.ebuild | 55 | ||||
-rw-r--r-- | media-video/SDLcam/files/SDLcam-0.7.3-prototypes.patch | 21 | ||||
-rw-r--r-- | media-video/SDLcam/files/SDLcam-0.7.3-tsc.patch | 51 | ||||
-rw-r--r-- | media-video/SDLcam/files/digest-SDLcam-0.7.3-r2 | 1 |
5 files changed, 137 insertions, 2 deletions
diff --git a/media-video/SDLcam/ChangeLog b/media-video/SDLcam/ChangeLog index 39cd74b3abfa..0c67c2b0291c 100644 --- a/media-video/SDLcam/ChangeLog +++ b/media-video/SDLcam/ChangeLog @@ -1,6 +1,13 @@ # ChangeLog for media-video/SDLcam -# Copyright 2002-2004 Gentoo Foundation; Distributed under the GPL v2 -# $Header: /var/cvsroot/gentoo-x86/media-video/SDLcam/ChangeLog,v 1.5 2004/06/25 00:49:40 agriffis Exp $ +# Copyright 1999-2005 Gentoo Foundation; Distributed under the GPL v2 +# $Header: /var/cvsroot/gentoo-x86/media-video/SDLcam/ChangeLog,v 1.6 2005/10/14 00:36:14 vapier Exp $ + +*SDLcam-0.7.3-r2 (14 Oct 2005) + + 14 Oct 2005; Mike Frysinger <vapier@gentoo.org> + +files/SDLcam-0.7.3-prototypes.patch, +files/SDLcam-0.7.3-tsc.patch, + +SDLcam-0.7.3-r2.ebuild: + Add tsc fix by Tobias Klausmann #109161. *SDLcam-0.7.3-r1 (30 Jan 2004) diff --git a/media-video/SDLcam/SDLcam-0.7.3-r2.ebuild b/media-video/SDLcam/SDLcam-0.7.3-r2.ebuild new file mode 100644 index 000000000000..744412b9c4e8 --- /dev/null +++ b/media-video/SDLcam/SDLcam-0.7.3-r2.ebuild @@ -0,0 +1,55 @@ +# Copyright 1999-2005 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Header: /var/cvsroot/gentoo-x86/media-video/SDLcam/SDLcam-0.7.3-r2.ebuild,v 1.1 2005/10/14 00:36:14 vapier Exp $ + +inherit eutils + +DESCRIPTION="Webcam application that uses the SDL library" +HOMEPAGE="http://sdlcam.raphnet.net/" +SRC_URI="http://sdlcam.raphnet.net/downloads/${P}.tar.gz" + +LICENSE="GPL-2" +SLOT="0" +KEYWORDS="~x86" +IUSE="" + +DEPEND="dev-libs/libxml2 + media-libs/libfame + media-libs/libsdl + media-libs/sdl-image + media-libs/sdl-ttf" + +src_unpack() { + unpack ${A} + cd "${S}" + epatch "${FILESDIR}"/${PV}-gcc3.patch + epatch "${FILESDIR}"/${PV}-no-divx.patch + rm capture/divx.c # the divx.so needs to be ported to newer avifile + epatch "${FILESDIR}"/${PV}-linux-2.6.patch + epatch "${FILESDIR}"/${P}-tsc.patch #109161 + epatch "${FILESDIR}"/${P}-prototypes.patch + sed -i \ + -e "s: -g: ${CFLAGS} `avifile-config --cflags`:" \ + -e 's:-Wstrict-prototypes::' \ + Makefile + sed -i "/#include/s:avifile/::" capture/divx2.cpp + + # Don't you love hardcoded vars? + sed -i \ + -e 's:/usr/local/share/SDLcam/:/usr/share/SDLcam/:' \ + -e 's:/usr/local/lib/SDLcam:/usr/lib/SDLcam:' \ + -e 's:sources/:/usr/lib/SDLcam/sources/:' \ + configuration.h interface.cpp SDL_v4l_filters.c main.cpp +} + +src_install() { + dobin SDLcam || die + insinto /usr/share/SDLcam + doins LucidaSansRegular.ttf LucidaTypewriterRegular.ttf SDLcam.xml SDLcam.cfg || die + insinto /usr/lib/SDLcam/filters + doins filter/*.so || die + insinto /usr/lib/SDLcam/capture + doins capture/*.so || die + insinto /usr/lib/SDLcam/sources + doins sources/*.so || die +} diff --git a/media-video/SDLcam/files/SDLcam-0.7.3-prototypes.patch b/media-video/SDLcam/files/SDLcam-0.7.3-prototypes.patch new file mode 100644 index 000000000000..c63678985c58 --- /dev/null +++ b/media-video/SDLcam/files/SDLcam-0.7.3-prototypes.patch @@ -0,0 +1,21 @@ +--- SDL_v4l_filters_thomas.h ++++ SDL_v4l_filters_thomas.h +@@ -18,6 +18,7 @@ + */ + #ifndef FILTER_THOMAS_H + #define FILTER_THOMAS_H ++#include <sys/types.h> + #ifdef __cplusplus + extern "C" { + #endif +@@ -29,8 +30,8 @@ + #ifdef MMX + int MMX_add_sub_shr (unsigned char *bild, unsigned char *buf, unsigned short *summe, unsigned int len, unsigned int shr); + #endif +-void yuv420p_to_rgb32(unsigned int width,unsigned int height,unsigned char *y,unsigned char *u,unsigned char *v,unsigned char *d); +-void yuv420p_to_bgr32(unsigned int width,unsigned int height,unsigned char *y,unsigned char *u,unsigned char *v,unsigned char *d); ++void yuv420p_to_rgb32(size_t width,size_t height,unsigned char *y,unsigned char *u,unsigned char *v,unsigned char *d); ++void yuv420p_to_bgr32(size_t width,size_t height,unsigned char *y,unsigned char *u,unsigned char *v,unsigned char *d); + void SDL_v4l_Reorder_cleanup (void); + int SDL_v4l_Reorder (const SDL_v4l_image *SRC, SDL_v4l_image *DST,int off_x,int off_y,int typ,int radius,double effekt); + #ifdef __cplusplus diff --git a/media-video/SDLcam/files/SDLcam-0.7.3-tsc.patch b/media-video/SDLcam/files/SDLcam-0.7.3-tsc.patch new file mode 100644 index 000000000000..807667b22a5d --- /dev/null +++ b/media-video/SDLcam/files/SDLcam-0.7.3-tsc.patch @@ -0,0 +1,51 @@ +Patch by Tobias Klausmann to fix TSC issues on Pentium M's + +http://bugs.gentoo.org/109161 + +--- misc.c ++++ misc.c +@@ -25,6 +25,11 @@ + #include "dyn_misc.h" + #include "misc.h" + ++#define rdtsc(low,high) \ ++ __asm__ __volatile__("rdtsc" : "=a" (low), "=d" (high)) ++ ++ ++ + char *xStrdup (const char *t) {{{ + char *ret; + ret = strdup (t); +@@ -42,18 +47,9 @@ + + void getTimeStampCounter ( TimeStampCounter *t ) {{{ + #ifdef TIMER +- unsigned int h=t->high; +- unsigned int l=t->low ; +- asm ( +- "push %%eax \n" +- "push %%edx \n" +- "rdtsc \n" +- "movl %%eax,%1 \n" +- "movl %%edx,%0 \n" +- "pop %%edx \n" +- "pop %%edx \n" +- : "=m" (h) , "=m" (l) +- ); ++ unsigned long h=t->high; ++ unsigned long l=t->low ; ++ rdtsc(l,h); + t->high = h; + t->low = l; + #else +--- misc.h.orig 2005-10-08 13:52:05.000000000 +0200 ++++ misc.h 2005-10-08 13:52:18.000000000 +0200 +@@ -24,7 +24,7 @@ + + char *xStrdup (const char *t); + +-typedef struct { unsigned int high, low; } TimeStampCounter; ++typedef struct { unsigned long high, low; } TimeStampCounter; + void getTimeStampCounter ( TimeStampCounter *t ); + void Start_Timer (unsigned int idx); + void Ende_Timer (unsigned int idx); diff --git a/media-video/SDLcam/files/digest-SDLcam-0.7.3-r2 b/media-video/SDLcam/files/digest-SDLcam-0.7.3-r2 new file mode 100644 index 000000000000..a9c2256dddd8 --- /dev/null +++ b/media-video/SDLcam/files/digest-SDLcam-0.7.3-r2 @@ -0,0 +1 @@ +MD5 82b7d7e7e6f4d6fe1cd2c4ab97232fd8 SDLcam-0.7.3.tar.gz 299421 |