Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Commit 58d8310

Browse filesBrowse files
committed
Merge pull request #1322 from dmcdougall/mac_build
Update Mac build process. Fixes #751
2 parents 70e1b25 + 8662c32 commit 58d8310
Copy full SHA for 58d8310
Expand file treeCollapse file tree

13 files changed

+19
-482
lines changed

‎test/TODO renamed to ‎TODO_TESTS

Copy file name to clipboard
File renamed without changes.

‎make.osx

Copy file name to clipboardExpand all lines: make.osx
-117Lines changed: 0 additions & 117 deletions
This file was deleted.

‎setupext.py

Copy file name to clipboardExpand all lines: setupext.py
+19-1Lines changed: 19 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -57,7 +57,7 @@
5757
basedir = defaultdict(lambda: ['/usr/local', '/usr'], {
5858
# execptions to the ['/usr/local', '/usr'] defaults
5959
'win32' : ['win32_static',],
60-
'darwin' : ['/usr/local/', '/usr', '/usr/X11'],
60+
'darwin' : ['/usr/local/', '/usr', '/usr/X11', '/opt/local'],
6161
'sunos5' : [os.getenv('MPLIB_BASE') or '/usr/local',],
6262
'gnu0' : ['/usr'],
6363
'aix5' : ['/usr/local'],
@@ -258,6 +258,20 @@ def get_win32_compiler():
258258
else:
259259
std_libs = ['stdc++', 'm']
260260

261+
def set_pkgconfig_path():
262+
pkgconfig_path = sysconfig.get_config_var('LIBDIR')
263+
if pkgconfig_path is None:
264+
return
265+
266+
pkgconfig_path = os.path.join(pkgconfig_path, 'pkgconfig')
267+
if not os.path.isdir(pkgconfig_path):
268+
return
269+
270+
try:
271+
os.environ['PKG_CONFIG_PATH'] += ':' + pkgconfig_path
272+
except KeyError:
273+
os.environ['PKG_CONFIG_PATH'] = pkgconfig_path
274+
261275
def has_pkgconfig():
262276
if has_pkgconfig.cache is not None:
263277
return has_pkgconfig.cache
@@ -267,6 +281,10 @@ def has_pkgconfig():
267281
#print 'environ', os.environ['PKG_CONFIG_PATH']
268282
status, output = getstatusoutput("pkg-config --help")
269283
has_pkgconfig.cache = (status == 0)
284+
285+
# Set the PKG_CONFIG_PATH environment variable
286+
if has_pkgconfig.cache:
287+
set_pkgconfig_path()
270288
return has_pkgconfig.cache
271289
has_pkgconfig.cache = None
272290

‎test/README.build_slaves

Copy file name to clipboardExpand all lines: test/README.build_slaves
-10Lines changed: 0 additions & 10 deletions
This file was deleted.

‎test/README.txt

Copy file name to clipboardExpand all lines: test/README.txt
-2Lines changed: 0 additions & 2 deletions
This file was deleted.

‎test/_buildbot_doc.sh

Copy file name to clipboardExpand all lines: test/_buildbot_doc.sh
-32Lines changed: 0 additions & 32 deletions
This file was deleted.

‎test/_buildbot_install.py

Copy file name to clipboardExpand all lines: test/_buildbot_install.py
-37Lines changed: 0 additions & 37 deletions
This file was deleted.

‎test/_buildbot_mac_sage.sh

Copy file name to clipboardExpand all lines: test/_buildbot_mac_sage.sh
-23Lines changed: 0 additions & 23 deletions
This file was deleted.

‎test/_buildbot_test.py

Copy file name to clipboardExpand all lines: test/_buildbot_test.py
-19Lines changed: 0 additions & 19 deletions
This file was deleted.

0 commit comments

Comments
0 (0)
Morty Proxy This is a proxified and sanitized view of the page, visit original site.