pkgsrc/www/py-curl/patches/patch-aa
obache 67372001fb Try to prevent to link against static libraries.
Fixes build failure on NetBSD/amd64, reported by Dieter Roelants via private mail.
2012-01-28 13:15:10 +00:00

47 lines
1.9 KiB
Text

$NetBSD: patch-aa,v 1.8 2012/01/28 13:15:11 obache Exp $
* in pkgsrc, OpenSSL is used for cURL SSL support, so disable pick up of
static-libs to detect ssl library for REQUIRE_LIB_DEPS=no platforms,
and prevent to link with static library additionally.
* add multi python variant support
--- setup.py.orig 2008-09-09 17:40:34.000000000 +0000
+++ setup.py
@@ -96,16 +96,10 @@ else:
include_dirs.append(e[2:])
else:
extra_compile_args.append(e)
- libs = split_quoted(
- os.popen("'%s' --libs" % CURL_CONFIG).read()+\
- os.popen("'%s' --static-libs" % CURL_CONFIG).read())
+ libs = split_quoted(os.popen("'%s' --libs" % CURL_CONFIG).read())
for e in libs:
if e[:2] == "-l":
libraries.append(e[2:])
- if e[2:] == 'ssl':
- define_macros.append(('HAVE_CURL_OPENSSL', 1))
- if e[2:] == 'gnutls':
- define_macros.append(('HAVE_CURL_GNUTLS', 1))
elif e[:2] == "-L":
library_dirs.append(e[2:])
else:
@@ -113,6 +107,7 @@ else:
for e in split_quoted(os.popen("'%s' --features" % CURL_CONFIG).read()):
if e == 'SSL':
define_macros.append(('HAVE_CURL_SSL', 1))
+ define_macros.append(('HAVE_CURL_OPENSSL', 1))
if not libraries:
libraries.append("curl")
# Add extra compile flag for MacOS X
@@ -149,9 +144,9 @@ def get_data_files():
# a list of tuples with (path to install to, a list of local files)
data_files = []
if sys.platform == "win32":
- datadir = os.path.join("doc", PACKAGE)
+ datadir = os.path.join("doc", PACKAGE + sys.version[0:3])
else:
- datadir = os.path.join("share", "doc", PACKAGE)
+ datadir = os.path.join("share", "doc", PACKAGE + sys.version[0:3])
#
files = ["ChangeLog", "COPYING", "COPYING2", "INSTALL", "README", "TODO",]
if files: