--- Makefile.in Wed Jun 18 05:00:10 2003 +++ Makefile.in Tue Aug 5 21:26:23 2003 @@ -26,7 +26,7 @@ #Rules: major -- inc for incompatible change # : minor -- inc for bugfix or forward compatible change -LIBVERSION=1.0 +LIBVERSION=1 PATHS= @@ -35,7 +35,7 @@ CFLAGS=@CFLAGS@ CPPFLAGS=-I. -I$(srcdir) @CPPFLAGS@ $(PATHS) @DEFS@ LDFLAGS=@LDFLAGS@ -LIBS=@LIBS@ +LIBS=-L. @LIBS@ THLDFLAGS=@THLDFLAGS@ THLIBS=@THLIBS@ AR=@AR@ @@ -52,8 +52,10 @@ PERL=@PERL@ ENT=@ENT@ EXEEXT=@EXEEXT@ +SHLDSONAME=-Wl,-soname,libspread.so.$(LIBVERSION) +TSHLDSONAME=-Wl,-soname,libtspread.so.$(LIBVERSION) -TARGETS=spread$(EXEEXT) spuser$(EXEEXT) spflooder$(EXEEXT) spmonitor$(EXEEXT) sptuser${EXEEXT} @LIBSPSO@ @LIBTSPSO@ +TARGETS=spread$(EXEEXT) spuser$(EXEEXT) spflooder$(EXEEXT) spmonitor$(EXEEXT) sptuser${EXEEXT} @LIBSPSO@ @LIBTSPSO@ libspread.a libtspread.a LIBSP_OBJS= alarm.o events.o memory.o sp.o @@ -124,8 +126,11 @@ $(INSTALL) -m 0755 libspread.$(LIBVERSION).dylib $(DESTDIR)$(libdir)/libspread.$(LIBVERSION).dylib (cd $(DESTDIR)$(libdir); $(SOFTLINK) -f libspread.$(LIBVERSION).dylib libspread.dylib) -libspread.so: $(LIBSP_SHOBJS) - $(SHLD) -o $@ $(LIBSP_SHOBJS) $(SHLDFLAGS) $(SHLIBS) +libspread.so: $@.$(LIBVERSION) + $(SOFTLINK) $@.$(LIBVERSION) $@ + +libspread.so.$(LIBVERSION): $(LIBSP_SHOBJS) + $(SHLD) -o $@ $(LIBSP_SHOBJS) $(SHLDSONAME) $(SHLDFLAGS) $(SHLIBS) install-libspread.so: libspread.so $(INSTALL) -m 0755 libspread.so $(DESTDIR)$(libdir)/libspread.so.$(LIBVERSION) @@ -143,8 +148,11 @@ $(INSTALL) -m 0755 libtspread.$(LIBVERSION).dylib $(DESTDIR)$(libdir)/libtspread.$(LIBVERSION).dylib (cd $(DESTDIR)$(libdir); $(SOFTLINK) -f libtspread.$(LIBVERSION).dylib libtspread.dylib) -libtspread.so: $(LIBTSP_SHOBJS) - $(SHLD) -o $@ $(LIBTSP_SHOBJS) $(SHLDFLAGS) $(SHLIBS) $(THLIBS) +libtspread.so: $@.$(LIBVERSION) + $(SOFTLINK) $@.$(LIBVERSION) $@ + +libtspread.so.$(LIBVERSION): $(LIBTSP_SHOBJS) + $(SHLD) -o $@ $(LIBTSP_SHOBJS) $(TSHLDSONAME) $(SHLDFLAGS) $(SHLIBS) $(THLIBS) install-libtspread.so: libtspread.so $(INSTALL) -m 0755 libtspread.so $(DESTDIR)$(libdir)/libtspread.so.$(LIBVERSION) @@ -153,17 +161,17 @@ spread$(EXEEXT): $(SPREADOBJS) $(LD) -o $@ $(SPREADOBJS) $(LDFLAGS) $(LIBS) -spuser$(EXEEXT): libspread.a user.o - $(LD) -o $@ user.o $(LDFLAGS) libspread.a $(LIBS) +spuser$(EXEEXT): libspread.so user.o + $(LD) -o $@ user.o $(LDFLAGS) -lspread $(LIBS) -spflooder$(EXEEXT): libspread.a flooder.o - $(LD) -o $@ flooder.o $(LDFLAGS) libspread.a $(LIBS) +spflooder$(EXEEXT): libspread.so flooder.o + $(LD) -o $@ flooder.o $(LDFLAGS) -lspread $(LIBS) spmonitor$(EXEEXT): $(MONITOROBJS) $(LD) -o $@ $(MONITOROBJS) $(LDFLAGS) $(LIBS) -sptuser$(EXEEXT): user.to libtspread.a - $(LD) $(THLDFLAGS) -o $@ user.to libtspread.a $(LDFLAGS) $(LIBS) $(THLIBS) +sptuser$(EXEEXT): user.to libtspread.so + $(LD) $(THLDFLAGS) -o $@ user.to -ltspread $(LDFLAGS) $(LIBS) $(THLIBS) spsimple_user$(EXEEXT): simple_user.o libspread.a $(LD) -o $@ simple_user.o $(LDFLAGS) libspread.a $(LIBS) @@ -192,7 +200,7 @@ fi clean: - rm -f *.lo *.tlo *.to *.o *.a *.dylib $(TARGETS) spsimple_user + rm -f *.lo *.tlo *.to *.o *.a *.dylib $(TARGETS) spsimple_user *.so.$(LIBVERSION) rm -f config.cache config.log docs/*.out core rm -rf autom4te.cache @@ -247,11 +255,6 @@ done if [ ! -d $(DESTDIR)$(sysconfdir) ]; then \ $(buildtoolsdir)/mkinstalldirs $(DESTDIR)$(sysconfdir); \ - fi - if [ ! -f $(DESTDIR)$(sysconfdir)/spread.conf ]; then \ - $(INSTALL) -m 644 $(srcdir)/sample.spread.conf $(DESTDIR)$(sysconfdir)/spread.conf; \ - else \ - echo "$(DESTDIR)$(sysconfdir)/spread.conf already exists, install will not overwrite"; \ fi uninstallall: uninstall