Note that there are some explanatory texts on larger screens.

plurals
  1. PO
    primarykey
    data
    text
    <p>I have managed (with some help) so solve the problem. The problem is that after installation, the pycurl.so is not copied to the site-packages for this virtualenv. </p> <p>When installing via <code>pip -v install pycurl</code>, the following output is given:</p> <pre><code>Downloading/unpacking pycurl Using version 7.19.0 (newest of versions: 7.19.0, 7.19.0, 7.18.2, 7.18.1, 7.16.4, 7.16.2.1, 7.16.2, 7.16.1, 7.15.5.1) Downloading pycurl-7.19.0.tar.gz (71Kb): 71Kb downloaded Running setup.py egg_info for package pycurl Using curl-config (libcurl 7.19.7) running egg_info creating pip-egg-info/pycurl.egg-info writing pip-egg-info/pycurl.egg-info/PKG-INFO writing top-level names to pip-egg-info/pycurl.egg-info/top_level.txt writing dependency_links to pip-egg-info/pycurl.egg-info/dependency_links.txt writing manifest file 'pip-egg-info/pycurl.egg-info/SOURCES.txt' warning: manifest_maker: standard file '-c' not found reading manifest file 'pip-egg-info/pycurl.egg-info/SOURCES.txt' reading manifest template 'MANIFEST.in' writing manifest file 'pip-egg-info/pycurl.egg-info/SOURCES.txt' Installing collected packages: pycurl Running setup.py install for pycurl Using curl-config (libcurl 7.19.7) running install running build running build_py creating build creating build/lib.linux-x86_64-2.7 creating build/lib.linux-x86_64-2.7/curl copying python/curl/__init__.py -&gt; build/lib.linux-x86_64-2.7/curl running build_ext building 'pycurl' extension creating build/temp.linux-x86_64-2.7 creating build/temp.linux-x86_64-2.7/src gcc -pthread -fno-strict-aliasing -g -O2 -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes -fPIC -DHAVE_CURL_SSL=1 -I/opt/python2.7/include/python2.7 -c src/pycurl.c -o build/temp.linux-x86_64-2.7/src/pycurl.o src/pycurl.c:85:4: warning: #warning "libcurl was compiled with SSL support, but configure could not determine which " "library was used; thus no SSL crypto locking callbacks will be set, which may " "cause random crashes on SSL requests" src/pycurl.c: In function ‘do_multi_info_read’: src/pycurl.c:2843: warning: call to ‘_curl_easy_getinfo_err_string’ declared with attribute warning: curl_easy_getinfo expects a pointer to char * for this info src/pycurl.c: In function ‘multi_socket_callback’: src/pycurl.c:2355: warning: call to ‘_curl_easy_getinfo_err_string’ declared with attribute warning: curl_easy_getinfo expects a pointer to char * for this info In function ‘util_curl_unsetopt’, inlined from ‘do_curl_unsetopt’ at src/pycurl.c:1551: src/pycurl.c:1476: warning: call to ‘_curl_easy_setopt_err_CURLSH’ declared with attribute warning: curl_easy_setopt expects a CURLSH* argument for this option gcc -pthread -shared build/temp.linux-x86_64-2.7/src/pycurl.o -L/opt/python2.7/lib -lcurl -lpython2.7 -o build/lib.linux-x86_64-2.7/pycurl.so unknown option: --static-libs Usage: curl-config [OPTION] Available values for OPTION include: --ca ca bundle install path --cc compiler --cflags pre-processor and compiler flags --checkfor [version] check for (lib)curl of the specified version --features newline separated list of enabled features --help display this help and exit --libs library linking information --prefix curl install prefix --protocols newline separated list of enabled protocols --version output version information --vernum output the version information as a number (hexadecimal) gcc (GCC) 4.4.4 20100726 (Red Hat 4.4.4-13) Copyright (C) 2010 Free Software Foundation, Inc. This is free software; see the source for copying conditions. There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. running install_lib creating /home/ec2-user/.virtualenvs/xxx/lib/python2.7/site-packages/curl copying build/lib.linux-x86_64-2.7/curl/__init__.py -&gt; /home/ec2-user/.virtualenvs/xxx/lib/python2.7/site-packages/curl byte-compiling /home/ec2-user/.virtualenvs/xxx/lib/python2.7/site-packages/curl/__init__.py to __init__.pyc running install_data copying ChangeLog -&gt; /home/ec2-user/.virtualenvs/xxx/share/doc/pycurl copying COPYING -&gt; /home/ec2-user/.virtualenvs/xxx/share/doc/pycurl copying COPYING2 -&gt; /home/ec2-user/.virtualenvs/xxx/share/doc/pycurl copying INSTALL -&gt; /home/ec2-user/.virtualenvs/xxx/share/doc/pycurl copying README -&gt; /home/ec2-user/.virtualenvs/xxx/share/doc/pycurl copying TODO -&gt; /home/ec2-user/.virtualenvs/xxx/share/doc/pycurl copying doc/curlshareobject.html -&gt; /home/ec2-user/.virtualenvs/xxx/share/doc/pycurl/html copying doc/pycurl.html -&gt; /home/ec2-user/.virtualenvs/xxx/share/doc/pycurl/html copying doc/curlobject.html -&gt; /home/ec2-user/.virtualenvs/xxx/share/doc/pycurl/html copying doc/curlmultiobject.html -&gt; /home/ec2-user/.virtualenvs/xxx/share/doc/pycurl/html copying doc/callbacks.html -&gt; /home/ec2-user/.virtualenvs/xxx/share/doc/pycurl/html copying examples/retriever.py -&gt; /home/ec2-user/.virtualenvs/xxx/share/doc/pycurl/examples copying examples/file_upload.py -&gt; /home/ec2-user/.virtualenvs/xxx/share/doc/pycurl/examples copying examples/linksys.py -&gt; /home/ec2-user/.virtualenvs/xxx/share/doc/pycurl/examples copying examples/xmlrpc_curl.py -&gt; /home/ec2-user/.virtualenvs/xxx/share/doc/pycurl/examples copying examples/retriever-multi.py -&gt; /home/ec2-user/.virtualenvs/xxx/share/doc/pycurl/examples copying examples/sfquery.py -&gt; /home/ec2-user/.virtualenvs/xxx/share/doc/pycurl/examples copying examples/basicfirst.py -&gt; /home/ec2-user/.virtualenvs/xxx/share/doc/pycurl/examples copying tests/test.py -&gt; /home/ec2-user/.virtualenvs/xxx/share/doc/pycurl/tests copying tests/test_ftp.py -&gt; /home/ec2-user/.virtualenvs/xxx/share/doc/pycurl/tests copying tests/test_share.py -&gt; /home/ec2-user/.virtualenvs/xxx/share/doc/pycurl/tests copying tests/test_multi5.py -&gt; /home/ec2-user/.virtualenvs/xxx/share/doc/pycurl/tests copying tests/test_multi_timer.py -&gt; /home/ec2-user/.virtualenvs/xxx/share/doc/pycurl/tests copying tests/test_post.py -&gt; /home/ec2-user/.virtualenvs/xxx/share/doc/pycurl/tests copying tests/test_gtk.py -&gt; /home/ec2-user/.virtualenvs/xxx/share/doc/pycurl/tests copying tests/test_post3.py -&gt; /home/ec2-user/.virtualenvs/xxx/share/doc/pycurl/tests copying tests/test_debug.py -&gt; /home/ec2-user/.virtualenvs/xxx/share/doc/pycurl/tests copying tests/test_multi4.py -&gt; /home/ec2-user/.virtualenvs/xxx/share/doc/pycurl/tests copying tests/test_cb.py -&gt; /home/ec2-user/.virtualenvs/xxx/share/doc/pycurl/tests copying tests/test_multi_vs_thread.py -&gt; /home/ec2-user/.virtualenvs/xxx/share/doc/pycurl/tests copying tests/test_stringio.py -&gt; /home/ec2-user/.virtualenvs/xxx/share/doc/pycurl/tests copying tests/test_xmlrpc.py -&gt; /home/ec2-user/.virtualenvs/xxx/share/doc/pycurl/tests copying tests/test_multi_socket_select.py -&gt; /home/ec2-user/.virtualenvs/xxx/share/doc/pycurl/tests copying tests/test_multi6.py -&gt; /home/ec2-user/.virtualenvs/xxx/share/doc/pycurl/tests copying tests/test_multi_socket.py -&gt; /home/ec2-user/.virtualenvs/xxx/share/doc/pycurl/tests copying tests/test_multi.py -&gt; /home/ec2-user/.virtualenvs/xxx/share/doc/pycurl/tests copying tests/util.py -&gt; /home/ec2-user/.virtualenvs/xxx/share/doc/pycurl/tests copying tests/test_multi3.py -&gt; /home/ec2-user/.virtualenvs/xxx/share/doc/pycurl/tests copying tests/test_internals.py -&gt; /home/ec2-user/.virtualenvs/xxx/share/doc/pycurl/tests copying tests/test_post2.py -&gt; /home/ec2-user/.virtualenvs/xxx/share/doc/pycurl/tests copying tests/test_memleak.py -&gt; /home/ec2-user/.virtualenvs/xxx/share/doc/pycurl/tests copying tests/test_multi2.py -&gt; /home/ec2-user/.virtualenvs/xxx/share/doc/pycurl/tests copying tests/test_socketopen.py -&gt; /home/ec2-user/.virtualenvs/xxx/share/doc/pycurl/tests copying tests/test_getinfo.py -&gt; /home/ec2-user/.virtualenvs/xxx/share/doc/pycurl/tests running install_egg_info running egg_info creating pycurl.egg-info writing pycurl.egg-info/PKG-INFO writing top-level names to pycurl.egg-info/top_level.txt writing dependency_links to pycurl.egg-info/dependency_links.txt writing manifest file 'pycurl.egg-info/SOURCES.txt' warning: manifest_maker: standard file '-c' not found reading manifest file 'pycurl.egg-info/SOURCES.txt' reading manifest template 'MANIFEST.in' writing manifest file 'pycurl.egg-info/SOURCES.txt' Copying pycurl.egg-info to /home/ec2-user/.virtualenvs/xxx/lib/python2.7/site-packages/pycurl-7.19.0-py2.7.egg-info running install_scripts writing list of installed files to '/tmp/pip-lEWzoB-record/install-record.txt' Successfully installed pycurl Cleaning up... Removing temporary dir /home/ec2-user/.virtualenvs/xxx/build... </code></pre> <p>The key error here is: <code>gcc -pthread -shared build/temp.linux-x86_64-2.7/src/pycurl.o -L/opt/python2.7/lib -lcurl -lpython2.7 -o build/lib.linux-x86_64-2.7/pycurl.so unknown option: --static-libs Usage: curl-config [OPTION] Available values for OPTION include: --ca ca bundle install path --cc compiler --cflags pre-processor and compiler flags --checkfor [version] check for (lib)curl of the specified version --features newline separated list of enabled features --help display this help and exit --libs library linking information --prefix curl install prefix --protocols newline separated list of enabled protocols --version output version information --vernum output the version information as a number (hexadecimal)</code></p> <p>Which shows that <code>curl-config</code> is being called with the argument <code>--static-libs</code>, which it fails to recognise and instead prints it's 'usage' output. Most importantly, it is returning a non-error-code output which makes the compiler assume the <code>pycurl.so</code> compilation was successful.</p> <p>This is described in more detail <a href="http://yz.mit.edu/wp/cute-silent-failure-building-pycurl/" rel="noreferrer">here</a></p> <p>The solution to this problem was to modify the pycurl's setup.py and change line 101 to read <code>--libs</code> instead of <code>--static-libs</code>. This causes <code>pycurl.so</code> to be built and copied to the <code>site-packages</code> directory successfully.</p>
    singulars
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. VO
      singulars
      1. This table or related slice is empty.
    2. VO
      singulars
      1. This table or related slice is empty.
    3. VO
      singulars
      1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload