Date: Friday, August 26, 2011 @ 05:20:34
  Author: tpowa
Revision: 136321

archrelease: copy trunk to extra-i686, extra-x86_64

Added:
  xarchiver/repos/extra-i686/PKGBUILD
    (from rev 136320, xarchiver/trunk/PKGBUILD)
  xarchiver/repos/extra-i686/xarchiver-0.5.2-fix_7z_support.patch
    (from rev 136320, xarchiver/trunk/xarchiver-0.5.2-fix_7z_support.patch)
  xarchiver/repos/extra-i686/xarchiver-0.5.2-rpm2cpio.patch
    (from rev 136320, xarchiver/trunk/xarchiver-0.5.2-rpm2cpio.patch)
  xarchiver/repos/extra-i686/xarchiver-0.5.2-segfault-open-with.patch
    (from rev 136320, xarchiver/trunk/xarchiver-0.5.2-segfault-open-with.patch)
  xarchiver/repos/extra-i686/xarchiver.install
    (from rev 136320, xarchiver/trunk/xarchiver.install)
  xarchiver/repos/extra-x86_64/PKGBUILD
    (from rev 136320, xarchiver/trunk/PKGBUILD)
  xarchiver/repos/extra-x86_64/xarchiver-0.5.2-fix_7z_support.patch
    (from rev 136320, xarchiver/trunk/xarchiver-0.5.2-fix_7z_support.patch)
  xarchiver/repos/extra-x86_64/xarchiver-0.5.2-rpm2cpio.patch
    (from rev 136320, xarchiver/trunk/xarchiver-0.5.2-rpm2cpio.patch)
  xarchiver/repos/extra-x86_64/xarchiver-0.5.2-segfault-open-with.patch
    (from rev 136320, xarchiver/trunk/xarchiver-0.5.2-segfault-open-with.patch)
  xarchiver/repos/extra-x86_64/xarchiver.install
    (from rev 136320, xarchiver/trunk/xarchiver.install)
Deleted:
  xarchiver/repos/extra-i686/PKGBUILD
  xarchiver/repos/extra-i686/xarchiver.install
  xarchiver/repos/extra-x86_64/PKGBUILD
  xarchiver/repos/extra-x86_64/xarchiver.install

-------------------------------------------------------+
 extra-i686/PKGBUILD                                   |  128 +++++++---------
 extra-i686/xarchiver-0.5.2-fix_7z_support.patch       |  110 +++++++++++++
 extra-i686/xarchiver-0.5.2-rpm2cpio.patch             |   84 ++++++++++
 extra-i686/xarchiver-0.5.2-segfault-open-with.patch   |   15 +
 extra-i686/xarchiver.install                          |   24 +--
 extra-x86_64/PKGBUILD                                 |  128 +++++++---------
 extra-x86_64/xarchiver-0.5.2-fix_7z_support.patch     |  110 +++++++++++++
 extra-x86_64/xarchiver-0.5.2-rpm2cpio.patch           |   84 ++++++++++
 extra-x86_64/xarchiver-0.5.2-segfault-open-with.patch |   15 +
 extra-x86_64/xarchiver.install                        |   24 +--
 10 files changed, 562 insertions(+), 160 deletions(-)

Deleted: extra-i686/PKGBUILD
===================================================================
--- extra-i686/PKGBUILD 2011-08-26 09:18:46 UTC (rev 136320)
+++ extra-i686/PKGBUILD 2011-08-26 09:20:34 UTC (rev 136321)
@@ -1,68 +0,0 @@
-# $Id$
-# Maintainer: Alexander Fehr <pizzapunk gmail com>
-# Contributor: Andrew Simmons <andrew.simm...@gmail.com>
-
-pkgname=xarchiver
-pkgver=0.5.2
-pkgrel=3
-pkgdesc="GTK+ frontend to various command line archivers"
-arch=('i686' 'x86_64')
-url="http://xarchiver.sourceforge.net";
-license=('GPL')
-groups=('xfce4-goodies')
-depends=('gtk2' 'desktop-file-utils' 'hicolor-icon-theme')
-makedepends=('intltool')
-optdepends=('tar: TAR support'
-            'gzip: GZIP support'
-            'bzip2: BZIP2 support'
-            'zip: ZIP support'
-            'unzip: ZIP support'
-            'unrar: RAR support'
-            'p7zip: 7z support'
-            'arj: ARJ support'
-            'lha: LHA support'
-            'lzma-utils: LZMA support'
-            'lzop: LZOP support'
-            'xz: XZ support')
-options=('!libtool')
-install=xarchiver.install
-source=(http://downloads.sourceforge.net/xarchiver/xarchiver-$pkgver.tar.bz2
-        # add_xz_support.patch by Robby Workman taken from
-        # 
http://slackbuilds.org/slackbuilds/13.1/system/xarchiver/xarchiver-0.5.2-add_xz_support.patch
-        # sent upstream through
-        # 
https://sourceforge.net/tracker/?func=detail&aid=2847624&group_id=140153&atid=745600
-        xarchiver-0.5.2-add_xz_support.patch
-        # rpm2cpio.patch by Daniel Hokka Zakrisson
-        # taken from https://bugzilla.redhat.com/show_bug.cgi?id=577480
-        # sent upstream through
-        # 
https://sourceforge.net/tracker/?func=detail&aid=3310768&group_id=140153&atid=745602
-        xarchiver-0.5.2-rpm2cpio.patch
-        # segfault-open-with.patch by Bastiaan Jacques
-        # taken from https://bugzilla.redhat.com/show_bug.cgi?id=690012
-        # sent upstream through
-        # 
https://sourceforge.net/tracker/?func=detail&aid=3310778&group_id=140153&atid=745600
-        xarchiver-0.5.2-segfault-open-with.patch
-        # fix-7z-support.patch by taken from
-        # 
https://sourceforge.net/tracker/?func=detail&aid=3137589&group_id=140153&atid=745602
-        xarchiver-0.5.2-fix_7z_support.patch)
-md5sums=('2bc7f06403cc6582dd4a8029ec9d038d'
-         '3db8e4d1131c04b48363903a0376aba3'
-         'd4a1accdbba2b50e5707097dd3548d7a'
-         'f9036a44157b318cbc59ed012b04974b'
-         '782f55c1f1021dc02c7739bf8a47336e')
-
-build() {
-  cd "$srcdir/xarchiver-$pkgver"
-  #patches taken from: http://pkgs.fedoraproject.org/gitweb/?p=xarchiver.git
-  patch -Np1 -i ../xarchiver-0.5.2-add_xz_support.patch
-  patch -Np1 -i ../xarchiver-0.5.2-rpm2cpio.patch
-  patch -Np1 -i ../xarchiver-0.5.2-segfault-open-with.patch
-  patch -Np1 -i ../xarchiver-0.5.2-fix_7z_support.patch
-  ./configure --prefix=/usr --libexecdir=/usr/lib/xfce4
-  make
-}
-
-package() {
-  cd "$srcdir/xarchiver-$pkgver"
-  make DESTDIR="$pkgdir" install
-}

Copied: xarchiver/repos/extra-i686/PKGBUILD (from rev 136320, 
xarchiver/trunk/PKGBUILD)
===================================================================
--- extra-i686/PKGBUILD                         (rev 0)
+++ extra-i686/PKGBUILD 2011-08-26 09:20:34 UTC (rev 136321)
@@ -0,0 +1,60 @@
+# $Id$
+# Maintainer: Alexander Fehr <pizzapunk gmail com>
+# Contributor: Andrew Simmons <andrew.simm...@gmail.com>
+
+pkgname=xarchiver
+pkgver=0.5.2
+pkgrel=4
+pkgdesc="GTK+ frontend to various command line archivers"
+arch=('i686' 'x86_64')
+url="http://xarchiver.sourceforge.net";
+license=('GPL')
+groups=('xfce4-goodies')
+depends=('gtk2' 'desktop-file-utils' 'hicolor-icon-theme')
+makedepends=('intltool')
+optdepends=('tar: TAR support'
+            'gzip: GZIP support'
+            'bzip2: BZIP2 support'
+            'zip: ZIP support'
+            'unzip: ZIP support'
+            'unrar: RAR support'
+            'p7zip: 7z support'
+            'arj: ARJ support'
+            'lha: LHA support'
+            'lzma-utils: LZMA support'
+            'lzop: LZOP support')
+options=('!libtool')
+install=xarchiver.install
+source=(http://downloads.sourceforge.net/xarchiver/xarchiver-$pkgver.tar.bz2
+        # rpm2cpio.patch by Daniel Hokka Zakrisson
+        # taken from https://bugzilla.redhat.com/show_bug.cgi?id=577480
+        # sent upstream through
+        # 
https://sourceforge.net/tracker/?func=detail&aid=3310768&group_id=140153&atid=745602
+        xarchiver-0.5.2-rpm2cpio.patch
+        # segfault-open-with.patch by Bastiaan Jacques
+        # taken from https://bugzilla.redhat.com/show_bug.cgi?id=690012
+        # sent upstream through
+        # 
https://sourceforge.net/tracker/?func=detail&aid=3310778&group_id=140153&atid=745600
+        xarchiver-0.5.2-segfault-open-with.patch
+        # fix-7z-support.patch by taken from
+        # 
https://sourceforge.net/tracker/?func=detail&aid=3137589&group_id=140153&atid=745602
+        xarchiver-0.5.2-fix_7z_support.patch)
+md5sums=('2bc7f06403cc6582dd4a8029ec9d038d'
+         'd4a1accdbba2b50e5707097dd3548d7a'
+         'f9036a44157b318cbc59ed012b04974b'
+         '782f55c1f1021dc02c7739bf8a47336e')
+
+build() {
+  cd "$srcdir/xarchiver-$pkgver"
+  #patches taken from: http://pkgs.fedoraproject.org/gitweb/?p=xarchiver.git
+  patch -Np1 -i ../xarchiver-0.5.2-rpm2cpio.patch
+  patch -Np1 -i ../xarchiver-0.5.2-segfault-open-with.patch
+  patch -Np1 -i ../xarchiver-0.5.2-fix_7z_support.patch
+  ./configure --prefix=/usr --libexecdir=/usr/lib/xfce4
+  make
+}
+
+package() {
+  cd "$srcdir/xarchiver-$pkgver"
+  make DESTDIR="$pkgdir" install
+}

Copied: xarchiver/repos/extra-i686/xarchiver-0.5.2-fix_7z_support.patch (from 
rev 136320, xarchiver/trunk/xarchiver-0.5.2-fix_7z_support.patch)
===================================================================
--- extra-i686/xarchiver-0.5.2-fix_7z_support.patch                             
(rev 0)
+++ extra-i686/xarchiver-0.5.2-fix_7z_support.patch     2011-08-26 09:20:34 UTC 
(rev 136321)
@@ -0,0 +1,110 @@
+diff -Nur xarchiver-0.5.2.orig/src/7zip.c xarchiver-0.5.2/src/7zip.c
+--- xarchiver-0.5.2.orig/src/7zip.c    2008-10-25 00:41:17.000000000 +1300
++++ xarchiver-0.5.2/src/7zip.c 2010-12-15 11:24:26.000000000 +1300
+@@ -64,15 +64,14 @@
+       XEntry *entry;
+       gchar *filename;
+       gpointer item[5];
+-      gint linesize = 0,n = 0,a = 0;
+-      gboolean dir = FALSE;
++      gint linesize = 0,a = 0;
+ 
+       if (last_line)
+               return;
+ 
+       if (jump_header == FALSE)
+       {
+-              if (line[0] == '-')
++              if ((line[0] == '-') && (line[3] != NULL)) 
+               {
+                       jump_header = TRUE;
+                       return;
+@@ -93,71 +92,42 @@
+       item[4] = line;
+ 
+       /* Time */
+-      for(n=13; n < linesize; ++n)
+-              if(line[n] == ' ')
+-                      break;
+-      line[n] = '\0';
++      line[19] = '\0';
+       item[3] = line + 11;
+-      a = ++n;
+       
+       /* Permissions */
+-      for(; n < linesize; n++)
+-              if(line[n] == ' ')
+-                      break;
+-      line[n] = '\0';
+-      if ((line+a)[0] == 'D')
+-              dir = TRUE;
+-      item[2] = line + a;
++      line[25] = '\0';
++      item[2] = line + 20;
+       
+       /* Size */
+-      for(++n; n < linesize; ++n)
+-              if(line[n] >= '0' && line[n] <= '9')
++      for(a=26; a < linesize; ++a)
++              if(line[a] >= '0' && line[a] <= '9')
+                       break;
+-      a = n;
+ 
+-      for(; n < linesize; ++n)
+-              if(line[n] == ' ')
+-                      break;
+-
+-      line[n] = '\0';
++      line[38] = '\0';
+       item[0] = line + a;
+       archive->dummy_size += g_ascii_strtoull(item[0],NULL,0);
+ 
+       /* Compressed */
+-      for(++n; n < linesize; ++n)
+-              if(line[n] >= '0' && line[n] <= '9')
+-                      break;
+-      a = n;
+-
+-      for(; n < linesize; ++n)
+-              if(line[n] == ' ')
+-                      break;
+-
+-      line[n] = '\0';
+-
+-      if (line[50] != ' ')
++      /* Is this item solid? */
++      if (line[50] == ' ')
+       {
+-              n+=2;
+-              item[1] = line + a;
+               line[linesize-1] = '\0';
+-              filename = g_strdup(line + n);
++              filename = g_strdup(line + 53);
+       }
+-      /* Is this a solid archive? */
++
+       else
+       {
+-              item[1] = "0";
+-              line[n-1] = '\0';
++              for(a=39; a < linesize; ++a)
++                      if(line[a] >= '0' && line[a] <= '9')
++                              break;
++
++              line[51] = '\0';
++              item[1] = line + a;
++              line[linesize-1] = '\0';
+               filename = g_strdup(line + 53);
+       }
+ 
+-      /* Work around for 7za which doesn't
+-      * output / with directories */
+-      if (dir)
+-      {
+-              gchar *filename_with_slash = g_strconcat (filename,"/",NULL);
+-              g_free (filename);
+-              filename = filename_with_slash;
+-      }
+       entry = xa_set_archive_entries_for_each_row (archive,filename,item);
+       g_free(filename);
+ }

Copied: xarchiver/repos/extra-i686/xarchiver-0.5.2-rpm2cpio.patch (from rev 
136320, xarchiver/trunk/xarchiver-0.5.2-rpm2cpio.patch)
===================================================================
--- extra-i686/xarchiver-0.5.2-rpm2cpio.patch                           (rev 0)
+++ extra-i686/xarchiver-0.5.2-rpm2cpio.patch   2011-08-26 09:20:34 UTC (rev 
136321)
@@ -0,0 +1,84 @@
+diff -up ./src/rpm.c.rpm2cpio ./src/rpm.c
+--- ./src/rpm.c.rpm2cpio       2008-10-24 13:43:04.000000000 +0200
++++ ./src/rpm.c        2011-03-27 03:14:20.225742237 +0200
+@@ -23,11 +23,8 @@ extern gboolean batch_mode;
+ 
+ void xa_open_rpm (XArchive *archive)
+ {
+-      unsigned char bytes[8];
+       unsigned short int i;
+-    int dl,il,sigsize,offset,response;
+-    gchar *ibs,*executable;
+-    gchar *gzip_tmp = NULL;
++    int response;
+       GSList *list = NULL;
+       FILE *stream;
+       gboolean result;
+@@ -56,66 +53,14 @@ void xa_open_rpm (XArchive *archive)
+               archive->column_types[i] = types[i];
+ 
+       xa_create_liststore (archive,names);
+-    if (fseek ( stream, 104 , SEEK_CUR ) )
+-    {
+-        fclose (stream);
+-        response = xa_show_message_dialog (GTK_WINDOW 
(xa_main_window),GTK_DIALOG_MODAL,GTK_MESSAGE_ERROR,GTK_BUTTONS_OK,_("Can't 
fseek to position 104:"),g_strerror(errno));
+-        return;
+-    }
+-    if ( fread ( bytes, 1, 8, stream ) == 0 )
+-      {
+-              fclose ( stream );
+-              response = xa_show_message_dialog (GTK_WINDOW 
(xa_main_window),GTK_DIALOG_MODAL,GTK_MESSAGE_ERROR,GTK_BUTTONS_OK,_("Can't 
read data from file:"),g_strerror(errno));
+-              return;
+-    }
+-    il = 256 * ( 256 * ( 256 * bytes[0] + bytes[1]) + bytes[2] ) + bytes[3];
+-    dl = 256 * ( 256 * ( 256 * bytes[4] + bytes[5]) + bytes[6] ) + bytes[7];
+-    sigsize = 8 + 16 * il + dl;
+-    offset = 104 + sigsize + ( 8 - ( sigsize % 8 ) ) % 8 + 8;
+-    if (fseek ( stream, offset  , SEEK_SET ) )
+-    {
+-        fclose (stream);
+-        response = xa_show_message_dialog (GTK_WINDOW 
(xa_main_window),GTK_DIALOG_MODAL,GTK_MESSAGE_ERROR,GTK_BUTTONS_OK,_("Can't 
fseek in file:"),g_strerror(errno));
+-        return;
+-    }
+-    if ( fread ( bytes, 1, 8, stream ) == 0 )
+-      {
+-              fclose ( stream );
+-              response = xa_show_message_dialog (GTK_WINDOW 
(xa_main_window),GTK_DIALOG_MODAL,GTK_MESSAGE_ERROR,GTK_BUTTONS_OK,_("Can't 
read data from file:"),g_strerror(errno));
+-              return;
+-    }
+-    il = 256 * ( 256 * ( 256 * bytes[0] + bytes[1]) + bytes[2] ) + bytes[3];
+-    dl = 256 * ( 256 * ( 256 * bytes[4] + bytes[5]) + bytes[6] ) + bytes[7];
+-      sigsize = 8 + 16 * il + dl;
+-      offset = offset + sigsize;
+-      fclose (stream);
+ 
+       /* Create a unique temp dir in /tmp */
+       result = xa_create_temp_directory (archive);
+       if (!result)
+               return;
+ 
+-      gzip_tmp = g_strconcat (archive->tmp,"/file.gz_bz",NULL);
+-      ibs = g_strdup_printf ( "%u" , offset );
+-
+       /* Now I run dd to have the bzip2 / gzip compressed cpio archive in 
/tmp */
+-      gchar *command = g_strconcat ( "dd if=",archive->escaped_path," 
ibs=",ibs," skip=1 of=",gzip_tmp,NULL);
+-      g_free (ibs);
+-      list = g_slist_append(list,command);
+-      batch_mode = TRUE;
+-      result = xa_run_command (archive,list);
+-      if (result == FALSE)
+-      {       
+-              g_free (gzip_tmp);
+-              return;
+-      }
+-      if (xa_detect_archive_type (gzip_tmp) == XARCHIVETYPE_GZIP)
+-              executable = "gzip -dc ";
+-      else
+-              executable = "bzip2 -dc ";
+-
+-      command = g_strconcat("sh -c \"",executable,gzip_tmp," > 
",archive->tmp,"/file.cpio\"",NULL);
+-      g_free(gzip_tmp);
++      gchar *command = g_strconcat ( "sh -c \"rpm2cpio 
",archive->escaped_path," > ",archive->tmp, "/file.cpio\"",NULL);
+       list = NULL;
+       list = g_slist_append(list,command);
+       result = xa_run_command (archive,list);

Copied: xarchiver/repos/extra-i686/xarchiver-0.5.2-segfault-open-with.patch 
(from rev 136320, xarchiver/trunk/xarchiver-0.5.2-segfault-open-with.patch)
===================================================================
--- extra-i686/xarchiver-0.5.2-segfault-open-with.patch                         
(rev 0)
+++ extra-i686/xarchiver-0.5.2-segfault-open-with.patch 2011-08-26 09:20:34 UTC 
(rev 136321)
@@ -0,0 +1,15 @@
+diff -pur xarchiver-0.5.2/src/open-with-dlg.c 
xarchiver-0.5.2.new/src/open-with-dlg.c
+--- xarchiver-0.5.2/src/open-with-dlg.c        2008-10-17 14:06:03.000000000 
+0200
++++ xarchiver-0.5.2.new/src/open-with-dlg.c    2011-05-16 21:48:49.042839556 
+0200
+@@ -289,7 +289,10 @@ static void xa_open_with_dialog_selectio
+       GtkTreeIter iter;
+       GtkTreeModel *model;
+ 
+-      gtk_tree_selection_get_selected(selection,&model,&iter);
++      if (!gtk_tree_selection_get_selected(selection,&model,&iter)) {
++              return;
++      }
++
+       gtk_tree_model_get(model,&iter,2,&exec,-1);
+       
+       gtk_entry_set_text(GTK_ENTRY(data->custom_command_entry),exec);

Deleted: extra-i686/xarchiver.install
===================================================================
--- extra-i686/xarchiver.install        2011-08-26 09:18:46 UTC (rev 136320)
+++ extra-i686/xarchiver.install        2011-08-26 09:20:34 UTC (rev 136321)
@@ -1,12 +0,0 @@
-post_install() {
-  update-desktop-database -q
-  gtk-update-icon-cache -q -t -f usr/share/icons/hicolor
-}
-
-post_upgrade() {
-  post_install
-}
-
-post_remove() {
-  post_install
-}

Copied: xarchiver/repos/extra-i686/xarchiver.install (from rev 136320, 
xarchiver/trunk/xarchiver.install)
===================================================================
--- extra-i686/xarchiver.install                                (rev 0)
+++ extra-i686/xarchiver.install        2011-08-26 09:20:34 UTC (rev 136321)
@@ -0,0 +1,12 @@
+post_install() {
+  update-desktop-database -q
+  gtk-update-icon-cache -q -t -f usr/share/icons/hicolor
+}
+
+post_upgrade() {
+  post_install
+}
+
+post_remove() {
+  post_install
+}

Deleted: extra-x86_64/PKGBUILD
===================================================================
--- extra-x86_64/PKGBUILD       2011-08-26 09:18:46 UTC (rev 136320)
+++ extra-x86_64/PKGBUILD       2011-08-26 09:20:34 UTC (rev 136321)
@@ -1,68 +0,0 @@
-# $Id$
-# Maintainer: Alexander Fehr <pizzapunk gmail com>
-# Contributor: Andrew Simmons <andrew.simm...@gmail.com>
-
-pkgname=xarchiver
-pkgver=0.5.2
-pkgrel=3
-pkgdesc="GTK+ frontend to various command line archivers"
-arch=('i686' 'x86_64')
-url="http://xarchiver.sourceforge.net";
-license=('GPL')
-groups=('xfce4-goodies')
-depends=('gtk2' 'desktop-file-utils' 'hicolor-icon-theme')
-makedepends=('intltool')
-optdepends=('tar: TAR support'
-            'gzip: GZIP support'
-            'bzip2: BZIP2 support'
-            'zip: ZIP support'
-            'unzip: ZIP support'
-            'unrar: RAR support'
-            'p7zip: 7z support'
-            'arj: ARJ support'
-            'lha: LHA support'
-            'lzma-utils: LZMA support'
-            'lzop: LZOP support'
-            'xz: XZ support')
-options=('!libtool')
-install=xarchiver.install
-source=(http://downloads.sourceforge.net/xarchiver/xarchiver-$pkgver.tar.bz2
-        # add_xz_support.patch by Robby Workman taken from
-        # 
http://slackbuilds.org/slackbuilds/13.1/system/xarchiver/xarchiver-0.5.2-add_xz_support.patch
-        # sent upstream through
-        # 
https://sourceforge.net/tracker/?func=detail&aid=2847624&group_id=140153&atid=745600
-        xarchiver-0.5.2-add_xz_support.patch
-        # rpm2cpio.patch by Daniel Hokka Zakrisson
-        # taken from https://bugzilla.redhat.com/show_bug.cgi?id=577480
-        # sent upstream through
-        # 
https://sourceforge.net/tracker/?func=detail&aid=3310768&group_id=140153&atid=745602
-        xarchiver-0.5.2-rpm2cpio.patch
-        # segfault-open-with.patch by Bastiaan Jacques
-        # taken from https://bugzilla.redhat.com/show_bug.cgi?id=690012
-        # sent upstream through
-        # 
https://sourceforge.net/tracker/?func=detail&aid=3310778&group_id=140153&atid=745600
-        xarchiver-0.5.2-segfault-open-with.patch
-        # fix-7z-support.patch by taken from
-        # 
https://sourceforge.net/tracker/?func=detail&aid=3137589&group_id=140153&atid=745602
-        xarchiver-0.5.2-fix_7z_support.patch)
-md5sums=('2bc7f06403cc6582dd4a8029ec9d038d'
-         '3db8e4d1131c04b48363903a0376aba3'
-         'd4a1accdbba2b50e5707097dd3548d7a'
-         'f9036a44157b318cbc59ed012b04974b'
-         '782f55c1f1021dc02c7739bf8a47336e')
-
-build() {
-  cd "$srcdir/xarchiver-$pkgver"
-  #patches taken from: http://pkgs.fedoraproject.org/gitweb/?p=xarchiver.git
-  patch -Np1 -i ../xarchiver-0.5.2-add_xz_support.patch
-  patch -Np1 -i ../xarchiver-0.5.2-rpm2cpio.patch
-  patch -Np1 -i ../xarchiver-0.5.2-segfault-open-with.patch
-  patch -Np1 -i ../xarchiver-0.5.2-fix_7z_support.patch
-  ./configure --prefix=/usr --libexecdir=/usr/lib/xfce4
-  make
-}
-
-package() {
-  cd "$srcdir/xarchiver-$pkgver"
-  make DESTDIR="$pkgdir" install
-}

Copied: xarchiver/repos/extra-x86_64/PKGBUILD (from rev 136320, 
xarchiver/trunk/PKGBUILD)
===================================================================
--- extra-x86_64/PKGBUILD                               (rev 0)
+++ extra-x86_64/PKGBUILD       2011-08-26 09:20:34 UTC (rev 136321)
@@ -0,0 +1,60 @@
+# $Id$
+# Maintainer: Alexander Fehr <pizzapunk gmail com>
+# Contributor: Andrew Simmons <andrew.simm...@gmail.com>
+
+pkgname=xarchiver
+pkgver=0.5.2
+pkgrel=4
+pkgdesc="GTK+ frontend to various command line archivers"
+arch=('i686' 'x86_64')
+url="http://xarchiver.sourceforge.net";
+license=('GPL')
+groups=('xfce4-goodies')
+depends=('gtk2' 'desktop-file-utils' 'hicolor-icon-theme')
+makedepends=('intltool')
+optdepends=('tar: TAR support'
+            'gzip: GZIP support'
+            'bzip2: BZIP2 support'
+            'zip: ZIP support'
+            'unzip: ZIP support'
+            'unrar: RAR support'
+            'p7zip: 7z support'
+            'arj: ARJ support'
+            'lha: LHA support'
+            'lzma-utils: LZMA support'
+            'lzop: LZOP support')
+options=('!libtool')
+install=xarchiver.install
+source=(http://downloads.sourceforge.net/xarchiver/xarchiver-$pkgver.tar.bz2
+        # rpm2cpio.patch by Daniel Hokka Zakrisson
+        # taken from https://bugzilla.redhat.com/show_bug.cgi?id=577480
+        # sent upstream through
+        # 
https://sourceforge.net/tracker/?func=detail&aid=3310768&group_id=140153&atid=745602
+        xarchiver-0.5.2-rpm2cpio.patch
+        # segfault-open-with.patch by Bastiaan Jacques
+        # taken from https://bugzilla.redhat.com/show_bug.cgi?id=690012
+        # sent upstream through
+        # 
https://sourceforge.net/tracker/?func=detail&aid=3310778&group_id=140153&atid=745600
+        xarchiver-0.5.2-segfault-open-with.patch
+        # fix-7z-support.patch by taken from
+        # 
https://sourceforge.net/tracker/?func=detail&aid=3137589&group_id=140153&atid=745602
+        xarchiver-0.5.2-fix_7z_support.patch)
+md5sums=('2bc7f06403cc6582dd4a8029ec9d038d'
+         'd4a1accdbba2b50e5707097dd3548d7a'
+         'f9036a44157b318cbc59ed012b04974b'
+         '782f55c1f1021dc02c7739bf8a47336e')
+
+build() {
+  cd "$srcdir/xarchiver-$pkgver"
+  #patches taken from: http://pkgs.fedoraproject.org/gitweb/?p=xarchiver.git
+  patch -Np1 -i ../xarchiver-0.5.2-rpm2cpio.patch
+  patch -Np1 -i ../xarchiver-0.5.2-segfault-open-with.patch
+  patch -Np1 -i ../xarchiver-0.5.2-fix_7z_support.patch
+  ./configure --prefix=/usr --libexecdir=/usr/lib/xfce4
+  make
+}
+
+package() {
+  cd "$srcdir/xarchiver-$pkgver"
+  make DESTDIR="$pkgdir" install
+}

Copied: xarchiver/repos/extra-x86_64/xarchiver-0.5.2-fix_7z_support.patch (from 
rev 136320, xarchiver/trunk/xarchiver-0.5.2-fix_7z_support.patch)
===================================================================
--- extra-x86_64/xarchiver-0.5.2-fix_7z_support.patch                           
(rev 0)
+++ extra-x86_64/xarchiver-0.5.2-fix_7z_support.patch   2011-08-26 09:20:34 UTC 
(rev 136321)
@@ -0,0 +1,110 @@
+diff -Nur xarchiver-0.5.2.orig/src/7zip.c xarchiver-0.5.2/src/7zip.c
+--- xarchiver-0.5.2.orig/src/7zip.c    2008-10-25 00:41:17.000000000 +1300
++++ xarchiver-0.5.2/src/7zip.c 2010-12-15 11:24:26.000000000 +1300
+@@ -64,15 +64,14 @@
+       XEntry *entry;
+       gchar *filename;
+       gpointer item[5];
+-      gint linesize = 0,n = 0,a = 0;
+-      gboolean dir = FALSE;
++      gint linesize = 0,a = 0;
+ 
+       if (last_line)
+               return;
+ 
+       if (jump_header == FALSE)
+       {
+-              if (line[0] == '-')
++              if ((line[0] == '-') && (line[3] != NULL)) 
+               {
+                       jump_header = TRUE;
+                       return;
+@@ -93,71 +92,42 @@
+       item[4] = line;
+ 
+       /* Time */
+-      for(n=13; n < linesize; ++n)
+-              if(line[n] == ' ')
+-                      break;
+-      line[n] = '\0';
++      line[19] = '\0';
+       item[3] = line + 11;
+-      a = ++n;
+       
+       /* Permissions */
+-      for(; n < linesize; n++)
+-              if(line[n] == ' ')
+-                      break;
+-      line[n] = '\0';
+-      if ((line+a)[0] == 'D')
+-              dir = TRUE;
+-      item[2] = line + a;
++      line[25] = '\0';
++      item[2] = line + 20;
+       
+       /* Size */
+-      for(++n; n < linesize; ++n)
+-              if(line[n] >= '0' && line[n] <= '9')
++      for(a=26; a < linesize; ++a)
++              if(line[a] >= '0' && line[a] <= '9')
+                       break;
+-      a = n;
+ 
+-      for(; n < linesize; ++n)
+-              if(line[n] == ' ')
+-                      break;
+-
+-      line[n] = '\0';
++      line[38] = '\0';
+       item[0] = line + a;
+       archive->dummy_size += g_ascii_strtoull(item[0],NULL,0);
+ 
+       /* Compressed */
+-      for(++n; n < linesize; ++n)
+-              if(line[n] >= '0' && line[n] <= '9')
+-                      break;
+-      a = n;
+-
+-      for(; n < linesize; ++n)
+-              if(line[n] == ' ')
+-                      break;
+-
+-      line[n] = '\0';
+-
+-      if (line[50] != ' ')
++      /* Is this item solid? */
++      if (line[50] == ' ')
+       {
+-              n+=2;
+-              item[1] = line + a;
+               line[linesize-1] = '\0';
+-              filename = g_strdup(line + n);
++              filename = g_strdup(line + 53);
+       }
+-      /* Is this a solid archive? */
++
+       else
+       {
+-              item[1] = "0";
+-              line[n-1] = '\0';
++              for(a=39; a < linesize; ++a)
++                      if(line[a] >= '0' && line[a] <= '9')
++                              break;
++
++              line[51] = '\0';
++              item[1] = line + a;
++              line[linesize-1] = '\0';
+               filename = g_strdup(line + 53);
+       }
+ 
+-      /* Work around for 7za which doesn't
+-      * output / with directories */
+-      if (dir)
+-      {
+-              gchar *filename_with_slash = g_strconcat (filename,"/",NULL);
+-              g_free (filename);
+-              filename = filename_with_slash;
+-      }
+       entry = xa_set_archive_entries_for_each_row (archive,filename,item);
+       g_free(filename);
+ }

Copied: xarchiver/repos/extra-x86_64/xarchiver-0.5.2-rpm2cpio.patch (from rev 
136320, xarchiver/trunk/xarchiver-0.5.2-rpm2cpio.patch)
===================================================================
--- extra-x86_64/xarchiver-0.5.2-rpm2cpio.patch                         (rev 0)
+++ extra-x86_64/xarchiver-0.5.2-rpm2cpio.patch 2011-08-26 09:20:34 UTC (rev 
136321)
@@ -0,0 +1,84 @@
+diff -up ./src/rpm.c.rpm2cpio ./src/rpm.c
+--- ./src/rpm.c.rpm2cpio       2008-10-24 13:43:04.000000000 +0200
++++ ./src/rpm.c        2011-03-27 03:14:20.225742237 +0200
+@@ -23,11 +23,8 @@ extern gboolean batch_mode;
+ 
+ void xa_open_rpm (XArchive *archive)
+ {
+-      unsigned char bytes[8];
+       unsigned short int i;
+-    int dl,il,sigsize,offset,response;
+-    gchar *ibs,*executable;
+-    gchar *gzip_tmp = NULL;
++    int response;
+       GSList *list = NULL;
+       FILE *stream;
+       gboolean result;
+@@ -56,66 +53,14 @@ void xa_open_rpm (XArchive *archive)
+               archive->column_types[i] = types[i];
+ 
+       xa_create_liststore (archive,names);
+-    if (fseek ( stream, 104 , SEEK_CUR ) )
+-    {
+-        fclose (stream);
+-        response = xa_show_message_dialog (GTK_WINDOW 
(xa_main_window),GTK_DIALOG_MODAL,GTK_MESSAGE_ERROR,GTK_BUTTONS_OK,_("Can't 
fseek to position 104:"),g_strerror(errno));
+-        return;
+-    }
+-    if ( fread ( bytes, 1, 8, stream ) == 0 )
+-      {
+-              fclose ( stream );
+-              response = xa_show_message_dialog (GTK_WINDOW 
(xa_main_window),GTK_DIALOG_MODAL,GTK_MESSAGE_ERROR,GTK_BUTTONS_OK,_("Can't 
read data from file:"),g_strerror(errno));
+-              return;
+-    }
+-    il = 256 * ( 256 * ( 256 * bytes[0] + bytes[1]) + bytes[2] ) + bytes[3];
+-    dl = 256 * ( 256 * ( 256 * bytes[4] + bytes[5]) + bytes[6] ) + bytes[7];
+-    sigsize = 8 + 16 * il + dl;
+-    offset = 104 + sigsize + ( 8 - ( sigsize % 8 ) ) % 8 + 8;
+-    if (fseek ( stream, offset  , SEEK_SET ) )
+-    {
+-        fclose (stream);
+-        response = xa_show_message_dialog (GTK_WINDOW 
(xa_main_window),GTK_DIALOG_MODAL,GTK_MESSAGE_ERROR,GTK_BUTTONS_OK,_("Can't 
fseek in file:"),g_strerror(errno));
+-        return;
+-    }
+-    if ( fread ( bytes, 1, 8, stream ) == 0 )
+-      {
+-              fclose ( stream );
+-              response = xa_show_message_dialog (GTK_WINDOW 
(xa_main_window),GTK_DIALOG_MODAL,GTK_MESSAGE_ERROR,GTK_BUTTONS_OK,_("Can't 
read data from file:"),g_strerror(errno));
+-              return;
+-    }
+-    il = 256 * ( 256 * ( 256 * bytes[0] + bytes[1]) + bytes[2] ) + bytes[3];
+-    dl = 256 * ( 256 * ( 256 * bytes[4] + bytes[5]) + bytes[6] ) + bytes[7];
+-      sigsize = 8 + 16 * il + dl;
+-      offset = offset + sigsize;
+-      fclose (stream);
+ 
+       /* Create a unique temp dir in /tmp */
+       result = xa_create_temp_directory (archive);
+       if (!result)
+               return;
+ 
+-      gzip_tmp = g_strconcat (archive->tmp,"/file.gz_bz",NULL);
+-      ibs = g_strdup_printf ( "%u" , offset );
+-
+       /* Now I run dd to have the bzip2 / gzip compressed cpio archive in 
/tmp */
+-      gchar *command = g_strconcat ( "dd if=",archive->escaped_path," 
ibs=",ibs," skip=1 of=",gzip_tmp,NULL);
+-      g_free (ibs);
+-      list = g_slist_append(list,command);
+-      batch_mode = TRUE;
+-      result = xa_run_command (archive,list);
+-      if (result == FALSE)
+-      {       
+-              g_free (gzip_tmp);
+-              return;
+-      }
+-      if (xa_detect_archive_type (gzip_tmp) == XARCHIVETYPE_GZIP)
+-              executable = "gzip -dc ";
+-      else
+-              executable = "bzip2 -dc ";
+-
+-      command = g_strconcat("sh -c \"",executable,gzip_tmp," > 
",archive->tmp,"/file.cpio\"",NULL);
+-      g_free(gzip_tmp);
++      gchar *command = g_strconcat ( "sh -c \"rpm2cpio 
",archive->escaped_path," > ",archive->tmp, "/file.cpio\"",NULL);
+       list = NULL;
+       list = g_slist_append(list,command);
+       result = xa_run_command (archive,list);

Copied: xarchiver/repos/extra-x86_64/xarchiver-0.5.2-segfault-open-with.patch 
(from rev 136320, xarchiver/trunk/xarchiver-0.5.2-segfault-open-with.patch)
===================================================================
--- extra-x86_64/xarchiver-0.5.2-segfault-open-with.patch                       
        (rev 0)
+++ extra-x86_64/xarchiver-0.5.2-segfault-open-with.patch       2011-08-26 
09:20:34 UTC (rev 136321)
@@ -0,0 +1,15 @@
+diff -pur xarchiver-0.5.2/src/open-with-dlg.c 
xarchiver-0.5.2.new/src/open-with-dlg.c
+--- xarchiver-0.5.2/src/open-with-dlg.c        2008-10-17 14:06:03.000000000 
+0200
++++ xarchiver-0.5.2.new/src/open-with-dlg.c    2011-05-16 21:48:49.042839556 
+0200
+@@ -289,7 +289,10 @@ static void xa_open_with_dialog_selectio
+       GtkTreeIter iter;
+       GtkTreeModel *model;
+ 
+-      gtk_tree_selection_get_selected(selection,&model,&iter);
++      if (!gtk_tree_selection_get_selected(selection,&model,&iter)) {
++              return;
++      }
++
+       gtk_tree_model_get(model,&iter,2,&exec,-1);
+       
+       gtk_entry_set_text(GTK_ENTRY(data->custom_command_entry),exec);

Deleted: extra-x86_64/xarchiver.install
===================================================================
--- extra-x86_64/xarchiver.install      2011-08-26 09:18:46 UTC (rev 136320)
+++ extra-x86_64/xarchiver.install      2011-08-26 09:20:34 UTC (rev 136321)
@@ -1,12 +0,0 @@
-post_install() {
-  update-desktop-database -q
-  gtk-update-icon-cache -q -t -f usr/share/icons/hicolor
-}
-
-post_upgrade() {
-  post_install
-}
-
-post_remove() {
-  post_install
-}

Copied: xarchiver/repos/extra-x86_64/xarchiver.install (from rev 136320, 
xarchiver/trunk/xarchiver.install)
===================================================================
--- extra-x86_64/xarchiver.install                              (rev 0)
+++ extra-x86_64/xarchiver.install      2011-08-26 09:20:34 UTC (rev 136321)
@@ -0,0 +1,12 @@
+post_install() {
+  update-desktop-database -q
+  gtk-update-icon-cache -q -t -f usr/share/icons/hicolor
+}
+
+post_upgrade() {
+  post_install
+}
+
+post_remove() {
+  post_install
+}

Reply via email to