I use alpine as my primary e-mail client. In order to get it compiled for Solaris 11 (snv_166 and later), you will need to make a few changes to the source.
[paulie@adrenaline ~]$ uname -orv 5.11 snv_166 Solaris [paulie@adrenaline ~]$ ./configure --with-ssl-include-dir= /usr/include/openssl [paulie@adrenaline ~]$ gmakeWe run into a problem ...
In file included from osdep.c:66: scandir.c: In function `Scandir': scandir.c:45: error: structure has no member named `dd_fd'Let's investigate:
[paulie@adrenaline ~]$ vi /usr/include/dirent.h #if defined(__USE_LEGACY_PROTOTYPES__) /* traditional SVR4 definition */ typedef struct { int dd_fd; /* file descriptor */ int dd_loc; /* offset in block */ int dd_size; /* amount of valid data */ char *dd_buf; /* directory block */ } DIR; /* stream data from opendir() #else /* default definition (POSIX conformant) */ typedef struct { int d_fd; /* file descriptor */ int d_loc; /* offset in block */ int d_size; /* amount of valid data */ char *d_buf; /* directory block */ } DIR; /* stream data from opendir() #endif /* __USE_LEGACY_PROTOTYPES__ */Interesting, so alpine *should* be using POSIX instead of the older UNIX SVR4 definitions. Let's make a change to the scandir.c file, which is located in alpine-2.00/imap/c-client/scandir.c. On line 45 I see the following use of dd_fd:
if ((!dirp) || (fstat (dirp->dd_fd,&stb) < 0)) return -1;Let's change that dd_fd to d_fd.
if ((!dirp) || (fstat (dirp->d_fd,&stb) < 0)) return -1;After recompile, everything works as expected. I'm sure there is a better way of fixing this problem, but considering how trivial this issue is, a small edit is sufficient.
8:40 PST - May 31, 2011