Fix compile issue on Mac OS X

This commit is contained in:
rdb 2016-06-22 22:24:33 +02:00
parent 7676104f4c
commit fede8b8d69
2 changed files with 6 additions and 1 deletions

View File

@ -1543,12 +1543,17 @@ def SmartPkgEnable(pkg, pkgconfig = None, libs = None, incs = None, defs = None,
location = LocateLibrary(libname, lpath, prefer_static=True)
if location is not None:
# If it's a .so or .dylib we may have changed it and copied it to the built/lib dir.
if location.endswith('.so') or location.endswith('.dylib'):
location = os.path.join(GetOutputDir(), "lib", os.path.basename(location))
LibName(target_pkg, location)
else:
# This is for backward compatibility - in the thirdparty dir,
# we kept some libs with "panda" prefix, like libpandatiff.
location = LocateLibrary("panda" + libname, lpath, prefer_static=True)
if location is not None:
if location.endswith('.so') or location.endswith('.dylib'):
location = os.path.join(GetOutputDir(), "lib", os.path.basename(location))
LibName(target_pkg, location)
else:
print(GetColor("cyan") + "Couldn't find library lib" + libname + " in thirdparty directory " + pkg.lower() + GetColor())

View File

@ -150,7 +150,7 @@ OpenForInputMCast(const Socket_Address &address) {
sizeof(struct in6_addr));
imreq.ipv6mr_interface = 0; // use DEFAULT interface
status = setsockopt(GetSocket(), IPPROTO_IPV6, IPV6_ADD_MEMBERSHIP,
status = setsockopt(GetSocket(), IPPROTO_IPV6, IPV6_JOIN_GROUP,
(const char *)&imreq, sizeof(imreq));
}