Skip to content

Commit

Permalink
The build script should now work properly with python(x,y) even if mo…
Browse files Browse the repository at this point in the history
…sek is installed

Conflicts:
	gpkit/build.py
  • Loading branch information
galbramc authored and whoburg committed Apr 20, 2016
1 parent 14eab52 commit 5c5fb21
Showing 1 changed file with 16 additions and 5 deletions.
21 changes: 16 additions & 5 deletions gpkit/build.py
Original file line number Diff line number Diff line change
Expand Up @@ -88,6 +88,15 @@ class Mosek_CLI(SolverBackend):
name = "mosek_cli"

def look(self):
"Attempts to run mskexpopt."

if sys.platform == "win32":
## does not work on 32-bit windows ##
log("# Build script does not support mosek_cli"
" your architecture (%s)" % platform.architecture()[0])
return


try:
log("# Trying to run mskexpopt...")
if call("mskexpopt") in (1052, 28): # 28 for MacOSX
Expand Down Expand Up @@ -138,13 +147,15 @@ def look(self):
self.libpattern = "mosek64_?_?.dll"
self.flags = "-Wl,--export-all-symbols,-R"
## below is for 32-bit windows ##
elif platform.architecture()[0] == '32bit':
self.dir = "C:\\Program Files (x86)\\Mosek"
self.platform = "win32x86"
self.libpattern = "mosek?_?.dll"
#elif platform.architecture()[0] == '32bit':
# self.dir = "C:\\Program Files (x86)\\Mosek"
# self.platform = "win32x86"
# self.libpattern = "mosek?_?.dll"
# self.flags = "-Wl,--export-all-symbols,-R"
else:
log("# Build script does not support"
log("# Build script does not support mosek"
" your architecture (%s)" % platform.architecture()[0])
return
elif sys.platform == "darwin":
self.dir = pathjoin(os.path.expanduser("~"), "mosek")
self.platform = "osx64x86"
Expand Down

0 comments on commit 5c5fb21

Please sign in to comment.