mirror of
https://github.com/panda3d/panda3d.git
synced 2025-10-02 18:03:56 -04:00
get frameworks from pkg-config as well
This commit is contained in:
parent
9009141e45
commit
8525e325c3
@ -1008,9 +1008,21 @@ def PkgConfigGetLibs(pkgname, tool = "pkg-config"):
|
|||||||
result = handle.read().strip()
|
result = handle.read().strip()
|
||||||
handle.close()
|
handle.close()
|
||||||
libs = []
|
libs = []
|
||||||
for l in result.split(" "):
|
|
||||||
|
# Walk through the result arguments carefully. Look for -lname as
|
||||||
|
# well as -framework name.
|
||||||
|
r = result.split(' ')
|
||||||
|
ri = 0
|
||||||
|
while ri < len(r):
|
||||||
|
l = r[ri]
|
||||||
if l.startswith("-l") or l.startswith("/"):
|
if l.startswith("-l") or l.startswith("/"):
|
||||||
libs.append(l)
|
libs.append(l)
|
||||||
|
elif l == '-framework':
|
||||||
|
libs.append(l)
|
||||||
|
ri += 1
|
||||||
|
libs.append(r[ri])
|
||||||
|
ri += 1
|
||||||
|
|
||||||
return libs
|
return libs
|
||||||
|
|
||||||
def PkgConfigGetIncDirs(pkgname, tool = "pkg-config"):
|
def PkgConfigGetIncDirs(pkgname, tool = "pkg-config"):
|
||||||
|
Loading…
x
Reference in New Issue
Block a user