Install Open MQ 4.4 on Mac OS X 10.6 (Snow Leopard)

Intro

Snow Leopard comes with a native 64 bit Java 1.6 environment. The Open MQ binaries are made for the JDK 1.5 in 32 bit. This article shows how to make Open MQ work on OS X 1.6 by compiling from source.

Steps

  • Set environment
    export JAVA_HOME=/System/Library/Frameworks/JavaVM.framework/Home
    export ANT_HOME=$HOME/apache-ant-1.7.1
    export ANT_OPTS=-Xmx512m
    export IMQ_HOME=$HOME/mq/dist/mq
    export CLASSPATH=$CLASSPATH:$IMQ_HOME/lib/jms.jar:$IMQ_HOME/lib/imq.jar
  • Download and unpack ant in your home directory
  • Download and uppack OpenMQ 4.4 source in your home directory
  • Create extlib:
    mkdir ~/mq/extlib
  • Download the Java EE 5 API into extlib:

    http://download.java.net/maven/1/javaee/jars/javaee-api-5.jar

  • Compile Open MQ:
    cd ~/mq
    ant
  • Test Open MQ:
    cd dist/mq/bin
    ./imqbrokerd -tty &
    cd ../examples/helloworld/helloworldmessage
    java HelloWorldMessage
    You should see
    Sending Message: Hello World
    Read Message: Hello World
    And some debug messages on the imqbrokerd console.

References

This entry was posted in Java and tagged . Bookmark the permalink.

NewPush has solutions to fit your business needs.  For more than a decade, our focus has been to take on the technical challenges that are the hardest and most time-consumming.  Our goal is to free up your resources to focus on the core activities of your business and to drive your business performance.  Please visit our main site at newpush.com for more information or call us at +1-303-423-4500.