स्थापित करने के लिए easy_install स्थापित करना ... मैं इस तथ्य के साथ पकड़ने आया हूं कि ElementTree ऐसा करने वाला नहीं है जो मैं करना चाहता हूं। मैंने lxml के लिए प्रलेखन की जांच की है, और ऐसा प्रतीत होता है कि यह मेरे उद्देश्यों को पूरा करेगा। Lxml प्राप्त करने के लिए, मुझे easy_install प्राप्त करने की आवश्यकता है। तो मैंने इसे here से डाउनलोड किया, और इसे /Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/
में रखा। तब मैं उस फ़ोल्डर में गया, और sh setuptools-0.6c11-py2.6.egg
भाग गया।lxml
सफलतापूर्वक स्थापित किया गया। तब मैं उत्साहित हो गया क्योंकि मैंने सोचा था कि easy_install का पूरा बिंदु यह था कि मैं बस easy_install lxml के माध्यम से स्थापित कर सकता था, और lxml जादुई रूप से डाउनलोड, निर्मित और स्थापित किया जा सकता है, जो मेरे आयात के आनंद के लिए तैयार है। तो मैं easy_install lxml
भाग गया। मैंने नीचे दिए गए परिणामों को चिपकाया। मुझे क्या करना चाहिए?
easy_install lxml
Searching for lxml
Reading http://pypi.python.org/simple/lxml/
Reading http://codespeak.net/lxml
Best match: lxml 2.2.6
Downloading http://codespeak.net/lxml/lxml-2.2.6.tgz
Processing lxml-2.2.6.tgz
Running lxml-2.2.6/setup.py -q bdist_egg --dist-dir /var/folders/49/49N0+g5QFKCm51AbzMtghE+++TI/-Tmp-/easy_install-rxbP6K/lxml-2.2.6/egg-dist-tmp-fjakR0
Building lxml version 2.2.6.
NOTE: Trying to build without Cython, pre-generated 'src/lxml/lxml.etree.c' needs to be available.
Using build configuration of libxslt 1.1.12
Building against libxml2/libxslt in the following directory: /usr/lib
unable to execute gcc-4.0: No such file or directory
error: Setup script exited with error: command 'gcc-4.0' failed with exit status 1
(फिर से: कोड कोड बनाने के लिए चार रिक्त स्थान से इंडेंट करें) या संपादक में "01010" बटन पर क्लिक करें, जबकि आपके पास कुछ चीजें हाइलाइट की गई हैं। –