installing the sup MUA on 64bit arch linux 1

Posted by lloyd Thu, 24 Sep 2009 16:52:00 GMT

You’ll probably get here from a google search on trying to figure out how to get sup running on your arch box that was recently upgraded to ruby 1.9. sure it hurts, but it’s progress! Pick a different distro if you don’t wanna play!

Getting sup running, quick and dirty and highly time dependent:

installing the ferret gem

gem install sup will fail miserably, first you’ll find that “ferret” isn’t installing. This problem has been solved, sure would be nice to get this accepted up stream :/

installing ncurses

try again, now ncurses ain’t installing!

here’s some steps that should work:

 
$ gem fetch ncurses
$ gem unpack ncurses-0.9.1.gem 
$ ruby extconf.rb 
$ patch -p1 < ~/ncurses_ruby_1.9.patch
$ make
$ sudo make install

Here’s the contents of ncurses_ruby_1.9.patch:

--- ncurses-0.9.1.orig/form_wrap.c    2009-09-24 10:53:41.000000000 -0600
+++ ncurses-0.9.1/form_wrap.c    2009-09-24 10:52:02.000000000 -0600
@@ -392,7 +392,7 @@
  */
 static VALUE rbncurs_m_new_form(VALUE dummy, VALUE rb_field_array)
 {
-  long n = RARRAY(rb_field_array)->len;
+  long n = RARRAY_LEN(rb_field_array);
   /* Will ncurses free this array? If not, must do it after calling free_form(). */
   FIELD** fields = ALLOC_N(FIELD*, (n+1));
   long i;  
@@ -616,7 +616,7 @@
         rb_raise(rb_eArgError, "TYPE_ENUM requires three additional arguments");
      }
     else {
-        int n = RARRAY(arg3)->len;
+        int n = RARRAY_LEN(arg3);
         /*  Will ncurses free this array of strings in free_field()? */
         char** list = ALLOC_N(char*, n+1);
         int i;
@@ -775,7 +775,7 @@
  * form_field
  */
 static VALUE rbncurs_c_set_form_fields(VALUE rb_form, VALUE rb_field_array) {
-  long n = RARRAY(rb_field_array)->len;
+  long n = RARRAY_LEN(rb_field_array);
   /*  If ncurses does not free memory used by the previous array of strings, */
   /*  we will have to do it now. */
   FIELD** fields = ALLOC_N(FIELD*, (n+1));
@@ -1123,7 +1123,7 @@
      VALUE argc = rb_funcall(proc, rb_intern("arity"),0);
      VALUE args = get_proc(field, FIELDTYPE_ARGS);
      if (args != Qnil) {        
-        if (NUM2INT(argc)-1 != RARRAY(args)->len) {    
+       if (NUM2INT(argc)-1 != RARRAY_LEN(args)) {    
           char msg[500];
           snprintf(msg, 500, "The validation functions for this field type need %d additional arguments.",NUM2INT(argc)-1);
           msg[499]=0;

the rest…

First, clone yourself a copy of sup from the gitorius hosted repo:

git clone git://gitorious.org/sup/mainline.git
And follow the instructions:
  1. install all gems referenced in the rakefile
  2. as the author suggests ruby -I lib bin/sup

Behold! It starts! Now is it actually usable is another question…

chromium on 64 bit (arch) linux

Posted by lloyd Fri, 11 Sep 2009 20:22:00 GMT

Really not much to write about, it was trivial to do, and feels a hell of a lot faster than the burning fox. Steps?

First, grab the latest build from the chrome buildbot.

Second, probably notice that the chrome binary won’t run for you… missing shared libs? Heeey, me too! Apparently we’re building with certain debug libs here. use @ldd@ to figger out what’s missin, and go create some symlinks:

[lth@clover chrome-linux]$ ldd chrome | egrep \\.[0-9]d 
    libnss3.so.1d => /usr/lib/libnss3.so.1d (0x00007fe64a846000)
    libnssutil3.so.1d => /usr/lib/libnssutil3.so.1d (0x00007fe64a628000)
    libsmime3.so.1d => /usr/lib/libsmime3.so.1d (0x00007fe64a3fd000)
    libssl3.so.1d => /usr/lib/libssl3.so.1d (0x00007fe64a1cd000)
    libplds4.so.0d => /usr/lib/libplds4.so.0d (0x00007fe649fca000)
    libplc4.so.0d => /usr/lib/libplc4.so.0d (0x00007fe649dc6000)
    libnspr4.so.0d => /usr/lib/libnspr4.so.0d (0x00007fe649b8a000)

Sunspider reports on my box chromium’s js performance is is 4.87x faster than that of the fox. Don’t get too excited, javascript performance isn’t everything

TEST                   COMPARISON            FROM                 TO             DETAILS

=============================================================================

** TOTAL **:           4.87x as fast     2619.0ms +/- 1.2%   537.6ms +/- 2.0%     significant

=============================================================================

  3d:                  3.57x as fast      327.4ms +/- 2.5%    91.8ms +/- 10.1%     significant
    cube:              3.59x as fast      117.0ms +/- 1.1%    32.6ms +/- 22.7%     significant
    morph:             3.52x as fast      112.0ms +/- 5.7%    31.8ms +/- 14.2%     significant
    raytrace:          3.59x as fast       98.4ms +/- 2.3%    27.4ms +/- 4.1%     significant

  access:              10.9x as fast      451.8ms +/- 1.4%    41.4ms +/- 3.4%     significant
    binary-trees:      17.5x as fast       38.4ms +/- 1.8%     2.2ms +/- 25.3%     significant
    fannkuch:          14.1x as fast      206.4ms +/- 1.2%    14.6ms +/- 4.7%     significant
    nbody:             7.44x as fast      148.8ms +/- 0.9%    20.0ms +/- 4.4%     significant
    nsieve:            12.7x as fast       58.2ms +/- 7.5%     4.6ms +/- 14.8%     significant

  bitops:              8.84x as fast      367.6ms +/- 3.6%    41.6ms +/- 1.6%     significant
    3bit-bits-in-byte: 13.9x as fast       47.2ms +/- 1.2%     3.4ms +/- 20.0%     significant
    bits-in-byte:      9.29x as fast       83.6ms +/- 7.6%     9.0ms +/- 9.8%     significant
    bitwise-and:       11.1x as fast      135.0ms +/- 7.0%    12.2ms +/- 4.6%     significant
    nsieve-bits:       5.99x as fast      101.8ms +/- 2.6%    17.0ms +/- 0.0%     significant

  controlflow:         13.2x as fast       39.6ms +/- 2.8%     3.0ms +/- 0.0%     significant
    recursive:         13.2x as fast       39.6ms +/- 2.8%     3.0ms +/- 0.0%     significant

  crypto:              5.11x as fast      160.4ms +/- 0.9%    31.4ms +/- 4.5%     significant
    aes:               6.08x as fast       64.4ms +/- 1.7%    10.6ms +/- 10.5%     significant
    md5:               4.44x as fast       46.2ms +/- 1.2%    10.4ms +/- 6.5%     significant
    sha1:              4.79x as fast       49.8ms +/- 1.1%    10.4ms +/- 6.5%     significant

  date:                2.33x as fast      175.0ms +/- 2.8%    75.2ms +/- 3.9%     significant
    format-tofte:      2.59x as fast       79.4ms +/- 4.9%    30.6ms +/- 6.2%     significant
    format-xparb:      2.14x as fast       95.6ms +/- 1.5%    44.6ms +/- 3.2%     significant

  math:                5.58x as fast      325.8ms +/- 3.0%    58.4ms +/- 3.6%     significant
    cordic:            5.49x as fast      125.2ms +/- 2.4%    22.8ms +/- 4.6%     significant
    partial-sums:      5.55x as fast      134.4ms +/- 4.7%    24.2ms +/- 4.3%     significant
    spectral-norm:     5.81x as fast       66.2ms +/- 4.1%    11.4ms +/- 6.0%     significant

  regexp:              18.0x as fast      223.8ms +/- 7.9%    12.4ms +/- 5.5%     significant
    dna:               18.0x as fast      223.8ms +/- 7.9%    12.4ms +/- 5.5%     significant

  string:              3.00x as fast      547.6ms +/- 3.2%   182.4ms +/- 3.0%     significant
    base64:            2.57x as fast       48.8ms +/- 3.3%    19.0ms +/- 8.0%     significant
    fasta:             4.20x as fast      138.6ms +/- 1.2%    33.0ms +/- 2.7%     significant
    tagcloud:          3.20x as fast      114.6ms +/- 2.9%    35.8ms +/- 2.9%     significant
    unpack-code:       2.88x as fast      174.8ms +/- 9.7%    60.6ms +/- 8.7%     significant
    validate-input:    2.08x as fast       70.8ms +/- 2.9%    34.0ms +/- 2.6%     significant

–ll