version: 3.9.3
source: opendap.org
Libdap only seems to work when the internal regex is used. Took me a while to figure this out.
Not for Panther.
Edit xdrutil_ppc.c, xdrutils.cc, and xdrutils.h and replace:
__POWERPC__
with:
BOGUS
Edit xdr-datatypes.h and change these defs to:
#define XDR_INT32 xdr_int #define XDR_UINT32 xdr_u_int #define XDR_INT16 xdr_short #define XDR_UINT16 xdr_u_short
In the libdap source:
export MACOSX_DEPLOYMENT_TARGET=10.5 ./configure --disable-shared --disable-dependency-tracking --with-included-regex \ CFLAGS="-Os -arch ppc -arch i386 -arch ppc64 -arch x86_64" \ CXXFLAGS="-Os -arch ppc -arch i386 -arch ppc64 -arch x86_64"
Replace lines:
– the BITSIZEOF_PTRDIFF_T line with:
#ifdef __LP64__ #define BITSIZEOF_PTRDIFF_T 64 #else #define BITSIZEOF_PTRDIFF_T 32 #endif
– the BITSIZEOF_SIZE_T line with:
#ifdef __LP64__ #define BITSIZEOF_SIZE_T 64 #else #define BITSIZEOF_SIZE_T 32 #endif
– the PTRDIFF_T_SUFFIX line with:
#ifdef __LP64__ #define PTRDIFF_T_SUFFIX l #else #define PTRDIFF_T_SUFFIX #endif
– the SIZEOF_LONG line with:
#ifdef __LP64__ #define SIZEOF_LONG 8 #else #define SIZEOF_LONG 4 #endif
– the XDR_* lines with:
#define XDR_INT16 xdr_short #define XDR_INT32 xdr_int #define XDR_UINT16 xdr_u_short #define XDR_UINT32 xdr_u_int
Replace the XDR_* lines with:
#define XDR_INT16 xdr_short #define XDR_INT32 xdr_int #define XDR_UINT16 xdr_u_short #define XDR_UINT32 xdr_u_int
make sudo make install
In the libdap source:
export MACOSX_DEPLOYMENT_TARGET=10.4 ./configure --disable-shared --disable-dependency-tracking --with-included-regex \ CFLAGS="-Os -arch ppc -arch i386" CXXFLAGS="-Os -arch ppc -arch i386"
Do the same XDR_* edits as in Leopard.
make sudo make install
Libdap needs a newer version of libxml2 than is in Panther. Build a current libxml2 (no instructions here) before compiling libdap.
In the libdap source:
./configure --disable-shared --disable-dependency-tracking \ --with-included-regex CFLAGS=-Os CXXFLAGS=-Os make sudo make install