kylemcdonald / FreeWifi

How to get free wifi.
Other
2.87k stars 223 forks source link

Netifaces Error #10

Closed jrvansuita closed 7 years ago

jrvansuita commented 7 years ago

I'm acquainted with phyton, but I'm trying to get things working here. When I ran cd FreeWifi && sudo pip install -r requirements.txt some error happend with netifaces installation, can you help me to figure it out what's it?

jrvansuita$ cd FreeWifi && sudo pip install -r requirements.txt
Password:
The directory '/Users/jrvansuita/Library/Caches/pip/http' or its parent directory is not owned by the current user and the cache has been disabled. Please check the permissions and owner of that directory. If executing pip with sudo, you may want sudo's -H flag.
The directory '/Users/jrvansuita/Library/Caches/pip' or its parent directory is not owned by the current user and caching wheels has been disabled. check the permissions and owner of that directory. If executing pip with sudo, you may want sudo's -H flag.
Collecting netifaces (from -r requirements.txt (line 1))
  Downloading netifaces-0.10.5.tar.gz
Collecting netaddr (from -r requirements.txt (line 2))
  Downloading netaddr-0.7.19-py2.py3-none-any.whl (1.6MB)
    100% |████████████████████████████████| 1.6MB 272kB/s 
Collecting wireless (from -r requirements.txt (line 3))
  Downloading wireless-0.3.2.tar.gz
Collecting SpoofMAC (from -r requirements.txt (line 4))
  Downloading SpoofMAC-2.1.1.tar.gz
Collecting tqdm (from -r requirements.txt (line 5))
  Downloading tqdm-4.11.2-py2.py3-none-any.whl (46kB)
    100% |████████████████████████████████| 51kB 347kB/s 
Collecting docopt (from SpoofMAC->-r requirements.txt (line 4))
  Downloading docopt-0.6.2.tar.gz
Installing collected packages: netifaces, netaddr, wireless, docopt, SpoofMAC, tqdm
  Running setup.py install for netifaces ... error
    Complete output from command /Library/Frameworks/Python.framework/Versions/2.7/Resources/Python.app/Contents/MacOS/Python -u -c "import setuptools, tokenize;__file__='/private/tmp/pip-build-_c8xo6/netifaces/setup.py';f=getattr(tokenize, 'open', open)(__file__);code=f.read().replace('\r\n', '\n');f.close();exec(compile(code, __file__, 'exec'))" install --record /tmp/pip-Z1MLLx-record/install-record.txt --single-version-externally-managed --compile:
    running install
    running build
    running build_ext
    checking for getifaddrs...not found.
    checking for getnameinfo...not found.
    checking for socket IOCTLs...not found.
    checking for optional header files...none found.
    checking whether struct sockaddr has a length field...no.
    checking which sockaddr_xxx structs are defined...none!
    checking for routing socket support...no.
    checking for sysctl(CTL_NET...) support...no.
    checking for netlink support...no.
    building 'netifaces' extension
    /usr/bin/clang -fno-strict-aliasing -fno-common -dynamic -arch i386 -arch x86_64 -g -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes -DNETIFACES_VERSION=0.10.5 -I/Library/Frameworks/Python.framework/Versions/2.7/include/python2.7 -c netifaces.c -o build/temp.macosx-10.6-intel-2.7/netifaces.o
    xcrun: error: invalid active developer path (/Library/Developer/CommandLineTools), missing xcrun at: /Library/Developer/CommandLineTools/usr/bin/xcrun
    error: command '/usr/bin/clang' failed with exit status 1

    ----------------------------------------
Command "/Library/Frameworks/Python.framework/Versions/2.7/Resources/Python.app/Contents/MacOS/Python -u -c "import setuptools, tokenize;__file__='/private/tmp/pip-build-_c8xo6/netifaces/setup.py';f=getattr(tokenize, 'open', open)(__file__);code=f.read().replace('\r\n', '\n');f.close();exec(compile(code, __file__, 'exec'))" install --record /tmp/pip-Z1MLLx-record/install-record.txt --single-version-externally-managed --compile" failed with error code 1 in /private/tmp/pip-build-_c8xo6/netifaces/
vansuita:FreeWifi jrvansuita$ 
kylemcdonald commented 7 years ago

it looks like your command line tools aren't installed: error: invalid active developer path (/Library/Developer/CommandLineTools), try:

sudo xcode-select --install

based on http://apple.stackexchange.com/questions/254380/macos-sierra-invalid-active-developer-path