Build Python, Numpy and Scipy source with Visual Studio 6.0 forwindows

Discussion in 'Python' started by Richard_Martineau@xyratex.com, Sep 16, 2008.

  1. Guest

    Hello All

    I wonder if anyone can advise me or has done similar to the following?

    Basically I've downloaded the Python 2.5.2 source code that builds
    with Visual Studio 6.0. I've built Python for windows. This was easy
    (it even came with the pcbuild.dsw workspace file). Great!

    Now comes the troubled bit...I now look for similar source code for
    Python extensions Numpy and Scipy but the source code and directories
    are not all obvious. Looks like these are normally built via other
    compilers. However I need to do all my builds in VS 6.0.

    For Numpy (I haven't got as far as Scipy yet) I've organised the
    source code into the following projects and lumped them all into my
    new workspace numpy.dsw:

    dotblas
    fft
    lib
    linalg
    multiarray
    numarray
    random
    scalarmath
    sort
    umath

    I'm obviously not sure if this is correct. As you can see from above,
    I've re-arranged the source code directory named core into the
    following projects:

    dotblas
    sort
    multiarray
    scalarmath
    umath


    Unbelievably I am having some luck and nearly all the projects compile
    and link (untested though).
    I created the auto-generated files using the python scripts. Then I
    included the headers where necessary.

    However the remaining problems are:
    multiarray (wont compile)
    dotblas (wont link)

    dotblas seems to have missing dependencies on these:
    _cblas_sdot
    _cblas_ddot
    _cblas_cdotu_sub
    _cblas_zdotu_sub
    _cblas_cgemm
    _cblas_zgemm
    _cblas_sgemm
    _cblas_dgemm
    _cblas_cgemv
    _cblas_zgemv
    _cblas_sgemv
    _cblas_dgemv
    _cblas_caxpy
    _cblas_saxpy
    _cblas_zaxpy
    _cblas_daxpy
    _cblas_cdotc_sub
    _cblas_zdotc_sub

    Well that's a snapshot of where I am this morning. What I'm really
    after is some advice from anybody who has done similar. I'd really
    appreciate hearing from you.

    Thanks for your help and very happy to have joined this group


    Richard
    , Sep 16, 2008
    #1
    1. Advertising

  2. En Tue, 16 Sep 2008 06:25:27 -0300, <>
    escribió:

    > I wonder if anyone can advise me or has done similar to the following?
    >
    > Basically I've downloaded the Python 2.5.2 source code that builds
    > with Visual Studio 6.0. I've built Python for windows. This was easy
    > (it even came with the pcbuild.dsw workspace file). Great!
    >
    > Now comes the troubled bit...I now look for similar source code for
    > Python extensions Numpy and Scipy but the source code and directories
    > are not all obvious. Looks like these are normally built via other
    > compilers. However I need to do all my builds in VS 6.0.
    >
    > For Numpy (I haven't got as far as Scipy yet) I've organised the
    > source code into the following projects and lumped them all into my
    > new workspace numpy.dsw:


    Don't try to roll your own projects, compile it using distutils instead.
    Distutils takes care of defining the right symbols and compiler options,
    and should detect VS.
    I'm pretty sure the Numpy README file (or similar) describes how to build
    it; usually you install the required dependencies and then run:
    python setup.py build

    --
    Gabriel Genellina
    Gabriel Genellina, Sep 16, 2008
    #2
    1. Advertising

  3. Guest

    On Sep 16, 11:02 am, "Gabriel Genellina" <>
    wrote:
    > En Tue, 16 Sep 2008 06:25:27 -0300, <>  
    > escribió:
    >
    > > I wonder if anyone can advise me or has done similar to the following?

    >
    > > Basically I've downloaded the Python 2.5.2 source code that builds
    > > with Visual Studio 6.0. I've built Python for windows. This was easy
    > > (it even came with the pcbuild.dsw workspace file). Great!

    >
    > > Now comes the troubled bit...I now look for similar source code for
    > > Python extensions Numpy and Scipy but the source code and directories
    > > are not all obvious. Looks like these are normally built via other
    > > compilers. However I need to do all my builds in VS 6.0.

    >
    > > For Numpy (I haven't got as far as Scipy yet) I've organised the
    > > source code into the following projects and lumped them all into my
    > > new workspace numpy.dsw:

    >
    > Don't try to roll your own projects, compile it using distutils instead.  
    > Distutils takes care of defining the right symbols and compiler options,  
    > and should detect VS.
    > I'm pretty sure the Numpy README file (or similar) describes how to build  
    > it; usually you install the required dependencies and then run:
    > python setup.py build
    >
    > --
    > Gabriel Genellina


    Thanks for your message.

    Unfortunately I need as much control and visibility as possible as I
    eventually want to port from windows os to pharlap rtos.

    I appreciate your advice and I understand it's not a great idea to
    roll your own, but if it's possible, I really need to do so.

    Any further help/advice greatly appreciated


    Richard
    , Sep 16, 2008
    #3
  4. Terry Reedy Guest

    wrote:

    > Now comes the troubled bit...I now look for similar source code for
    > Python extensions Numpy and Scipy but the source code and directories
    > are not all obvious. Looks like these are normally built via other
    > compilers. However I need to do all my builds in VS 6.0.


    Numpy/scipy specific questions tend to get more specific answers on the
    numpy/scipy mailing lists. Or see gmane.comp.python.numeric.general at
    news.gmane.org
    Terry Reedy, Sep 16, 2008
    #4
  5. Richie Guest

    On Sep 16, 7:03 pm, Terry Reedy <> wrote:
    > wrote:
    > > Now comes the troubled bit...I now look for similar source code for
    > > Python extensions Numpy and Scipy but the source code and directories
    > > are not all obvious. Looks like these are normally built via other
    > > compilers. However I need to do all my builds in VS 6.0.

    >
    > Numpy/scipy specific questions tend to get more specific answers on the
    > numpy/scipy mailing lists.  Or see gmane.comp.python.numeric.general at
    > news.gmane.org


    Thanks very much for your advice Terry. I've just signed up with Numpy
    discussion and Scipy dev. Just taking a look at gmane now!

    Richard
    Richie, Sep 17, 2008
    #5
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Terry Reedy

    Re: numpy and scipy for Python 2.3

    Terry Reedy, Jul 10, 2003, in forum: Python
    Replies:
    0
    Views:
    452
    Terry Reedy
    Jul 10, 2003
  2. vml
    Replies:
    3
    Views:
    689
  3. chapagainanish
    Replies:
    3
    Views:
    507
    Diez B. Roggisch
    Sep 3, 2008
  4. Vicent Giner

    Installing NumPy and SciPy in Python 2.6

    Vicent Giner, Nov 28, 2008, in forum: Python
    Replies:
    1
    Views:
    537
    David Cournapeau
    Nov 28, 2008
  5. Replies:
    0
    Views:
    441
Loading...

Share This Page