Manuel Koch: |I use OpdenDX version 4.1.1 (downloaded from opendx.org), on a SGI IRIX 6.5 |Workstation. | |I want to write a mudule... Starting with the examples included (like |hello.c, hello_outbord.c, etc.) I found out that the libraries do not |export any symbols; only compiling the outboard version worked at all. |But when I try to execute hello_outboard, OpenDX crashes with the |eroor-message "pcreateve : Operation not permitted" and the connection to |the server is lost. ... |Is there anyone who succesfully compiled dx on an SGI with this |missing-symbols problem solved? And, of course, is there anyone who |wrote a loadable (or outboard) mudule for use on a SGI IRIX system?
I've built on SGI (4.1.0 and previous releases), and inboard, outboard, and
loadable modules all work. However there are a few build tricks. DX isn't
quite to the "configure; make; make install" point yet on IRIX, though it's
close.
With the symbols issue (sans pcreateve -- I've never seen that), you may be
hitting the /usr/lib/libz.a problem I've reported before. On SGI, /usr/lib
is o32. If you're not building o32, your build should not be looking here.
The problem is, when DX goes scavanging the system for libraries in
src/exec/Makefile, it probes /usr/lib and merges in o32 .o's from libz.a,
and this makes your DX libraries unusable (mixed architecture .a's are not
supported by IRIX ld). ld doesn't generate a symbol table, which is
probably why you find it exports no symbols, and your library is now just
taking up disk space. Extract the .o's in libDX.a (ar x libDX.a), do a
"file '*.o'", and (if that's your problem) you'll see what I mean.
Anyway, I'll back up to the beginning. Here's what I do:
---------------------------------------------------------------------------
1) CONFIGURE
env ARCH="" \
CXX="/bin/CC -n32" \
CC="/bin/cc -n32" \
SGI_ABI="-n32" \
CPPFLAGS="-w" \
CFLAGS="-O2 -w" \
CXXFLAGS="-O2 -w" \
LDFLAGS="-Wl,-n32,-rpath,/usr/local/lib32" \
configure --prefix=$HOME/software/dx-4.1.0
---------------------------------------------------------------------------
2) APPLY PATCH FOR /usr/lib MAKEFILE BUG
(See attached. Basically this just hacks the hard-coded
"/lib /usr/lib /usr/local/lib" in src/exec/Makefile to
"/lib32 /usr/lib32 /usr/local/lib32".)
---------------------------------------------------------------------------
3) MAKE
gmake # The java subtree in 4.1.0 doesn't fly with
# IRIX make, but does with GNU make
---------------------------------------------------------------------------
4) INSTALL
gmake install
---------------------------------------------------------------------------
That should do it.
A few notes on CONFIGURE.
If $ARCH is set in the environment (the default profiles on one of our
lab systems does this), DX's configure doesn't detect the platform, and
your configure is toast. Also, I may have gone overboard with the
-n32's above, but this makes very sure everything gets built for the
architecture I choose. And, we follow SGI's convention here with
/usr/{lib,lib32,lib64} for our /usr/local tree -- thus the LDFLAGS
setting. Remove if you don't need it. Finally, I build most trees to
install locally, thus the --prefix. Remove if you prefer the
default prefix.
Regarding the building of DX modules, IIRC the provided module example
makefiles were a little out-of-date for SGIs. For that reason (and just
for learning), I wrote my own Makefile.
I've attached a small source package for the hello module with a Makefile
custom-built for SGI. To test:
> make build_inboard test_inboard
> make build_outboard test_outboard
> make build_loadable test_loadable
You'll want to tweak DXROOT in the Makefile.
|I want to write a mudule to export polygon-data from dx to other
|applications.
If you just want to get polydata out of DX, you might consider whether it
would be easier to just Extract the appropriate fields (polylines,
positions, etc.), ship those off raw, and pull those into your application.
--
Randall Hopper (mailto:[EMAIL PROTECTED])
EPA Scientific Visualization Center
US EPA MD/24 ERC-1A; RTP, NC 27711
opendx_hello_module.tgz
Description: application/tar-gz
--- src/exec/ORIG/Makefile Mon Jul 31 09:01:51 2000
+++ src/exec/Makefile Wed Aug 2 10:26:01 2000
@@ -340,7 +340,7 @@
for i in $(FMT_LIBS) "" ; do \
if test "$$i" != "" ; then \
lib=""; \
- for j in /lib /usr/lib /usr/local/lib -lnsl -lsocket
-ltiff -ljpeg -lpng -lz -ldl -lm -lSM -lICE -lXm -lXext -lXt -lX11 -lgen ; do
\
+ for j in /lib32 /usr/lib32 /usr/local/lib32 -lnsl
-lsocket -ltiff -ljpeg -lpng -lz -ldl -lm -lSM -lICE -lXm -lXext -lXt -lX11
-lgen ; do \
k=`echo $$j | sed -e "s/-L//"` ; \
if test -f $$k/$$i ; then \
lib=$$k/$$i ; \
