Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
C
cpython
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Kirill Smelkov
cpython
Commits
f727c311
Commit
f727c311
authored
Feb 03, 2013
by
Benjamin Peterson
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix find_library on Solaris (closes #5289)
parent
3e081c73
Changes
3
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
32 additions
and
0 deletions
+32
-0
Lib/ctypes/util.py
Lib/ctypes/util.py
+29
-0
Misc/ACKS
Misc/ACKS
+1
-0
Misc/NEWS
Misc/NEWS
+2
-0
No files found.
Lib/ctypes/util.py
View file @
f727c311
...
@@ -180,6 +180,35 @@ elif os.name == "posix":
...
@@ -180,6 +180,35 @@ elif os.name == "posix":
res.sort(cmp= lambda x,y: cmp(_num_version(x), _num_version(y)))
res.sort(cmp= lambda x,y: cmp(_num_version(x), _num_version(y)))
return res[-1]
return res[-1]
elif sys.platform == "sunos5":
def _findLib_crle(name, is64):
if not os.path.exists('
/
usr
/
bin
/
crle
'):
return None
if is64:
cmd = '
env
LC_ALL
=
C
/
usr
/
bin
/
crle
-
64
2
>/
dev
/
null
'
else:
cmd = '
env
LC_ALL
=
C
/
usr
/
bin
/
crle
2
>/
dev
/
null
'
for line in os.popen(cmd).readlines():
line = line.strip()
if line.startswith('
Default
Library
Path
(
ELF
):
'):
paths = line.split()[4]
if not paths:
return None
for dir in paths.split(":"):
libfile = os.path.join(dir, "lib%s.so" % name)
if os.path.exists(libfile):
return libfile
return None
def find_library(name, is64 = False):
return _get_soname(_findLib_crle(name, is64) or _findLib_gcc(name))
else:
else:
def _findSoname_ldconfig(name):
def _findSoname_ldconfig(name):
...
...
Misc/ACKS
View file @
f727c311
...
@@ -1044,6 +1044,7 @@ Charles Waldman
...
@@ -1044,6 +1044,7 @@ Charles Waldman
Richard Walker
Richard Walker
Larry Wall
Larry Wall
Kevin Walzer
Kevin Walzer
Ke Wang
Greg Ward
Greg Ward
Zachary Ware
Zachary Ware
Barry Warsaw
Barry Warsaw
...
...
Misc/NEWS
View file @
f727c311
...
@@ -199,6 +199,8 @@ Core and Builtins
...
@@ -199,6 +199,8 @@ Core and Builtins
Library
Library
-------
-------
- Issue #5289: Fix ctypes.util.find_library on Solaris.
- Issue #17106: Fix a segmentation fault in io.TextIOWrapper when an underlying
- Issue #17106: Fix a segmentation fault in io.TextIOWrapper when an underlying
stream or a decoder produces data of an unexpected type (i.e. when
stream or a decoder produces data of an unexpected type (i.e. when
io.TextIOWrapper initialized with text stream or use bytes-to-bytes codec).
io.TextIOWrapper initialized with text stream or use bytes-to-bytes codec).
...
...
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