Skip to content

Commit 01da4fb

Browse files
committed
Detect x32 userspace ABI on 64-bit kernel (fixes pypa#4962)
1 parent d67d98d commit 01da4fb

File tree

1 file changed

+6
-1
lines changed

1 file changed

+6
-1
lines changed

src/pip/_internal/pep425tags.py

+6-1
Original file line numberDiff line numberDiff line change
@@ -135,7 +135,12 @@ def get_platform():
135135
if result == "linux_x86_64" and _is_running_32bit():
136136
# 32 bit Python program (running on a 64 bit Linux): pip should only
137137
# install and run 32 bit compiled extensions in that case.
138-
result = "linux_i686"
138+
machine = platform.machine()
139+
140+
if machine == "x86_64":
141+
result = "linux_x32"
142+
else:
143+
result = "linux_i686" # and machine == "i686"
139144

140145
return result
141146

0 commit comments

Comments
 (0)