Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:15770 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 78954 invoked by uid 1010); 3 Apr 2005 21:00:55 -0000 Delivered-To: ezmlm-scan-internals@lists.php.net Delivered-To: ezmlm-internals@lists.php.net Received: (qmail 78939 invoked from network); 3 Apr 2005 21:00:55 -0000 Received: from unknown (HELO pb1.pair.com) (127.0.0.1) by localhost with SMTP; 3 Apr 2005 21:00:55 -0000 X-Host-Fingerprint: 17.250.248.86 smtpout.mac.com FreeBSD 4.7-5.2 (or MacOS X 10.2-10.3) (1) Received: from ([17.250.248.86:62403] helo=smtpout.mac.com) by pb1.pair.com (ecelerity HEAD r(5268)) with SMTP id CC/89-19272-58950524 for ; Sun, 03 Apr 2005 17:00:53 -0400 Received: from mac.com (smtpin01-en2 [10.13.10.146]) by smtpout.mac.com (Xserve/8.12.11/smtpout04/MantshX 4.0) with ESMTP id j33L0mgC000914 for ; Sun, 3 Apr 2005 14:00:48 -0700 (PDT) Received: from [192.168.1.101] (pd95e9f5b.dip.t-dialin.net [217.94.159.91]) (authenticated bits=0) by mac.com (Xserve/smtpin01/MantshX 4.0) with ESMTP id j33L0jdY025922 for ; Sun, 3 Apr 2005 14:00:47 -0700 (PDT) Mime-Version: 1.0 (Apple Message framework v619.2) Content-Transfer-Encoding: 7bit Message-ID: Content-Type: text/plain; charset=US-ASCII; format=flowed To: internals@lists.php.net Date: Sun, 3 Apr 2005 23:00:44 +0200 X-Mailer: Apple Mail (2.619.2) Subject: os x linking issue with extension From: lastobelus@mac.com (Michael Johnston) (I'm not sure if extension development belongs on this list, but I couldn't find a better one. If there is a more appropriate list, could someone please point me to it?) I am working on an extension that is os x specific & relies on Carbon & ApplicationServices (it is a port of appscript, to allow writing applescript applications in php). I used ext_skel to create an extension, and ran phpize. In the config.m4, I put: PHP_ADD_FRAMEWORK(Carbon) PHP_ADD_INCLUDE("/Developer/Headers/FlatCarbon") but when I attempt to use carbon api I get an undefined symbol error from the dynamic linker. looking at the configure script generated by phpize, it seemed to me that the PHP_ADD_FRAMEWORK macro is not actually being used to affect the build. I attempted to change this by manually editing the configure script to add $PHP_FRAMEWORKS to the arguments passed to linktool mode=link, and added PHP_VAR_SUBST="$PHP_FRAMEWORKS". Using make --debug, I verified that linktool mode=link was now being called with the -framework param, but I still get the same undefined symbol error. I don't know much about how the dynamic linker works. What do I need to do to have extension .so link to carbon? I am using the 5.0.3 release source package of php, os x 10.3.8, gcc 3.3 Michael Johnston