Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
OpenDAS
dlib
Commits
e4691051
"vscode:/vscode.git/clone" did not exist on "464e95f5bea8cc21c18c750b1942a3ca69aba1b0"
Commit
e4691051
authored
Aug 23, 2015
by
Ehsan Azarnasab
Browse files
use Python's architecture to give cmake a clue to generate the right config
parent
8e2ec4cc
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
8 additions
and
1 deletion
+8
-1
setup.py
setup.py
+8
-1
No files found.
setup.py
View file @
e4691051
...
...
@@ -326,6 +326,13 @@ class build(_build):
platform_arch
=
platform
.
architecture
()[
0
]
log
.
info
(
"Detected Python architecture: %s"
%
platform_arch
)
# make sure build artifacts are generated for the version of Python currently running
cmake_extra_arch
=
[]
if
platform_arch
==
'64bit'
:
cmake_extra_arch
=
[
'-DCMAKE_SIZEOF_VOID_P=8'
]
elif
platform_arch
==
'32bit'
:
cmake_extra_arch
=
[
'-DCMAKE_SIZEOF_VOID_P=4'
]
build_dir
=
os
.
path
.
join
(
script_dir
,
"./tools/python/build"
)
if
os
.
path
.
exists
(
build_dir
):
log
.
info
(
'Removing build directory %s'
%
build_dir
)
...
...
@@ -342,7 +349,7 @@ class build(_build):
cmake_cmd
=
[
cmake_path
,
".."
,
]
+
cmake_extra
]
+
cmake_extra
+
cmake_extra_arch
if
run_process
(
cmake_cmd
):
raise
DistutilsSetupError
(
"cmake configuration failed!"
)
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment