|
From: Travis O. <oli...@ee...> - 2006-02-15 21:21:00
|
Robert Kern wrote: >sk...@po... wrote: > > >>I'm trying to build numpy an svn sandbox (just updated a couple minutes >>ago). If I grub around in numpy/distutils/system_info.py it says something >>about creating a site.cfg file with (for example) information about locating >>atlas. It says nothing about where this file belongs. >> >> > >Sure it does. "The file 'site.cfg' in the same directory as this module is read >for configuration options." I think it's a really bad place for it to be, but >that is the state of affairs right now. > > > So, in particular, does this mean that it is read from (relative to the location of the main setup.py file) numpy/distutils/site.cfg ?? Yes, that is a bad place. We need some suggestions as to where site.cfg should be read from. I think you can set the environment variable ATLAS to 'None' and it will ignore ATLAS... I believe this is true of any of the configuration options. -Travis |
|
From: Travis O. <oli...@ee...> - 2006-02-15 21:26:49
|
sk...@po... wrote: >I'm trying to build numpy an svn sandbox (just updated a couple minutes >ago). If I grub around in numpy/distutils/system_info.py it says something >about creating a site.cfg file with (for example) information about locating >atlas. It says nothing about where this file belongs. I took a stab and >placed it in my numpy source tree, right next to setup.py, with these lines: > >Failing all this, is there some way to build numpy/scipy without atlas? At >this point I just want the damn thing to build. I'll worry about >performance later (if at all). > > Yes. You need to set the appropriate environment variables to 'None' In particular, on my system (which is multithreaded and has a BLAS picked up from /usr/lib and an unthreaded ATLAS that the system will find) export PTATLAS='None' export ATLAS='None' export BLAS='None' did the trick. -Travis |
|
From: Robert K. <rob...@gm...> - 2006-02-15 21:45:41
|
Travis Oliphant wrote: > So, in particular, does this mean that it is read from (relative to the > location of the main setup.py file) > > numpy/distutils/site.cfg ?? Yes. And in the case of scipy, it needs to be in the *installed* numpy/distutils directory. > Yes, that is a bad place. We need some suggestions as to where > site.cfg should be read from. Next to the setup.py that *invokes* numpy.distutils. AFAICT using os.getcwd() in system_info.py will give you this directory even if you start running the script from a different directory (e.g. "python ~/svn/scipy/setup.py install"). I can check this in if we agree that this is what we want. -- Robert Kern rob...@gm... "In the fields of hell where the grass grows high Are the graves of dreams allowed to die." -- Richard Harter |
|
From: David M. C. <co...@ph...> - 2006-02-15 22:05:27
|
On Wed, Feb 15, 2006 at 03:45:33PM -0600, Robert Kern wrote: > Travis Oliphant wrote: > > > So, in particular, does this mean that it is read from (relative to the > > location of the main setup.py file) > > > > numpy/distutils/site.cfg ?? > > Yes. And in the case of scipy, it needs to be in the *installed* numpy/distutils > directory. > > > Yes, that is a bad place. We need some suggestions as to where > > site.cfg should be read from. > > Next to the setup.py that *invokes* numpy.distutils. AFAICT using os.getcwd() in > system_info.py will give you this directory even if you start running the script > from a different directory (e.g. "python ~/svn/scipy/setup.py install"). I can > check this in if we agree that this is what we want. As a note: Python's distutils looks for distutils.cfg in it's installed location (/usr/lib/python2.4/distutils or whatever), then in ~/.pydistutils.cfg (or $HOME/pydistutils.cfg on non-Posix systems like Windows), then for setup.cfg in the current directory. Keys in later files override ones in earlier files. -- |>|\/|< /--------------------------------------------------------------------------\ |David M. Cooke http://arbutus.physics.mcmaster.ca/dmc/ |co...@ph... |
|
From: Travis O. <oli...@ee...> - 2006-02-15 22:15:31
|
David M. Cooke wrote: >On Wed, Feb 15, 2006 at 03:45:33PM -0600, Robert Kern wrote: > > >>Travis Oliphant wrote: >> >> >> >>>So, in particular, does this mean that it is read from (relative to the >>>location of the main setup.py file) >>> >>>numpy/distutils/site.cfg ?? >>> >>> >>Yes. And in the case of scipy, it needs to be in the *installed* numpy/distutils >>directory. >> >> >> >>>Yes, that is a bad place. We need some suggestions as to where >>>site.cfg should be read from. >>> >>> >>Next to the setup.py that *invokes* numpy.distutils. AFAICT using os.getcwd() in >>system_info.py will give you this directory even if you start running the script >>from a different directory (e.g. "python ~/svn/scipy/setup.py install"). I can >>check this in if we agree that this is what we want. >> >> > >As a note: Python's distutils looks for distutils.cfg in it's installed >location (/usr/lib/python2.4/distutils or whatever), then in >~/.pydistutils.cfg (or $HOME/pydistutils.cfg on non-Posix systems like >Windows), then for setup.cfg in the current directory. Keys in later files >override ones in earlier files. > > > I think this is a good plan. However, what I've started doesn't implement the over-riding process properly. Anybody want to take a stab at that? It would be nice if it could get into this next release. -Travis |
|
From: Travis O. <oli...@ee...> - 2006-02-15 22:14:03
|
Robert Kern wrote: >Travis Oliphant wrote: > > > >>So, in particular, does this mean that it is read from (relative to the >>location of the main setup.py file) >> >>numpy/distutils/site.cfg ?? >> >> > >Yes. And in the case of scipy, it needs to be in the *installed* numpy/distutils >directory. > > > >>Yes, that is a bad place. We need some suggestions as to where >>site.cfg should be read from. >> >> > >Next to the setup.py that *invokes* numpy.distutils. AFAICT using os.getcwd() in >system_info.py will give you this directory even if you start running the script >from a different directory (e.g. "python ~/svn/scipy/setup.py install"). I can >check this in if we agree that this is what we want. > > > I've started this process already. I think a useful search order is 1) next to current setup.py --- os.getcwd() is probably better than what I did (backing up the frame until you can't go back anymore and getting the __file__ from that frame). Incidentally, it looks like a site.cfg present there is already copied to numpy/distutils on install --- it's looks like its just not used for the numpy build itself. 2) in the compilers "HOME" directory --- not sure how to implement that. 3) in the system-wide directory (what is currently done --- except when you are installing numpy that means it has to be in numpy/distutils/site.cfg). I created a get_site_cfg() function in system_info where this searching can be done. Feel free to change it as appropriate. -Travis |
|
From: David M. C. <co...@ph...> - 2006-02-15 22:44:09
|
On Wed, Feb 15, 2006 at 03:13:56PM -0700, Travis Oliphant wrote: > Robert Kern wrote: > I've started this process already. I think a useful search order is > > 1) next to current setup.py --- os.getcwd() is probably better than > what I did (backing up the frame until you can't go back anymore and > getting the __file__ from that frame). Incidentally, it looks like a > site.cfg present there is already copied to numpy/distutils on install > --- it's looks like its just not used for the numpy build itself. > > 2) in the compilers "HOME" directory --- not sure how to implement that. Have a look at distutils.dist for the Distribution.find_config_files method. Also, the parse_config_files method reads the config options in a way that keeps which filenames they come from. > 3) in the system-wide directory (what is currently done --- except when > you are installing numpy that means it has to be in > numpy/distutils/site.cfg). -- |>|\/|< /--------------------------------------------------------------------------\ |David M. Cooke http://arbutus.physics.mcmaster.ca/dmc/ |co...@ph... |
|
From: <sk...@po...> - 2006-02-16 01:38:46
|
Travis> Yes, that is a bad place. We need some suggestions as to w=
here
Travis> site.cfg should be read from.
First place to look should be `pwd`.
Travis> I think you can set the environment variable ATLAS to 'None=
' and
Travis> it will ignore ATLAS...
Thank you, thank you, thank you. I now have numpy built... I'll tackl=
e the
rest of scipy ma=F1ana.
Skip
|