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

  • SEARCH
  • Home
  • 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 515733
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 13, 20262026-05-13T07:39:30+00:00 2026-05-13T07:39:30+00:00

I’m running a database server in a Linux VM (Ubuntu 9.10) under VMware Fusion,

  • 0

I’m running a database server in a Linux VM (Ubuntu 9.10) under VMware Fusion, but coding Django on the Mac side. Installing mysql-python requires that MySQL is installed on the Mac for compiling _mysql.so into site-packages.

However, after this is done, I have no further use for MySQL on the Mac side, and would rather just delete it. Of course, this is not possible when _mysql.so requires /usr/local/mysql/lib/libmysqlclient_r.16.dylib.

There is a “static” option in mysql-python’s site.cfg, which, when set to “true”, significantly increases the size of the _mysql.so file, but it still depends on the .dylib.

Is there a way of making the .so completely independent of whether MySQL is installed or not, even if that means making the file enormous?

The solution, if one exists, should work on both 10.5 and 10.6, since I’ll be using both versions on different machines for the time being.

  • 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-05-13T07:39:30+00:00Added an answer on May 13, 2026 at 7:39 am

    Never mind, found out myself after a bit more digging. It’s pretty simple, actually; I’ll record the solution here in case someone else needs it:

    1. Get the source tarball of MySQL from mysql.com (not the platform-specific binary tarball)

    2. Unpack it, run ./configure with whatever options suit your purposes, but you will require --enable-static. Just to be sure, I included --disable-shared, though it might not be strictly necessary. I used the following, yours might differ on other counts:

      $ ./configure --prefix=/usr/local/mysql-src/ --enable-static --disable-shared --with-charset=utf8 --with-extra-charsets=ascii,binary,latin1 --with-collation=utf8_general_ci
      $ make
      $ sudo make install

      (Regarding the charset and collation parameters here: they may be completely unnecessary in this use case, since I’m going to delete MySQL afterwards, but since all the client connections use some charset/collation, I’m covering my bases UTF-8 -wise just in case the default charset/collation used by MySQLdb is affected by how _mysql.so is compiled — wiser men than I may want to confirm this one way or the other.)

    3. Get the latest source tarball of mysql-python from http://pypi.python.org/pypi/MySQL-python

    4. Unpack it, and in site.cfg set static = True and mysql_config = /usr/local/mysql-src/bin/mysql_config (or whatever path you chose during configure).

    5. Run python setup.py build. Some architecture-related errors may appear at the end of the compile, but they can be ignored.

    6. Run sudo python setup.by install. This creates an .egg in your site-packages directory and adds it to the easy_install.pth file.

    7. You’re done! You may now delete all traces of MySQL as well as the mysql-python sources. The egg can be copied as-is to other Macs running the same version of OS X. I’m happily copying it to various virtual environments created with virtualenv as we speak.

    This worked on 10.5, I’ll test it on 10.6 soon and, if something needs to be done differently, report the results here.

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

Sidebar

Ask A Question

Stats

  • Questions 314k
  • Answers 314k
  • Best Answers 0
  • User 1
  • Popular
  • Answers
  • Editorial Team

    How to approach applying for a job at a company ...

    • 7 Answers
  • Editorial Team

    What is a programmer’s life like?

    • 5 Answers
  • Editorial Team

    How to handle personal stress caused by utterly incompetent and ...

    • 5 Answers
  • Editorial Team
    Editorial Team added an answer Figured it out. This is not a bug with PHP… May 13, 2026 at 11:03 pm
  • Editorial Team
    Editorial Team added an answer No, that is not good practice. You want to apply… May 13, 2026 at 11:03 pm
  • Editorial Team
    Editorial Team added an answer Check these libraries: http://en.wikipedia.org/wiki/Thrift_(protocol) http://code.google.com/apis/protocolbuffers/ May 13, 2026 at 11:03 pm

Related Questions

I want use html5's new tag to play a wav file (currently only supported
I'm trying to decode HTML entries from here NYTimes.com and I cannot figure out
I ran into a problem. Wrote the following code snippet: teksti = teksti.Trim() teksti
I've got a string that has curly quotes in it. I'd like to replace
In order to apply a triggered animation to all ToolTip s in my app,

Trending Tags

analytics british company computer developers django employee employer english facebook french google interview javascript language life php programmer programs salary

Top Members

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.