changes to allow building under Mac OS X/Rhapsody
[mmh] / mts / smtp / Makefile.in
index 7d197d5..55997a4 100644 (file)
@@ -24,6 +24,7 @@ INCLUDES = -I../.. -I$(srcdir) -I$(top_srcdir)
 LORDER  = @LORDER@
 TSORT   = @TSORT@
 RANLIB  = @RANLIB@
+LIBTOOL = @LIBTOOL@
 
 COMPILE = $(CC) -c $(DEFS) $(INCLUDES) $(CFLAGS)
 
@@ -54,8 +55,12 @@ all: libsmtp.a
 
 libsmtp.a: $(OBJS)
        rm -f $@
-       ar cr $@ `$(LORDER) $(OBJS) | $(TSORT)`
-       $(RANLIB) $@
+       if test x$(LIBTOOL) != xno ; then \
+         $(LIBTOOL) -static -c $(OBJS) -o $@  ; \
+       else \
+         ar cr $@ `$(LORDER) $(OBJS) | $(TSORT)`  ; \
+         $(RANLIB) $@  ; \
+       fi 
 
 install: