Novell Home

OpenPGM C Reference/Build Library

From Developer Community

There are currently no official releases or pre-built packages in any distributions. The OpenPGM library must be built from source taken from the projects subversion repository.


Contents

Building in Ubuntu 8.04

First install all the C compiler dependencies, SCons, Check, and Subversion.

$ sudo apt-get install build-essential scons check subversion

Install the library dependencies, primarily GLib, libsoup, and net-snmp libraries. libncurses is only required for some examples. Note that the repository contains multiple versions of libsoup with incompatible API, libsoup-2.4 is not supported.

$ sudo apt-get install libglib2.0-dev libsoup2.2-dev libncurses5-dev libsnmp-dev check

Checkout the repository as per the Subversion guide.

$ svn checkout https://forgesvn1.novell.com/svn/openpgm/trunk

Build.

$ cd trunk/openpgm/pgm
$ scons

By default SCons is configured to build the 64-bit debug tree in ./ref/debug:

$ scons

To build the default 64-bit release version in ./ref/release use the following:

$ scons BUILD=release

For 32-bit platforms use the following and look in ./ref/thirtytwo:

$ scons BUILD=thirtytwo


Building in RHEL or CentOS 4.x

Don't, the bundled GLib revision is too old.


Building in RHEL or CentOS 5.1 or 5.2

First install the C compiler dependencies.

$ sudo yum install gcc

Install SCons by downloading the latest stable package.

$ sudo rpm -i scons-0.97-1.noarch.rpm

Install the library dependencies, primarily GLib, libsoup, and net-snmp libraries. libncurses is only required for some examples.

$ sudo yum install glib2-devel.i386 libsoup-devel.i386 ncurses-devel.i386 net-snmp-devel.i386

Red Hat net-snmp libraries are a bit chunky and need some extras:

$ sudo yum install lm_sensors-devel.i386

To download the source code Subversion is needed to contact the repository.

$ sudo yum install subversion

Checkout the repository as per the Subversion guide.

$ svn checkout https://forgesvn1.novell.com/svn/openpgm/trunk

Build.

$ cd trunk/openpgm/pgm
$ scons

By default SCons is configured to build the debug tree in ./ref/debug to build the release version in ./ref/release.

$ scons BUILD=release


Testing

Two hosts are required for testing, one to send the other to receive. In this example ayaka is the sending host and kiku is receiving.

On the receiving host run the OpenPGM receiver.

kiku$ sudo ./ref/debug/examples/pgmrecv 
** Message: pgmrecv
2008-05-27 18:02:53 kiku: scheduling startup.
2008-05-27 18:02:53 kiku: entering main event loop ... 
2008-05-27 18:02:53 kiku: startup.
2008-05-27 18:02:53 kiku: create transport.
2008-05-27 18:02:53 kiku: startup complete.

On the sending host run the OpenPGM publisher.

ayaka$ sudo ./ref/debug/examples/pgmsend mooooo baa

Then on the receiver you should see the test messages.

2008-05-27 18:03:25 kiku: (7 bytes)
2008-05-27 18:03:25 kiku: 	1: "mooooo" (7 bytes)
2008-05-27 18:03:25 kiku: (4 bytes)
2008-05-27 18:03:25 kiku: 	1: "baa" (4 bytes)

Novell® Making IT Work As One

© 2008 Novell, Inc. All Rights Reserved.