[Raw Msg Headers][Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Zmailer 2.99.18 under Solaris 2.4



I am trying to compile Zmailer 2.99.18 under Solaris 2.4 with Gcc 2.7.0.

Found a problem with libmalloc/Makefile.in.  Some of the make variables have
spaces after the '=' sign, like

         RANLIB =           ranlib

This causes the Config.sed script to NOT replace this line, so on Soalris the
make would fail because ranlib would not be found.  My solution was to remove
the offending space.  Although, one could argue that the generation of the
Config.sed should be changed to allow such white space. 

The second thing I ran into is the following:

cd smtp ; make -w
make[3]: Entering directory `/opt/src/zmailer-2.99.18/transports/smtp'
gcc  -g -O -DSTDC_HEADERS -DHAVE_STRING_H -DHAVE_ALLOCA_H  -I../../include    -c smtp.c -o smtp.o
smtp.c:232: conflicting types for `atoi'
/opt/gnu/lib/gcc-lib/sparc-sun-solaris2.4/2.7.0/include/stdlib.h:77: previous declaration of `atoi'
smtp.c:233: conflicting types for `atol'
/opt/gnu/lib/gcc-lib/sparc-sun-solaris2.4/2.7.0/include/stdlib.h:78: previous declaration of `atol'
make[3]: *** [smtp.o] Error 1
make[3]: Leaving directory `/opt/src/zmailer-2.99.18/transports/smtp'

Here is a patch for transports/smtp/smtp.c.  Other things that are declared
in the 'std*.h' files should probably be inside the #if too.

RCS file: RCS/smtp.c,v
retrieving revision 1.1
diff -c -r1.1 smtp.c
*** 1.1 1995/10/08 19:03:45
--- smtp.c      1995/10/08 19:12:05
***************
*** 229,236 ****
--- 229,241 ----
  #ifndef MALLOC_TRACE
  extern univptr_t emalloc();
  #endif
+ #if   !defined(__GNUC__)
  extern int  atoi __((char*));
  extern long atol __((char*));
+ #else
+ extern int  atoi __((const char*));
+ extern long atol __((const char*));
+ #endif
  extern char *strerror();
  extern char *strchr();
  extern char *strrchr();

With these two changes it compiles cleanly.  Now to make it run.

-- Dan Ehrlich