From 0512cbbb55499f339b4e214e69cd5aa5b5aa7a33 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Jan=20R=C4=99korajski?= Date: Sun, 7 Oct 2012 17:20:04 +0200 Subject: [PATCH] - updated to 0.98.9 - removed obsolete patches --- amsn-libpng15.patch | 473 ------------------------------------------ amsn.spec | 41 ++-- ca-certificates.patch | 2 +- farstream.patch | 297 -------------------------- find-lang.sh | 0 useV4L2.patch | 84 -------- 6 files changed, 20 insertions(+), 877 deletions(-) delete mode 100644 amsn-libpng15.patch delete mode 100644 farstream.patch mode change 100644 => 100755 find-lang.sh delete mode 100644 useV4L2.patch diff --git a/amsn-libpng15.patch b/amsn-libpng15.patch deleted file mode 100644 index 819b801..0000000 --- a/amsn-libpng15.patch +++ /dev/null @@ -1,473 +0,0 @@ -http://pkgbuild.com/~ioni/libpng-1.5/amsn-0.98.4-libpng15.patch - ---- utils/TkCximage/src/CxImage/ximapng.cpp -+++ utils/TkCximage/src/CxImage/ximapng.cpp -@@ -15,7 +15,7 @@ - void CxImagePNG::ima_png_error(png_struct *png_ptr, char *message) - { - strcpy(info.szLastError,message); -- longjmp(png_ptr->jmpbuf, 1); -+ longjmp(png_jmpbuf(png_ptr), 1); - } - //////////////////////////////////////////////////////////////////////////////// - #if CXIMAGE_SUPPORT_DECODE -@@ -62,7 +62,7 @@ - /* Set error handling if you are using the setjmp/longjmp method (this is - * the normal method of doing things with libpng). REQUIRED unless you - * set up your own error handlers in the png_create_read_struct() earlier. */ -- if (setjmp(png_ptr->jmpbuf)) { -+ if (setjmp(png_jmpbuf(png_ptr))) { - /* Free all of the memory associated with the png_ptr and info_ptr */ - delete [] row_pointers; - png_destroy_read_struct(&png_ptr, &info_ptr, (png_infopp)NULL); -@@ -77,15 +77,15 @@ - png_read_info(png_ptr, info_ptr); - - if (info.nEscape == -1){ -- head.biWidth = info_ptr->width; -- head.biHeight= info_ptr->height; -+ head.biWidth = png_get_image_width(png_ptr, info_ptr); -+ head.biHeight= png_get_image_height(png_ptr, info_ptr); - info.dwType = CXIMAGE_FORMAT_PNG; -- longjmp(png_ptr->jmpbuf, 1); -+ longjmp(png_jmpbuf(png_ptr), 1); - } - - /* calculate new number of channels */ - int channels=0; -- switch(info_ptr->color_type){ -+ switch(png_get_color_type(png_ptr, info_ptr)){ - case PNG_COLOR_TYPE_GRAY: - case PNG_COLOR_TYPE_PALETTE: - channels = 1; -@@ -101,71 +101,76 @@ - break; - default: - strcpy(info.szLastError,"unknown PNG color type"); -- longjmp(png_ptr->jmpbuf, 1); -+ longjmp(png_jmpbuf(png_ptr), 1); - } - - //find the right pixel depth used for cximage -- int pixel_depth = info_ptr->pixel_depth; -+#if MIGHT_BE_BUGGY -+ int pixel_depth = png_get_pixel_depth(png_ptr, info_ptr); - if (channels == 1 && pixel_depth>8) pixel_depth=8; -+#endif -+ int pixel_depth; -+ if (channels == 1) pixel_depth=8; - if (channels == 2) pixel_depth=8; - if (channels >= 3) pixel_depth=24; - -- if (!Create(info_ptr->width, info_ptr->height, pixel_depth, CXIMAGE_FORMAT_PNG)){ -- longjmp(png_ptr->jmpbuf, 1); -+ if (!Create(png_get_image_width(png_ptr, info_ptr), png_get_image_height(png_ptr, info_ptr), pixel_depth, CXIMAGE_FORMAT_PNG)){ -+ longjmp(png_jmpbuf(png_ptr), 1); - } - - /* get metrics */ -- switch (info_ptr->phys_unit_type) -+ png_uint_32 res_x, res_y; -+ int unit_type; -+ png_get_pHYs_dpi(png_ptr, info_ptr, &res_x, &res_y, &unit_type); -+ switch (unit_type) - { - case PNG_RESOLUTION_UNKNOWN: -- SetXDPI(info_ptr->x_pixels_per_unit); -- SetYDPI(info_ptr->y_pixels_per_unit); -+ SetXDPI(res_x); -+ SetYDPI(res_y); - break; - case PNG_RESOLUTION_METER: -- SetXDPI((long)floor(info_ptr->x_pixels_per_unit * 254.0 / 10000.0 + 0.5)); -- SetYDPI((long)floor(info_ptr->y_pixels_per_unit * 254.0 / 10000.0 + 0.5)); -+ SetXDPI((long)floor(res_x * 254.0 / 10000.0 + 0.5)); -+ SetYDPI((long)floor(res_y * 254.0 / 10000.0 + 0.5)); - break; - } - -- if (info_ptr->num_palette>0){ -- SetPalette((rgb_color*)info_ptr->palette,info_ptr->num_palette); -- SetClrImportant(info_ptr->num_palette); -- } else if (info_ptr->bit_depth ==2) { // needed for 2 bpp grayscale PNGs -+ png_colorp palette; -+ int num_palette; -+ png_get_PLTE(png_ptr, info_ptr, &palette, &num_palette); -+ if (num_palette>0){ -+ SetPalette((rgb_color*)palette,num_palette); -+ SetClrImportant(num_palette); -+ } else if (png_get_bit_depth(png_ptr, info_ptr) ==2) { // needed for 2 bpp grayscale PNGs - SetPaletteColor(0,0,0,0); - SetPaletteColor(1,85,85,85); - SetPaletteColor(2,170,170,170); - SetPaletteColor(3,255,255,255); - } else SetGrayPalette(); // needed for grayscale PNGs - -- int nshift = max(0,(info_ptr->bit_depth>>3)-1)<<3; -+ int nshift = max(0,(png_get_bit_depth(png_ptr, info_ptr)>>3)-1)<<3; - -- if (info_ptr->num_trans!=0){ //palette transparency -- if (info_ptr->num_trans==1){ -- if (info_ptr->color_type == PNG_COLOR_TYPE_PALETTE){ --#if PNG_LIBPNG_VER_MAJOR >= 1 && PNG_LIBPNG_VER_MINOR >= 4 -- info.nBkgndIndex = info_ptr->trans_color.index; --#else -- info.nBkgndIndex = info_ptr->trans_values.index; --#endif -+png_uint_32 png_get_tRNS (png_const_structp png_ptr, png_infop -+info_ptr, png_bytep *trans_alpha, int *num_trans, png_color_16p -+*trans_color); -+ png_bytep trans_alpha; -+ int num_trans; -+ png_color_16p trans_color; -+ png_get_tRNS(png_ptr, info_ptr, &trans_alpha, &num_trans, &trans_color); -+ if (num_trans!=0){ //palette transparency -+ if (num_trans==1){ -+ if (png_get_color_type(png_ptr, info_ptr) == PNG_COLOR_TYPE_PALETTE){ -+ info.nBkgndIndex = trans_color->index; - } else{ --#if PNG_LIBPNG_VER_MAJOR >= 1 && PNG_LIBPNG_VER_MINOR >= 4 -- info.nBkgndIndex = info_ptr->trans_color.gray>>nshift; --#else -- info.nBkgndIndex = info_ptr->trans_values.gray>>nshift; --#endif -+ info.nBkgndIndex = trans_color->gray>>nshift; - } - } -- if (info_ptr->num_trans>1){ -+ if (num_trans>1){ - RGBQUAD* pal=GetPalette(); - if (pal){ - DWORD ip; -- for (ip=0;ipnum_trans);ip++) --#if PNG_LIBPNG_VER_MAJOR >= 1 && PNG_LIBPNG_VER_MINOR >= 4 -- pal[ip].rgbReserved=info_ptr->trans_alpha[ip]; --#else -- pal[ip].rgbReserved=info_ptr->trans[ip]; --#endif -- for (ip=info_ptr->num_trans;ip= 1 && PNG_LIBPNG_VER_MINOR >= 4 -- info.nBkgndColor.rgbRed = (BYTE)(info_ptr->trans_color.red>>nshift); -- info.nBkgndColor.rgbGreen = (BYTE)(info_ptr->trans_color.green>>nshift); -- info.nBkgndColor.rgbBlue = (BYTE)(info_ptr->trans_color.blue>>nshift); --#else -- info.nBkgndColor.rgbRed = (BYTE)(info_ptr->trans_values.red>>nshift); -- info.nBkgndColor.rgbGreen = (BYTE)(info_ptr->trans_values.green>>nshift); -- info.nBkgndColor.rgbBlue = (BYTE)(info_ptr->trans_values.blue>>nshift); --#endif -+ info.nBkgndColor.rgbRed = (BYTE)(trans_color->red>>nshift); -+ info.nBkgndColor.rgbGreen = (BYTE)(trans_color->green>>nshift); -+ info.nBkgndColor.rgbBlue = (BYTE)(trans_color->blue>>nshift); - info.nBkgndColor.rgbReserved = 0; - info.nBkgndIndex = 0; - } -@@ -202,15 +201,15 @@ - } - - // - flip the RGB pixels to BGR (or RGBA to BGRA) -- if (info_ptr->color_type & PNG_COLOR_MASK_COLOR){ -+ if (png_get_color_type(png_ptr, info_ptr) & PNG_COLOR_MASK_COLOR){ - png_set_bgr(png_ptr); - } - - // - handle cancel -- if (info.nEscape) longjmp(png_ptr->jmpbuf, 1); -+ if (info.nEscape) longjmp(png_jmpbuf(png_ptr), 1); - - // row_bytes is the width x number of channels x (bit-depth / 8) -- row_pointers = new BYTE[info_ptr->rowbytes + 8]; -+ row_pointers = new BYTE[png_get_rowbytes(png_ptr, info_ptr) + 8]; - - // turn on interlace handling - int number_passes = png_set_interlace_handling(png_ptr); -@@ -221,8 +220,10 @@ - SetCodecOption(0); - } - -- int chan_offset = info_ptr->bit_depth >> 3; -- int pixel_offset = info_ptr->pixel_depth >> 3; -+ int bit_depth = png_get_bit_depth(png_ptr, info_ptr); -+ int chan_offset = bit_depth >> 3; -+ //int pixel_offset = info_ptr->pixel_depth >> 3; -+ int pixel_offset = (bit_depth * channels) >> 3; - - for (int pass=0; pass < number_passes; pass++) { - iter.Upset(); -@@ -230,7 +231,7 @@ - do { - - // - handle cancel -- if (info.nEscape) longjmp(png_ptr->jmpbuf, 1); -+ if (info.nEscape) longjmp(png_jmpbuf(png_ptr), 1); - - #if CXIMAGE_SUPPORT_ALPHA // - if (AlphaIsValid()) { -@@ -241,7 +242,7 @@ - BYTE* prow= iter.GetRow(ay); - - //recover data from previous scan -- if (info_ptr->interlace_type && pass>0 && pass!=7){ -+ if (png_get_interlace_type(png_ptr, info_ptr) && pass>0 && pass!=7){ - for(ax=0;axinterlace_type && pass>0){ -- iter.GetRow(row_pointers, info_ptr->rowbytes); -+ if (png_get_interlace_type(png_ptr, info_ptr) && pass>0){ -+ iter.GetRow(row_pointers, png_get_rowbytes(png_ptr, info_ptr)); - //re-expand buffer for images with bit depth > 8 -- if (info_ptr->bit_depth > 8){ -+ if (png_get_bit_depth(png_ptr, info_ptr) > 8){ - for(long ax=(head.biWidth*channels-1);ax>=0;ax--) - row_pointers[ax*chan_offset] = row_pointers[ax]; - } -@@ -291,15 +292,15 @@ - png_read_row(png_ptr, row_pointers, NULL); - - //shrink 16 bit depth images down to 8 bits -- if (info_ptr->bit_depth > 8){ -+ if (png_get_bit_depth(png_ptr, info_ptr) > 8){ - for(long ax=0;ax<(head.biWidth*channels);ax++) - row_pointers[ax] = row_pointers[ax*chan_offset]; - } - - //copy the pixels -- iter.SetRow(row_pointers, info_ptr->rowbytes); -+ iter.SetRow(row_pointers, png_get_rowbytes(png_ptr, info_ptr)); - // expand 2 bpp images only in the last pass -- if (info_ptr->bit_depth==2 && pass==(number_passes-1)) -+ if (png_get_bit_depth(png_ptr, info_ptr)==2 && pass==(number_passes-1)) - expand2to4bpp(iter.GetRow()); - - //go on -@@ -340,6 +341,11 @@ - BYTE trans[256]; //for transparency (don't move) - png_struct *png_ptr; - png_info *info_ptr; -+ png_uint_32 width, height; -+ png_byte bit_depth; -+ png_byte color_type; -+ png_byte interlace_type; -+ BYTE channels; - - cx_try - { -@@ -362,9 +368,8 @@ - /* Set error handling. REQUIRED if you aren't supplying your own - * error hadnling functions in the png_create_write_struct() call. - */ -- if (setjmp(png_ptr->jmpbuf)){ -+ if (setjmp(png_jmpbuf(png_ptr))){ - /* If we get here, we had a problem reading the file */ -- if (info_ptr->palette) free(info_ptr->palette); - png_destroy_write_struct(&png_ptr, (png_infopp)&info_ptr); - cx_throw("Error saving PNG file"); - } -@@ -376,20 +381,18 @@ - png_set_write_fn(png_ptr,hFile,/*(png_rw_ptr)*/user_write_data,/*(png_flush_ptr)*/user_flush_data); - - /* set the file information here */ -- info_ptr->width = GetWidth(); -- info_ptr->height = GetHeight(); -- info_ptr->pixel_depth = (BYTE)GetBpp(); -- info_ptr->channels = (GetBpp()>8) ? (BYTE)3: (BYTE)1; -- info_ptr->bit_depth = (BYTE)(GetBpp()/info_ptr->channels); -- info_ptr->compression_type = info_ptr->filter_type = 0; -- info_ptr->valid = 0; -+ width = GetWidth(); -+ height = GetHeight(); -+ //pixel_depth = (BYTE)GetBpp(); -+ channels = (GetBpp()>8) ? (BYTE)3: (BYTE)1; -+ bit_depth = (BYTE)(GetBpp()/channels); - - switch(GetCodecOption(CXIMAGE_FORMAT_PNG)){ - case 1: -- info_ptr->interlace_type = PNG_INTERLACE_ADAM7; -+ interlace_type = PNG_INTERLACE_ADAM7; - break; - default: -- info_ptr->interlace_type = PNG_INTERLACE_NONE; -+ interlace_type = PNG_INTERLACE_NONE; - } - - /* set compression level */ -@@ -399,19 +402,19 @@ - - if (GetNumColors()){ - if (bGrayScale){ -- info_ptr->color_type = PNG_COLOR_TYPE_GRAY; -+ color_type = PNG_COLOR_TYPE_GRAY; - } else { -- info_ptr->color_type = PNG_COLOR_TYPE_PALETTE; -+ color_type = PNG_COLOR_TYPE_PALETTE; - } - } else { -- info_ptr->color_type = PNG_COLOR_TYPE_RGB; -+ color_type = PNG_COLOR_TYPE_RGB; - } - #if CXIMAGE_SUPPORT_ALPHA - if (AlphaIsValid()){ -- info_ptr->color_type |= PNG_COLOR_MASK_ALPHA; -- info_ptr->channels++; -- info_ptr->bit_depth = 8; -- info_ptr->pixel_depth += 8; -+ color_type |= PNG_COLOR_MASK_ALPHA; -+ channels++; -+ bit_depth = 8; -+ //pixel_depth += 8; - } - #endif - -@@ -428,29 +431,21 @@ - /* set metrics */ - png_set_pHYs(png_ptr, info_ptr, head.biXPelsPerMeter, head.biYPelsPerMeter, PNG_RESOLUTION_METER); - -- png_set_IHDR(png_ptr, info_ptr, info_ptr->width, info_ptr->height, info_ptr->bit_depth, -- info_ptr->color_type, info_ptr->interlace_type, -+ png_set_IHDR(png_ptr, info_ptr, width, height, bit_depth, -+ color_type, interlace_type, - PNG_COMPRESSION_TYPE_BASE, PNG_FILTER_TYPE_BASE); - - // simple transparency - if (info.nBkgndIndex >= 0){ -- info_ptr->num_trans = 1; -- info_ptr->valid |= PNG_INFO_tRNS; --#if PNG_LIBPNG_VER_MAJOR >= 1 && PNG_LIBPNG_VER_MINOR >= 4 -- info_ptr->trans_alpha = trans; -- info_ptr->trans_color.index = (BYTE)info.nBkgndIndex; -- info_ptr->trans_color.red = tc.rgbRed; -- info_ptr->trans_color.green = tc.rgbGreen; -- info_ptr->trans_color.blue = tc.rgbBlue; -- info_ptr->trans_color.gray = info_ptr->trans_color.index; --#else -- info_ptr->trans = trans; -- info_ptr->trans_values.index = (BYTE)info.nBkgndIndex; -- info_ptr->trans_values.red = tc.rgbRed; -- info_ptr->trans_values.green = tc.rgbGreen; -- info_ptr->trans_values.blue = tc.rgbBlue; -- info_ptr->trans_values.gray = info_ptr->trans_values.index; --#endif -+ png_color_16 trans_color; -+ -+ trans_color.index = (BYTE)info.nBkgndIndex; -+ trans_color.red = tc.rgbRed; -+ trans_color.green = tc.rgbGreen; -+ trans_color.blue = tc.rgbBlue; -+ trans_color.gray = (BYTE)info.nBkgndIndex; -+ -+ png_set_tRNS(png_ptr, info_ptr, trans, 1, &trans_color); - - // the transparency indexes start from 0 for non grayscale palette - if (!bGrayScale && head.biClrUsed && info.nBkgndIndex) -@@ -459,30 +454,27 @@ - - /* set the palette if there is one */ - if (GetPalette()){ -- if (!bGrayScale){ -- info_ptr->valid |= PNG_INFO_PLTE; -- } -- - int nc = GetClrImportant(); - if (nc==0) nc = GetNumColors(); - - if (info.bAlphaPaletteEnabled){ - for(WORD ip=0; ipnum_trans = (WORD)nc; -- info_ptr->valid |= PNG_INFO_tRNS; --#if PNG_LIBPNG_VER_MAJOR >= 1 && PNG_LIBPNG_VER_MINOR >= 4 -- info_ptr->trans_alpha = trans; --#else -- info_ptr->trans = trans; --#endif -+ png_set_tRNS(png_ptr, info_ptr, trans, (WORD)nc, NULL); - } - - // copy the palette colors -- info_ptr->palette = new png_color[nc]; -- info_ptr->num_palette = (png_uint_16) nc; -- for (int i=0; ipalette[i].red, &info_ptr->palette[i].green, &info_ptr->palette[i].blue); -+ if (!bGrayScale) { -+ png_color *palette; -+ -+ palette = (png_color *)png_malloc(png_ptr, nc*sizeof(palette[0])); -+ for (int i=0; i -@@ -496,8 +488,8 @@ - } } } - #endif // CXIMAGE_SUPPORT_ALPHA // - -- int row_size = max(info.dwEffWidth, info_ptr->width*info_ptr->channels*(info_ptr->bit_depth/8)); -- info_ptr->rowbytes = row_size; -+ int row_size = max(info.dwEffWidth, png_get_rowbytes(png_ptr, info_ptr)); -+ //info_ptr->rowbytes = row_size; - BYTE *row_pointers = new BYTE[row_size]; - - /* write the file information */ -@@ -515,7 +507,7 @@ - if (AlphaIsValid()){ - for (long ax=head.biWidth-1; ax>=0;ax--){ - c = BlindGetPixelColor(ax,ay); -- int px = ax * info_ptr->channels; -+ int px = ax * png_get_channels(png_ptr, info_ptr); - if (!bGrayScale){ - row_pointers[px++]=c.rgbRed; - row_pointers[px++]=c.rgbGreen; -@@ -530,7 +522,7 @@ - #endif //CXIMAGE_SUPPORT_ALPHA // - { - iter.GetRow(row_pointers, row_size); -- if (info_ptr->color_type == PNG_COLOR_TYPE_RGB) //HACK BY OP -+ if (png_get_color_type(png_ptr, info_ptr) == PNG_COLOR_TYPE_RGB) //HACK BY OP - RGBtoBGR(row_pointers, row_size); - png_write_row(png_ptr, row_pointers); - } -@@ -547,12 +539,6 @@ - /* It is REQUIRED to call this to finish writing the rest of the file */ - png_write_end(png_ptr, info_ptr); - -- /* if you malloced the palette, free it here */ -- if (info_ptr->palette){ -- delete [] (info_ptr->palette); -- info_ptr->palette = NULL; -- } -- - /* clean up after the write, and free any memory allocated */ - png_destroy_write_struct(&png_ptr, (png_infopp)&info_ptr); - ---- utils/TkCximage/src/CxImage/ximapng.h -+++ utils/TkCximage/src/CxImage/ximapng.h -@@ -64,8 +64,8 @@ - - static void PNGAPI user_error_fn(png_structp png_ptr,png_const_charp error_msg) - { -- strncpy((char*)png_ptr->error_ptr,error_msg,255); -- longjmp(png_ptr->jmpbuf, 1); -+ strncpy((char*)png_get_error_ptr(png_ptr),error_msg,255); -+ longjmp(png_jmpbuf(png_ptr), 1); - } - }; - diff --git a/amsn.spec b/amsn.spec index 1386c63..1d031ce 100644 --- a/amsn.spec +++ b/amsn.spec @@ -6,24 +6,22 @@ Summary(de.UTF-8): MSN Messenger-Klon für Linux Summary(fr.UTF-8): Clône MSN Messenger pour Linux Summary(pl.UTF-8): Klon MSN Messengera dla Linuksa Name: amsn -Version: 0.98.4 -Release: 7 +Version: 0.98.9 +Release: 1 License: GPL Group: Applications/Communications Source0: http://downloads.sourceforge.net/amsn/%{name}-%{version}-src.tar.gz -# Source0-md5: 3cf69c4a7773888cea854927c83b9cfb +# Source0-md5: b98f7a26df34a79b8bfade1ff2ccc88a Source1: find-lang.sh Patch0: %{name}-desktop.patch Patch1: %{name}-paths.patch -Patch2: useV4L2.patch -Patch3: %{name}-bwidget.patch -Patch4: ca-certificates.patch -Patch6: %{name}-disable-autoupdate.patch -Patch7: %{name}-libpng15.patch -Patch8: farstream.patch +Patch2: %{name}-bwidget.patch +Patch3: ca-certificates.patch +Patch4: %{name}-disable-autoupdate.patch URL: http://www.amsn-project.net/ BuildRequires: autoconf BuildRequires: farstream-devel +BuildRequires: gupnp-devel BuildRequires: gupnp-igd-devel BuildRequires: libjpeg-devel BuildRequires: libpng-devel >= 2:1.4 @@ -126,9 +124,6 @@ find -name '*.tcl' -print0 | xargs -0 sed -i -e 's,\r$,,' %patch2 -p1 %patch3 -p1 %patch4 -p1 -%patch6 -p1 -%patch7 -p0 -%patch8 -p1 %build %{__aclocal} @@ -138,6 +133,7 @@ find -name '*.tcl' -print0 | xargs -0 sed -i -e 's,\r$,,' %configure \ --enable-debug \ CFLAGS="%{rpmcflags}" + %{__make} \ verbose=yes @@ -148,7 +144,7 @@ find -name '*.tcl' -print0 | xargs -0 sed -i -e 's,\r$,,' rm -rf $RPM_BUILD_ROOT install -d $RPM_BUILD_ROOT{%{_iconsdir}/hicolor,%{_pixmapsdir},%{_desktopdir}} -%{__make} install \ +%{__make} -j1 install \ DESTDIR=$RPM_BUILD_ROOT mv $RPM_BUILD_ROOT%{_datadir}/%{name}/amsn $RPM_BUILD_ROOT%{_bindir}/amsn @@ -170,15 +166,14 @@ mv $RPM_BUILD_ROOT%{_datadir}/%{name}/amsn-remote-CLI $RPM_BUILD_ROOT%{_bindir}/ %{__rm} -r $RPM_BUILD_ROOT%{_datadir}/%{name}/lang/{*.*,LANG-HOWTO,sortlang} install -d $RPM_BUILD_ROOT%{tcl_sitearch} -mv $RPM_BUILD_ROOT%{_datadir}/%{name}/utils/linux/* $RPM_BUILD_ROOT%{tcl_sitearch} -rmdir $RPM_BUILD_ROOT%{_datadir}/%{name}/utils/linux -mv $RPM_BUILD_ROOT%{_datadir}/%{name}/utils/TkCximage $RPM_BUILD_ROOT%{tcl_sitearch} -mv $RPM_BUILD_ROOT%{_datadir}/%{name}/utils/webcamsn $RPM_BUILD_ROOT%{tcl_sitearch} -mv $RPM_BUILD_ROOT%{_datadir}/%{name}/utils/tcl_siren $RPM_BUILD_ROOT%{tcl_sitearch} -mv $RPM_BUILD_ROOT%{_datadir}/%{name}/utils/tclISF $RPM_BUILD_ROOT%{tcl_sitearch} -mv $RPM_BUILD_ROOT%{_datadir}/%{name}/utils/gupnp $RPM_BUILD_ROOT%{tcl_sitearch} -mv $RPM_BUILD_ROOT%{_datadir}/%{name}/utils/farsight $RPM_BUILD_ROOT%{tcl_sitearch} -mv $RPM_BUILD_ROOT%{_datadir}/%{name}/utils/asyncresolver $RPM_BUILD_ROOT%{tcl_sitearch} +mv $RPM_BUILD_ROOT%{_libdir}/%{name}/utils/linux/* $RPM_BUILD_ROOT%{tcl_sitearch} +mv $RPM_BUILD_ROOT%{_libdir}/%{name}/utils/TkCximage $RPM_BUILD_ROOT%{tcl_sitearch} +mv $RPM_BUILD_ROOT%{_libdir}/%{name}/utils/webcamsn $RPM_BUILD_ROOT%{tcl_sitearch} +mv $RPM_BUILD_ROOT%{_libdir}/%{name}/utils/tcl_siren $RPM_BUILD_ROOT%{tcl_sitearch} +mv $RPM_BUILD_ROOT%{_libdir}/%{name}/utils/tclISF $RPM_BUILD_ROOT%{tcl_sitearch} +mv $RPM_BUILD_ROOT%{_libdir}/%{name}/utils/gupnp $RPM_BUILD_ROOT%{tcl_sitearch} +mv $RPM_BUILD_ROOT%{_libdir}/%{name}/utils/farsight $RPM_BUILD_ROOT%{tcl_sitearch} +mv $RPM_BUILD_ROOT%{_libdir}/%{name}/utils/asyncresolver $RPM_BUILD_ROOT%{tcl_sitearch} mv $RPM_BUILD_ROOT{%{_datadir}/%{name},%{_desktopdir}}/%{name}.desktop mv $RPM_BUILD_ROOT%{_datadir}/%{name}/desktop-icons/* $RPM_BUILD_ROOT%{_iconsdir}/hicolor @@ -218,6 +213,7 @@ rm -rf $RPM_BUILD_ROOT %dir %{_datadir}/%{name} %{_datadir}/%{name}/*.tcl %{_datadir}/%{name}/hotmlog.htm +%{_datadir}/%{name}/msnp2p # langlist explains the language codes used %{_datadir}/%{name}/langlist @@ -234,6 +230,7 @@ rm -rf $RPM_BUILD_ROOT %attr(755,root,root) %{tcl_sitearch}/*/*.so %dir %{tcl_sitearch}/capture/libng %dir %{tcl_sitearch}/capture/libng/plugins +%attr(755,root,root) %{tcl_sitearch}/capture/libng/*.so %attr(755,root,root) %{tcl_sitearch}/capture/libng/plugins/*.so %files plugins -f %{name}-plugins.lang diff --git a/ca-certificates.patch b/ca-certificates.patch index 0258590..66a59cc 100644 --- a/ca-certificates.patch +++ b/ca-certificates.patch @@ -17,6 +17,6 @@ FILES_TO_INSTALL += utils/log utils/uri utils/combobox utils/voipcontrols -FILES_TO_INSTALL += utils/md4 utils/sasl ca-certs +FILES_TO_INSTALL += utils/md4 utils/sasl + FILES_TO_INSTALL += msnp2p FILES_TO_EXCLUDE := lang/genpage.c lang/addkey.tcl lang/lang1.tmpl lang/lang2.tmpl lang/lang3.tmpl lang/langchk.sh lang/complete.pl lang/genlangfiles.c - diff --git a/farstream.patch b/farstream.patch deleted file mode 100644 index f2687f6..0000000 --- a/farstream.patch +++ /dev/null @@ -1,297 +0,0 @@ -diff -up amsn-0.98.4/Compile.mk.farstream amsn-0.98.4/Compile.mk ---- amsn-0.98.4/Compile.mk.farstream 2009-10-15 04:39:25.000000000 -0400 -+++ amsn-0.98.4/Compile.mk 2012-03-09 18:04:13.304674222 -0500 -@@ -22,15 +22,15 @@ compile_m = $(CC) $(CFLAGS) -ObjC -fobj - compile_cc = $(CXX) $(CXXFLAGS) -c -o $@ $< - - ifeq ($(FOUND_OS),mac) --compile_farsight = $(CC) $(CFLAGS) -ObjC -fobjc-gc $(GST_CFLAGS) $(FARSIGHT2_CFLAGS) -c -o $@ $< -+compile_farsight = $(CC) $(CFLAGS) -ObjC -fobjc-gc $(GST_CFLAGS) $(FARSTREAM_CFLAGS) -c -o $@ $< - SHARED := -dynamiclib -fno-common -Wl,-single_module -shared-libgcc - else --compile_farsight = $(CC) $(CFLAGS) $(GST_CFLAGS) $(FARSIGHT2_CFLAGS) -c -o $@ $< -+compile_farsight = $(CC) $(CFLAGS) $(GST_CFLAGS) $(FARSTREAM_CFLAGS) -c -o $@ $< - SHARED := -shared - endif - - link_app = $(CC) $(LDFLAGS) $^ $(LDLIBS) -o $@ --link_farsight = $(CC) $(LDFLAGS) $^ $(LDLIBS) $(GST_LIBS) $(FARSIGHT2_LIBS) $(SHARED) -o $@ -+link_farsight = $(CC) $(LDFLAGS) $^ $(LDLIBS) $(GST_LIBS) $(FARSTREAM_LIBS) $(SHARED) -o $@ - link_so = $(CC) $(LDFLAGS) $^ $(LDLIBS) $(SHARED) -o $@ - link_so_addlibs = $(link_so) $(ADDLIBS) - link_so_cpp = $(CXX) $(LDFLAGS) $^ $(LDLIBS) $(CXX_LIB) $(SHARED) -o $@ -diff -up amsn-0.98.4/configure.ac.farstream amsn-0.98.4/configure.ac ---- amsn-0.98.4/configure.ac.farstream 2012-03-09 18:04:13.296674304 -0500 -+++ amsn-0.98.4/configure.ac 2012-03-09 18:04:13.305674212 -0500 -@@ -440,10 +440,10 @@ else - fi - AC_MSG_RESULT($USE_MMX) - --HAVE_FARSIGHT=no -+HAVE_FARSTREAM=no - GST_REQUIRED=0.10.22 - GST_MAJORMINOR=0.10 --FARSIGHT_REQUIRED=0.0.9 -+FARSTREAM_REQUIRED=0.1 - - dnl Check for pkgconfig first - AC_CHECK_PROG(HAVE_PKGCONFIG, pkg-config, yes, no) -@@ -467,9 +467,9 @@ if test "x$HAVE_PKGCONFIG" = "xyes"; the - - dnl Give error and exit if we don't have gstreamer - if test "x$HAVE_GST" = "xyes"; then -- PKG_CHECK_MODULES(FARSIGHT2, \ -- farsight2-$GST_MAJORMINOR >= $FARSIGHT_REQUIRED, -- HAVE_FARSIGHT=yes,HAVE_FARSIGHT=no) -+ PKG_CHECK_MODULES(FARSTREAM, \ -+ farstream-$FARSTREAM_REQUIRED, -+ HAVE_FARSTREAM=yes,HAVE_FARSTREAM=no) - fi - fi - -@@ -519,10 +519,10 @@ AC_SUBST(GST_LIBS) - AC_SUBST(GST_INTERFACES_CFLAGS) - AC_SUBST(GST_INTERFACES_LIBS) - --AC_SUBST(FARSIGHT2_CFLAGS) --AC_SUBST(FARSIGHT2_LIBS) -+AC_SUBST(FARSTREAM_CFLAGS) -+AC_SUBST(FARSTREAM_LIBS) - --AC_SUBST(HAVE_FARSIGHT) -+AC_SUBST(HAVE_FARSTREAM) - - dnl --------------------------------------------------------------------- - dnl write out stuff -@@ -540,14 +540,14 @@ compile time options summary - TK : $TK_VERSION - DEBUG : $DEBUG - STATIC : $STATIC -- FARSIGHT : $HAVE_FARSIGHT -+ FARSTREAM : $HAVE_FARSTREAM - LIBV4L : $HAVE_LIBV4L - GUPNP-IGD : $HAVE_GUPNP - - EOF - --if test x"$HAVE_FARSIGHT" = "xno"; then -- echo "*** You do not seem to have gstreamer and farsight2 installed." -+if test x"$HAVE_FARSTREAM" = "xno"; then -+ echo "*** You do not seem to have gstreamer and farstream installed." - echo "*** You will not be able to build the required component for audio conversations." - echo "*** Read this for more information : http://amsn-project.net/wiki/Farsight" - fi -diff -up amsn-0.98.4/Makefile.in.farstream amsn-0.98.4/Makefile.in ---- amsn-0.98.4/Makefile.in.farstream 2010-03-18 15:58:48.000000000 -0400 -+++ amsn-0.98.4/Makefile.in 2012-03-09 18:04:15.967646846 -0500 -@@ -127,8 +127,8 @@ endif - - GST_LIBS := @GST_LIBS@ @GST_INTERFACES_LIBS@ - GST_CFLAGS := @GST_CFLAGS@ @GST_INTERFACES_CFLAGS@ --FARSIGHT2_LIBS := @FARSIGHT2_LIBS@ --FARSIGHT2_CFLAGS := @FARSIGHT2_CFLAGS@ -+FARSTREAM_LIBS := @FARSTREAM_LIBS@ -+FARSTREAM_CFLAGS := @FARSTREAM_CFLAGS@ - - - # for gcc3 -@@ -169,7 +169,7 @@ ifeq (@HAVE_GUPNP@,yes) - FILES_TO_INSTALL += utils/gupnp/gupnp.$(SHLIB_EXTENSION) utils/gupnp/pkgIndex.tcl - endif - --ifeq (@HAVE_FARSIGHT@,yes) -+ifeq (@HAVE_FARSTREAM@,yes) - FILES_TO_INSTALL += utils/farsight/tcl_farsight.$(SHLIB_EXTENSION) utils/farsight/pkgIndex.tcl - endif - -@@ -319,7 +319,7 @@ include $(tclISF_dir)/src/Rules.mk - include $(async_dir)/Rules.mk - include $(async_dir)/src/Rules.mk - --ifeq (@HAVE_FARSIGHT@,yes) -+ifeq (@HAVE_FARSTREAM@,yes) - include $(tcl_farsight_dir)/Rules.mk - include $(tcl_farsight_dir)/src/Rules.mk - endif -diff -up amsn-0.98.4/utils/farsight/src/tcl_farsight.c.farstream amsn-0.98.4/utils/farsight/src/tcl_farsight.c ---- amsn-0.98.4/utils/farsight/src/tcl_farsight.c.farstream 2009-12-14 15:21:11.000000000 -0500 -+++ amsn-0.98.4/utils/farsight/src/tcl_farsight.c 2012-03-09 18:06:12.954448444 -0500 -@@ -14,12 +14,12 @@ - #include - - #include --#include --#include -+#include -+#include - #include - #include - --#include -+#include - - #ifdef G_OS_WIN32 - #include -@@ -1630,22 +1630,22 @@ static int Farsight_BusEventProc (Tcl_Ev - case GST_MESSAGE_ELEMENT: - { - const GstStructure *s = gst_message_get_structure (message); -- if (gst_structure_has_name (s, "farsight-error")) { -+ if (gst_structure_has_name (s, "farstream-error")) { - const GValue *errorvalue, *debugvalue, *error_no; - - error_no = gst_structure_get_value (message->structure, "error-no"); - errorvalue = gst_structure_get_value (message->structure, "error-msg"); - debugvalue = gst_structure_get_value (message->structure, "debug-msg"); - -- if (g_value_get_enum (error_no) != FS_ERROR_UNKNOWN_CNAME) { -+ if (g_value_get_enum (error_no)) { - _notify_debug ("Error on BUS (%d) %s .. %s", g_value_get_enum (error_no), - g_value_get_string (errorvalue), - g_value_get_string (debugvalue)); - } -- if (g_value_get_enum (error_no) != FS_ERROR_UNKNOWN_CNAME) { -- _notify_error ("Farsight error"); -+ if (g_value_get_enum (error_no)) { -+ _notify_error ("Farstream error"); - } -- } else if (gst_structure_has_name (s, "farsight-new-local-candidate")) { -+ } else if (gst_structure_has_name (s, "farstream-new-local-candidate")) { - FsStream *stream; - FsCandidate *candidate; - const GValue *value; -@@ -1658,7 +1658,7 @@ static int Farsight_BusEventProc (Tcl_Ev - - _new_local_candidate (stream, candidate); - } else if (gst_structure_has_name (s, -- "farsight-local-candidates-prepared")) { -+ "farstream-local-candidates-prepared")) { - FsStream *stream; - const GValue *value; - -@@ -1667,7 +1667,7 @@ static int Farsight_BusEventProc (Tcl_Ev - - - _local_candidates_prepared (stream); -- } else if (gst_structure_has_name (s, "farsight-codecs-changed")) { -+ } else if (gst_structure_has_name (s, "farstream-codecs-changed")) { - gboolean ready; - - if (!audio_codecs_ready) { -@@ -1682,7 +1682,7 @@ static int Farsight_BusEventProc (Tcl_Ev - _codecs_ready (video_session); - } - } -- } else if (gst_structure_has_name (s, "farsight-new-active-candidate-pair")) { -+ } else if (gst_structure_has_name (s, "farstream-new-active-candidate-pair")) { - FsCandidate *local; - FsCandidate *remote; - FsStream *stream; -@@ -1856,16 +1856,16 @@ _bus_callback (GstBus *bus, GstMessage * - case GST_MESSAGE_ELEMENT: - { - const GstStructure *s = gst_message_get_structure (message); -- if (gst_structure_has_name (s, "farsight-error")) { -+ if (gst_structure_has_name (s, "farstream-error")) { - goto drop; -- } else if (gst_structure_has_name (s, "farsight-new-local-candidate")) { -+ } else if (gst_structure_has_name (s, "farstream-new-local-candidate")) { - goto drop; - } else if (gst_structure_has_name (s, -- "farsight-local-candidates-prepared")) { -+ "farstream-local-candidates-prepared")) { - goto drop; -- } else if (gst_structure_has_name (s, "farsight-codecs-changed")) { -+ } else if (gst_structure_has_name (s, "farstream-codecs-changed")) { - goto drop; -- } else if (gst_structure_has_name (s, "farsight-new-active-candidate-pair")) { -+ } else if (gst_structure_has_name (s, "farstream-new-active-candidate-pair")) { - goto drop; - } else if (gst_structure_has_name (s, "level")) { - goto drop; -@@ -2918,7 +2918,7 @@ int Farsight_Prepare _ANSI_ARGS_((Client - G_CALLBACK (_conference_element_added), NULL); - - participant = fs_conference_new_participant (FS_CONFERENCE (conference), -- "", &error); -+ &error); - if (error) { - char temp[1000]; - snprintf (temp, 1000, "Error while creating new participant (%d): %s", -@@ -3157,7 +3157,14 @@ int Farsight_Prepare _ANSI_ARGS_((Client - } - - audio_stream = fs_session_new_stream (audio_session, participant, FS_DIRECTION_BOTH, -- "nice", total_params, transmitter_params, &error); -+ &error); -+ -+ if(!fs_stream_set_transmitter(audio_stream, "nice", -+ transmitter_params, total_params, &error)) { -+ char temp[1000]; -+ snprintf (temp, 1000, "Could not set transmitter \"nice\" (%d): %s.", error->code, error->message); -+ goto error; -+ } - - if (error) { - char temp[1000]; -@@ -3310,7 +3317,14 @@ int Farsight_Prepare _ANSI_ARGS_((Client - } - - video_stream = fs_session_new_stream (video_session, participant, -- FS_DIRECTION_BOTH, "nice", total_params, transmitter_params, &error); -+ FS_DIRECTION_BOTH, &error); -+ -+ if(!fs_stream_set_transmitter(video_stream, "nice", -+ transmitter_params, total_params, &error)) { -+ char temp[1000]; -+ snprintf (temp, 1000, "Could not set transmitter \"nice\" (%d): %s.", error->code, error->message); -+ goto error; -+ } - - if (error) { - char temp[1000]; -@@ -3391,7 +3405,7 @@ int Farsight_Start _ANSI_ARGS_((ClientDa - - - if (pipeline == NULL) { -- Tcl_AppendResult (interp, "Farsight needs to be prepared first", -+ Tcl_AppendResult (interp, "Farstream needs to be prepared first", - (char *) NULL); - return TCL_ERROR; - } -@@ -3568,7 +3582,7 @@ static int _SetMute (GstElement *element - if (element) { - g_object_set (element, "mute", mute, NULL); - } else { -- Tcl_AppendResult (interp, "Farsight isn't running", (char *) NULL); -+ Tcl_AppendResult (interp, "Farstream isn't running", (char *) NULL); - return TCL_ERROR; - } - -@@ -3602,7 +3616,7 @@ static int _GetMute (GstElement *element - g_object_get (element, "mute", &mute, NULL); - Tcl_SetObjResult(interp, Tcl_NewBooleanObj(mute)); - } else { -- Tcl_AppendResult (interp, "Farsight isn't running", (char *) NULL); -+ Tcl_AppendResult (interp, "Farstream isn't running", (char *) NULL); - return TCL_ERROR; - } - -@@ -3641,7 +3655,7 @@ static int _SetVolume (GstElement *eleme - if (element) { - g_object_set (element, "volume", volume, NULL); - } else { -- Tcl_AppendResult (interp, "Farsight isn't running", (char *) NULL); -+ Tcl_AppendResult (interp, "Farstream isn't running", (char *) NULL); - return TCL_ERROR; - } - -@@ -3676,7 +3690,7 @@ static int _GetVolume (GstElement *eleme - g_object_get (element, "volume", &volume, NULL); - Tcl_SetObjResult(interp, Tcl_NewDoubleObj(volume)); - } else { -- Tcl_AppendResult (interp, "Farsight isn't running", (char *) NULL); -+ Tcl_AppendResult (interp, "Farstream isn't running", (char *) NULL); - return TCL_ERROR; - } - diff --git a/find-lang.sh b/find-lang.sh old mode 100644 new mode 100755 diff --git a/useV4L2.patch b/useV4L2.patch deleted file mode 100644 index 7a55fe4..0000000 --- a/useV4L2.patch +++ /dev/null @@ -1,84 +0,0 @@ ---- amsn/configure.ac 2011/04/08 17:08:27 12314 -+++ amsn/configure.ac 2011/04/12 00:20:59 12315 -@@ -489,6 +489,11 @@ - libv4l2 >= 0.5.0, - HAVE_LIBV4L=yes,HAVE_LIBV4L=no) - fi -+ AC_CHECK_HEADERS(linux/videodev.h,HAVE_LIBV4L=yes,HAVE_LIBV4L=no) -+ AC_CHECK_HEADERS(linux/videodev2.h,HAVE_LIBV4L2=yes,HAVE_LIBV4L2=no) -+ if test x"$v4l2" = x"yes" ; then -+ HAVE_LIBV4L=yes -+ fi - AC_SUBST(HAVE_LIBV4L) - - AC_ARG_ENABLE([upnp], ---- amsn/utils/linux/capture/capture.h 2011/04/08 17:08:27 12314 -+++ amsn/utils/linux/capture/capture.h 2011/04/12 00:20:59 12315 -@@ -30,11 +30,13 @@ - - #include "config.h" - -+/* - #ifdef HAVE_SYS_VIDEODEV2_H - # include - #else - # include - #endif -+*/ - - #include "grab-ng.h" - ---- amsn/configure 2010/06/17 00:31:07 12053 -+++ amsn/configure 2011/04/12 00:43:13 12317 -@@ -597,6 +605,7 @@ - HAVE_GUPNP - GUPNP_LIBS - GUPNP_CFLAGS -+HAVE_LIBV4L2 - HAVE_LIBV4L - LIBV4L_LIBS - LIBV4L_CFLAGS -@@ -5688,6 +5697,35 @@ - HAVE_LIBV4L=yes - fi - fi -+ for ac_header in linux/videodev.h -+do : -+ ac_fn_c_check_header_mongrel "$LINENO" "linux/videodev.h" "ac_cv_header_linux_videodev_h" "$ac_includes_default" -+if test "x$ac_cv_header_linux_videodev_h" = xyes; then : -+ cat >>confdefs.h <<_ACEOF -+#define HAVE_LINUX_VIDEODEV_H 1 -+_ACEOF -+ HAVE_LIBV4L=yes -+else -+ HAVE_LIBV4L=no -+fi -+ -+done -+ -+ for ac_header in linux/videodev2.h -+do : -+ ac_fn_c_check_header_mongrel "$LINENO" "linux/videodev2.h" "ac_cv_header_linux_videodev2_h" "$ac_includes_default" -+if test "x$ac_cv_header_linux_videodev2_h" = xyes; then : -+ cat >>confdefs.h <<_ACEOF -+#define HAVE_LINUX_VIDEODEV2_H 1 -+_ACEOF -+ HAVE_LIBV4L2=yes -+else -+ HAVE_LIBV4L2=no -+fi -+ -+done -+ -+ - - - # Check whether --enable-upnp was given. -@@ -7058,6 +7124,7 @@ - STATIC : $STATIC - FARSIGHT : $HAVE_FARSIGHT - LIBV4L : $HAVE_LIBV4L -+ LIBV4L2 : $HAVE_LIBV4L2 - GUPNP-IGD : $HAVE_GUPNP - - EOF -- 2.43.0