Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 9313799
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 19, 20262026-06-19T01:58:17+00:00 2026-06-19T01:58:17+00:00

I am trying to compile PHP from source with the MySQL extension as a

  • 0

I am trying to compile PHP from source with the MySQL extension as a shared library. The instructions provided by ./configure --help say:

--with-mysql=DIR      Include MySQL support.  DIR is the MySQL base directory.

However, I have no idea what they mean by MySQL base directory! Is this the directory where the mysql client executable is? (e.g. on my machine /usr/bin). Or do they mean where the shared libraries (i.e. libmysqlclient.so and libmysqlclient_r.so) are located (e.g. on my machine /usr/lib)? Or some other place? I have tried several locations, but still when I try to use the compiled version of php I get the errors like:

Call to undefined function mysql_connect()

Please help! Thanks in advance.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-19T01:58:18+00:00Added an answer on June 19, 2026 at 1:58 am

    As the ./configure –help says it is the “DIR is the MySQL base directory.

    Which would be the directory where MySQL was installed, in my case: /usr/local/mysql

    You can try:

    mysqld --verbose --help
    

    And look for the “basedir” config value

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I'm trying to compile a new instance of PHP (5.4.0) from the source code
I am trying to compile phpcompiler from source using this configure command. ./configure --prefix=/opt/phc-0.3.0.1/
I am trying to compile a latex source file from php, using exec :
I am using open source C++ library DCMTK from http://dicom.offis.de/dcmtk.php.en . I have successfully
I'm trying to compile LESS from PHP and don't want to use node.js or
I'm trying to compile php 5.4.4 on a CentOS 6.1 x64 server with --enable-dbase
I'm trying to compile Q4M ( http://q4m.31tools.com ) for MySql 5.1.44 since there is
I'm trying to upgrade from PHP 5.2.x to 5.3.2 on my server. Problem is,
Just compiled 5.3.3 from source (win32). Trying to test some header() stuff but it
I am a PHP/Mysql programmer trying to learn Java and I'm stuck on how

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.