badpopcorn

Launching XULRunner 1.8.1.3 on a Mac

Written by Ben on June 13, 2007 | 2 Comments

Ok. I started playing with XULRunner again, but this time on my Mac. I downloaded a Mac build; I went through the getting started page and reviewed the tutorial; I had my XUL application ready, and then started it up:

/Library/Frameworks/XUL.framework/xulrunner-bin application.ini

IT FAILED, ARG!!! The xulrunner-bin process launched and promptly exited, and I couldn’t find any debug information about why. I checked and double checked, but I didn’t find any problems with my super simple XUL application. I even purposely broke my sample XUL application to try to get an error message– but nothing.

SOLUTION: Out of a hunch, I followed the deployment instructions and packaged up a “MyApp.app” Mac application. I launched it from Finder– `open MyApp.app` also would’ve worked from the Terminal– and it worked like a charm. It’s kinda hackish to develop in MyApp.app/ subdirectories, but it works…

MacPorts and Gambit-C

Written by Ben on May 22, 2007 | 1 Comment

The Gambit-C MacPorts Portfile was finally committed a couple days ago, and I just got around to trying it out. Just do a `sudo port -d selfupdate`, and `port install gambit-c`. Worked like a charm! Great Job Arto! :)

Just a few notes about the installation for those that are trying out the examples from the Gambit-C user manual:

  • gsc needs “-l /opt/local/lib/gambit-c/_gambc” when generating link files.
  • Pass the following to gcc for gambit.h: -I/opt/local/include

Using an example taken from the users manual:

Here is for example how a program with three modules (one in C and
two in Scheme) can be built. The content of the three source files
(`m1.c’, `m2.scm’ and `m3.scm’) is:

/* File: “m1.c” */
int power_of_2 (int x) { return 1<<x; }

; File: “m2.scm”
(c-declare “extern int power_of_2 ();”)
(define pow2 (c-lambda (int) int “power_of_2″))
(define (twice x) (cons x x))

; File: “m3.scm”
(write (map twice (map pow2 ‘(1 2 3 4)))) (newline)

The compilation of the two Scheme source files can be done with
three invocations of `gsc’:

$ gsc -c m2.scm # create m2.c (note: .scm is optional)
$ gsc -c m3.scm # create m3.c (note: .scm is optional)
$ gsc -link m2.c m3.c # create the incremental link file m3_.c

We, instead, use the following command lines:

# optional compile into C files.
$ gsc -c m2.scm # create m2.c (note: .scm is optional)
$ gsc -c m3.scm # create m3.c (note: .scm is optional)
# creates the link file (m3_.c) and creates m1.c m2.c if they don’t exist.
$ gsc -link -l /opt/local/lib/gambit-c/_gambc m2 m3
# Compiles the code into a.out
gcc -I/opt/local/include m1.c m2.c m3.c m3_.c -L/opt/local/lib/gambit-c -lgambc

Geronimo!!!

Written by Ben on January 6, 2006 | Comments Off

The Apache Geronimo project has hit the 1.0 Milestone! Yay, congrats, etc etc. I’ll have to now evaluate it to see if it’s usable for my Java projects. This is very cool stuff.

Bunnies and Geeks

Written by Ben on November 6, 2005 | Comments Off

Playboy wasn’t even on a list of organizations that I would’ve pegged to support Open Source projects:

Playboy\'s Apache Mirror