Shared libraries using MakeC++sharedLib on AIX 4.1

Denis Bertini (dbertini@in2p3.fr)
Thu, 19 Feb 1998 14:15:56 +0100 (MET)



Hello,
I have tried to create a Shared Library using the exec
MakeC++sharedLib on AIX 4.1 and this is the makefile
(it does work !) that i run :

# options de compilation
ifeq ($(OS),AIX)
CXX = xlC
CXXFLAGS = -w -O -qnoro -qnoroconst -qmaxmem=-1 -I$(ROOTSYS)/include
LD = xlC
LDFLAGS = -g -w -bloadmap
endif

#
ifeq ($(OS),HP-UX)
CXXFLAGS = -w -g +a1 +Z -I$(ROOTSYS)/include
LDFLAGS = -w -g +a1 -b
LD = CC
CXX = CC
endif

#

HDRS = TTBElement.h TTBTestBench.h testbench.h
SRCS = TTBElement.C TTBTestBench.C testbench.C
OBJS = TTBElement.o TTBTestBench.o testbench.o

# load root's libs

ROOTLIBS = -L$(ROOTSYS)/lib -lRoot -lCint
LIBS = $(ROOTLIBS) -lm -lcurses
GLIBS = $(LIBS) -lXm -lXt -lX11 -lPW -lld

PROGRAM = testbench.sl
all: $(PROGRAM)
$(PROGRAM): $(OBJS)
@echo "Linking $(PROGRAM) ..."
@/bin/rm -f $(PROGRAM)
/usr/lpp/xlC/bin/makeC++SharedLib -p 1 -o $(PROGRAM)
$(LIBS) $(OBJS)
@chmod -w+x $(PROGRAM)
@echo "done"
clean:
@/bin/rm -f $(OBJS) core
###
TTBElement.o: TTBElement.h
TTBTestBench.o: TTBTestBench.h
testbench.C: TTBElement.h TTBTestBench.h
@echo "Generating dictionary ..."
@/bin/rm -f testbench*
@rootcint testbench.C -c TTBElement.h TTBTestBench.h

**************************************************************


this makefile run and create the shared object testbench.so.
On root this library can be loaded but does not implement
the new classes !

Something wrong in it ?

BERTINI Denis