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 8417121
In Process

The Archive Base Latest Questions

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

How do you write a setup.py to compile .pyx files in an arbitrary location

  • 0

How do you write a setup.py to compile .pyx files in an arbitrary location and install the compiled code in another arbitrary location? For example dirA/spam.pyx to build/dirB/spam.so?

  • 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-10T01:57:18+00:00Added an answer on June 10, 2026 at 1:57 am

    According to the distutils documentation, you can build any compiled python modules in an arbitrary location using the command line option --build-base, e.g.:

    python setup.py build --build-base=/build/dirB
    

    If you want to keep the default build directory, but install to a custom location, you should use one of the options --user --home, --prefix, --exec-prefix, --install-base or --install-platbase

    Finally, if you just want the .so file in the current directory, use the option --inplace

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

Sidebar

Related Questions

I am trying to write a procedure in Inno setup code using default values
I want to write an JUnit @Rule (version 4.10) to setup some objects (an
I have the following setup in Oracle, i.e.: (‘aXYZApple-Au’, ‘aXYZOrange-Au’,’aXYZApple-Readonly’,’aXYZOrange-Write’, ’aXYZApple-Write’, ’aXYZOrange-Read’) What I
I m trying write code that after reset set up rrpmax as 3000. It
I try to load image with processing.js using CoffeeScript and write this simple code:
I want to know how I could write a CMake setup which allows compilation
I'm using Assetic with the compass filter to pass and compile .scss files. This
I have a C++ code that can be compiled with MPI support depending on
right now its set up to write to a file, but I want it
I've set up DAV in apache2, which works great. The thing is, all read/write

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.