[Numpy-svn] r3716 - in trunk: . numpy/distutils

numpy-svn@scip... numpy-svn@scip...
Sat Apr 14 23:46:10 CDT 2007


Author: rkern
Date: 2007-04-14 23:46:07 -0500 (Sat, 14 Apr 2007)
New Revision: 3716

Modified:
   trunk/numpy/distutils/system_info.py
   trunk/site.cfg.example
Log:
Add another place to check for configuration, namely ~/.numpy-site.cfg, to help automatic installation where one can't edit the source checkout. I've added the alternate name to make it hidden because that's just considerate.

Modified: trunk/numpy/distutils/system_info.py
===================================================================
--- trunk/numpy/distutils/system_info.py	2007-04-15 04:38:59 UTC (rev 3715)
+++ trunk/numpy/distutils/system_info.py	2007-04-15 04:46:07 UTC (rev 3716)
@@ -58,7 +58,7 @@
 The file 'site.cfg' is looked for in
 
 1) Directory of main setup.py file being run.
-2) Home directory of user running the setup.py file (Not implemented yet)
+2) Home directory of user running the setup.py file as ~/.numpy-site.cfg
 3) System wide directory (location of this file...)
 
 The first one found is used to get system configuration options The
@@ -349,7 +349,9 @@
         defaults['src_dirs'] = os.pathsep.join(default_src_dirs)
         defaults['search_static_first'] = str(self.search_static_first)
         self.cp = ConfigParser.ConfigParser(defaults)
-        self.files = get_standard_file('site.cfg')
+        self.files = []
+        self.files.extend(get_standard_file('.numpy-site.cfg'))
+        self.files.extend(get_standard_file('site.cfg'))
         self.parse_config_files()
         self.search_static_first = self.cp.getboolean(self.section,
                                                       'search_static_first')

Modified: trunk/site.cfg.example
===================================================================
--- trunk/site.cfg.example	2007-04-15 04:38:59 UTC (rev 3715)
+++ trunk/site.cfg.example	2007-04-15 04:46:07 UTC (rev 3716)
@@ -4,6 +4,9 @@
 # packages will use all sections so you should leave out sections that your
 # package does not use.
 
+# To assist automatic installation like easy_install, the user's home directory
+# will also be checked for the file ~/.numpy-site.cfg .
+
 # The format of the file is that of the standard library's ConfigParser module.
 #
 #   http://www.python.org/doc/current/lib/module-ConfigParser.html



More information about the Numpy-svn mailing list