develooper Front page | perl.macosx | Postings from August 2001

Re: JPEG, PerlMagick, GD.pm (was Re: Cocoa interfaces)

Thread Previous | Thread Next
From:
Edward Moy
Date:
August 30, 2001 17:00
Subject:
Re: JPEG, PerlMagick, GD.pm (was Re: Cocoa interfaces)
Message ID:
28640F08-9DA3-11D5-919E-003065ED53B2@apple.com
On Thursday, August 30, 2001, at 01:49  PM, Timothy A. Canon wrote:

> Well, it worked without a hitch for libxml2 (v2.4.2) and XML::LibXML
> (v1.00)!
>
> When I tried to compile libxslt (v1.0.2) I got the following error:
>
> ...
> extra.c: In function `xsltFunctionLocalTime':
> extra.c:238: invalid operands to binary -
> make[2]: *** [extra.lo] Error 1
> make[1]: *** [all-recursive] Error 1
> make: *** [all-recursive-am] Error 2
> ...
>
> The timezone function being called does not appear to be compatible so I
> just deleted it.  GMT is good enough for me (we'll see how it works).
>
> Here's my diff:
>
> [localhost:~/Desktop/libxslt-1.0.2/libxslt] tacanon% diff extra.c extra.c~
> 238c238
> <     lmt = gmt;
> ---
>>     lmt = gmt - timezone;

This reminds me of htmldoc.  In ps-pdf.cxx, they also use "timezone".  It 
is defined as:

#if defined(__FreeBSD__) || defined(__OpenBSD__) || defined(__NetBSD__)
#  define timezone (doc_date->tm_gmtoff)
#endif /* __*BSD__ */

which isn't getting defined, when it should.

The clean way to fix this is to add something like -DMacOSX to the CFLAGS 
of the Makefile, and then change the #if line to:

#if defined(__FreeBSD__) || defined(__OpenBSD__) || defined(__NetBSD__) || 
defined(MacOSX)

(Or the dirty way is to just comment out the #if and #endif lines.)

> The results from all the tests seemed to go fine except:
>
> ...
> compilation error: file ./test-2.5-1.xsl line 6 element
> exciting-new-1.8-feature
> xsltStylePreCompute: unknown xsl:exciting-new-1.8-feature
> compilation error: file ./test-2.5-1.xsl line 2 element stylesheet
> xsl:version: only 1.0 features are supported
> ...
>
> Tried to install XML::LibXSLT (v1.0.9) and got the multiple definitions
> error:
>
> t/01basic...........dyld: /usr/bin/perl multiple definitions of symbol
> _make_proxy_node
> /Library/Perl/darwin/auto/XML/LibXML/LibXML.bundle definition of
> _make_proxy_node
> blib/arch/auto/XML/LibXSLT/LibXSLT.bundle definition of _make_proxy_node
> and more...

This looks like both LibXML and LibXSLT are statically loading the same 
routine, make_proxy_node().  You'll probably have to rebuild both using a 
dynamic library, so that the symbol is unique (there are probably lots of 
multiple definitions).
--------------------------------------------------------------------------
Edward Moy
Apple Computer, Inc.
emoy@apple.com

(This message is from me as a reader of this list, and not a statement
from Apple.)


Thread Previous | Thread Next


nntp.perl.org: Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at ask@perl.org | Group listing | About