Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:14643 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 28543 invoked by uid 1010); 4 Feb 2005 19:20:09 -0000 Delivered-To: ezmlm-scan-internals@lists.php.net Delivered-To: ezmlm-internals@lists.php.net Received: (qmail 28528 invoked from network); 4 Feb 2005 19:20:09 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 4 Feb 2005 19:20:09 -0000 X-Host-Fingerprint: 216.145.54.172 mrout2.yahoo.com FreeBSD 4.7-5.2 (or MacOS X 10.2-10.3) (2) Received: from ([216.145.54.172:44510] helo=mrout2.yahoo.com) by pb1.pair.com (ecelerity HEAD (r4105:4106)) with SMTP id AA/02-60887-9EAC3024 for ; Fri, 04 Feb 2005 14:20:09 -0500 Received: from bourbon.corp.yahoo.com (bourbon.corp.yahoo.com [216.145.53.135]) by mrout2.yahoo.com (8.13.1/8.13.1/y.out) with ESMTP id j14JJSdu024563; Fri, 4 Feb 2005 11:19:28 -0800 (PST) Received: (from andrei@localhost) by bourbon.corp.yahoo.com (8.12.9/8.11.1) id j14JJReJ029883; Fri, 4 Feb 2005 11:19:27 -0800 (PST) (envelope-from andrei@gravitonic.com) X-Authentication-Warning: bourbon.corp.yahoo.com: andrei set sender to andrei@gravitonic.com using -f Date: Fri, 4 Feb 2005 11:19:27 -0800 To: "D.Walsh" Cc: internals@lists.php.net Message-ID: <20050204191925.GA29843@gravitonic.com> References: <2489380dc8de3b75cd1b1a3d7eb0c200@daleenterprise.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <2489380dc8de3b75cd1b1a3d7eb0c200@daleenterprise.com> User-Agent: Mutt/1.4.1i Subject: Re: [PHP-DEV] modules/embedded function and Mac OSX From: andrei@gravitonic.com (Andrei Zmievski) Make sure it was compiled as a bundle and not as a shared library. There is a difference. Run this: % file And if it replies "Mach-O dynamically linked shared library ppc", it was compiled in the wrong way. The latest updates to build system should fix this automatically. On Fri, 04 Feb 2005, D.Walsh wrote: > I've been having some problems building some modules or embedding the > function in PHP. > > I've attempted to build several different modules and all give the same > results. > > If I build as a module, placing an 'extension=' entry in php.ini > causes a dylib error. > > dyld: /usr/sbin/httpd Undefined symbols: > __array_init > __convert_to_string > __efree > __emalloc > __estrdup > __estrndup > _add_assoc_long_ex > _add_next_index_double > _add_next_index_string > _convert_to_array > _convert_to_long > > ________________________________________________________________________ > _ > > > Without the 'extension=' entry in php.ini, placing an entry in my php > script "dl('module.so');" results in the following log entry: > > [Fri Feb 4 06:12:38 2005] [error] PHP Warning: module: Unable to > register functions, unable to load in Unknown on line 0 > > ________________________________________________________________________ > _ > > > If I use this entry in my php script, the module functions work > properly. > > if (!function_exists('my_function') && @dl('module.so')) { > } > > ________________________________________________________________________ > _ > > > Is there anything specific I need to do for Mac OSX to build modules or > embed them in PHP so they work properly? > > -- > PHP Internals - PHP Runtime Development Mailing List > To unsubscribe, visit: http://www.php.net/unsub.php - Andrei