Couchbase
  • Why NoSQL?
  • Couchbase Server
  • Download
  • Resources
  • Careers
Home | Forums | SDKs | SDKs

couchbase php, mac, nginx

10 replies [Last post]
  • Login or register to post comments
Mon, 06/18/2012 - 09:40
janim007
Offline
Joined: 06/18/2012
Groups: None

Hello
i'm trying since 3 days to make couchbase client works for nginx on mac for php
i have installed couchbase server for mac
i have compiled libcouchbase with libvbucket manually
added couchbase.so on php.ini and this is the error im getting when try to run php-cgi:

HP Warning:  PHP Startup: Unable to load dynamic library '/opt/local/etc/php5/modules/couchbase.so' - dlopen(/opt/local/etc/php5/modules/couchbase.so, 9): Library not loaded: /usr/local/lib/libcouchbase.1.dylib
  Referenced from: /opt/local/etc/php5/modules/couchbase.so
  Reason: Incompatible library version: couchbase.so requires version 6.0.0 or later, but libcouchbase.1.dylib provides version 4.0.0 in Unknown on line 0

and when try to run php script and call new couchbase instance i'm getting php Fatal error: Class 'Couchbase' not found in ..

please any help !

thanks

Top
  • Login or register to post comments
Mon, 06/18/2012 - 10:46
janim007
Offline
Joined: 06/18/2012
Groups: None

any one please !

Top
  • Login or register to post comments
Tue, 06/26/2012 - 09:29
spassas
Offline
Joined: 06/26/2012
Groups: None

Anyone having a clue on that?

Top
  • Login or register to post comments
Wed, 06/27/2012 - 03:45
spassas
Offline
Joined: 06/26/2012
Groups: None

Fixed. It seems it was some incompatibility with the precompiled PHP SDK. By downloading the source files and compiling locally, everything worked fine

Top
  • Login or register to post comments
Wed, 07/04/2012 - 01:14
cbuser
Offline
Joined: 07/04/2012
Groups: None

Quick followup, how did you manage to recompile the php-ext-sdk. I tried to fork from github but there is no configure script. I used git clone https://github.com/couchbase/php-ext-couchbase.git. The instructions show that you have to configure make and make install.

Thanks

Top
  • Login or register to post comments
Wed, 07/04/2012 - 03:03
spassas
Offline
Joined: 06/26/2012
Groups: None

Try running "phpize" before "configure". That should solve your problem.

Top
  • Login or register to post comments
Thu, 07/05/2012 - 03:35
daschl
Offline
Joined: 05/19/2012
Groups: None

There is no configure script because, as spassas said, the "phpize" command configures it for you. This is because the command checks for your local installation and configures the paths and so on (so you can run make install).

The process is as follows:

$ phpize
$ ./configure
$ make
$ make test # OPTIONAL
$ make install # as root on linux

If you encounter errors during these steps, feel free to post them here.

Regards,
Michael

Top
  • Login or register to post comments
Tue, 07/17/2012 - 03:55
bloodwolf
Offline
Joined: 07/17/2012
Groups: None

i have the same problem.
i followed your steps, but it reported errors when "make":

............couchbase-php-ext-couchbase-4609e2a/couchbase.c:1159:45: error:
unknown type name 'libcouchbase_couch_request_t'
static void php_couchbase_complete_callback(libcouchbase_couch_request_t request,

Top
  • Login or register to post comments
Tue, 07/17/2012 - 04:04
bloodwolf
Offline
Joined: 07/17/2012
Groups: None

any one could help me?
thanks!

Top
  • Login or register to post comments
Tue, 07/17/2012 - 09:50
daschl
Offline
Joined: 05/19/2012
Groups: None

Too compile the PHP extension correctly, you need to make sure you run the appropriate versions for both libcouchbase and php-ext-couchbase.

Can you tell me which version you'd want to compile (you can find that out by either checking via your repository or by runnning "cbc version").

As a starting point, you should compile the "current" version against the "current" version - and the same for "next".

I'm running libcouchbase1.1.0dp6 and php-ext-couchbase 1.1-dp2.

Regards,
Michael

Top
  • Login or register to post comments
Tue, 07/17/2012 - 18:54
bloodwolf
Offline
Joined: 07/17/2012
Groups: None

yes, the php-ext-couchbase version is newer than libcouchbase.
thanks, now i have fixed it.

Top
  • Login or register to post comments
  • Login or register to post comments
  • Login
  • Register

Company

  • About Us
  • Leadership
  • Customers
  • Partners
  • Contact Us

Product

  • Couchbase Server
  • Couchbase SDKs
  • Use Cases
  • Documentation
  • Forums

Open Source

  • Couchbase Project
  • Couchbase vs. CouchDB

Commercial

  • Subscriptions & Support
  • Training & Services

News

  • Blog
  • Newsletter
  • Press Releases
  • Buzz

Follow Us

    
  • Customer Login
  • Terms of Service
  • Privacy Policy
  • Trademark Policy
  • Site Map

© 2013 COUCHBASE All rights reserved.

Sign in to Couchbase Community

close
  • Create new account
  • Request new password
You are logging into the Forums, Wiki and Issue Tracker