Re: 1.5.8 build failure on Solaris 8
> After looking through the code a bit, it looks like mutt_sasl.c ought
> to suffer a similar problem. Also I noticed that DB_ENV (DB4's
mutt_tunnel.c suffers it, too.
> handle, used by hcache.c) defines a function pointer named 'open' as
> well. Since that's supposed to work on solaris 8, there must be a
> preprocessor trick.
>
> I don't suppose you could dig a little further into exactly what's
> causing 'open' to get rewritten?
<fcntl.h>:
/* large file compilation environment setup */
#if !defined(_LP64) && _FILE_OFFSET_BITS == 64
#ifdef __PRAGMA_REDEFINE_EXTNAME
#pragma redefine_extname open open64
#pragma redefine_extname creat creat64
#else
#define open open64
#define creat creat64
#endif
#endif /* !_LP64 && _FILE_OFFSET_BITS == 64 */
I.e. _LP64 is not defined, and _FILE_OFFSET_BITS == 64 (in my case).
$ gcc -dM -E -DPKGDATADIR=\"/usr/local/share/mutt\"
-DSYSCONFDIR=\"/usr/local/etc\" -DBINDIR=\"/usr/local/bin\"
-DMUTTLOCALEDIR=\"/usr/local/share/locale\" -DHAVE_CONFIG_H=1 -I. -I. -I. -I.
-I. -I./imap -Iintl -I/usr/local/include -I/usr/local/ssl/include
-I/usr/local/include -I./intl -I/usr/local/include -Wall -pedantic -g -O2
mutt_socket.c |egrep "_LP64|_FILE_OFFSET_BITS|__PRAGMA_REDEFINE_EXTNAME"
#define _CS_XBS5_LP64_OFF64_CFLAGS 709
#define _CS_XBS5_LP64_OFF64_LIBS 711
#define _SC_XBS5_LP64_OFF64 722
#define _CS_XBS5_LP64_OFF64_LDFLAGS 710
#define _CS_XBS5_LP64_OFF64_LINTFLAGS 712
#define IOC_LP64 DATAMODEL_LP64
#define _FILE_OFFSET_BITS 64