Thread: [Pyobjc-dev] compilation issues on Py3.5, os x 10.10.5
Brought to you by:
ronaldoussoren
From: Diez B. R. <de...@we...> - 2016-07-28 13:43:43
|
Hi, I get the problem quoted below after trying to install pyobjc on my 10.10.5 System, Xcode version 7.2 into a vanilla Python3.5 Googling resulted in http://stackoverflow.com/questions/37525929/python-pyobjc-idtopythonprotocolnsurlsessionstreamdelegate-error <http://stackoverflow.com/questions/37525929/python-pyobjc-idtopythonprotocolnsurlsessionstreamdelegate-error>, which again on a vanilla Python 3.5 succeeds installing, but gives the second error below. Any suggestions are welcome. Cheers, Diez Error message for normal install: running build_ext building 'CoreFoundation._inlines' extension creating build/temp.macosx-10.6-intel-3.5/Modules /usr/bin/clang -fno-strict-aliasing -Wsign-compare -fno-common -dynamic -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes -arch i386 -arch x86_64 -g -Ibuild/temp.macosx-10.6-intel-3.5/pyobjc-include -I/Library/Frameworks/Python.framework/Versions/3.5/include/python3.5m -c Modules/_CoreFoundation_inlines.m -o build/temp.macosx-10.6-intel-3.5/Modules/_CoreFoundation_inlines.o -DPyObjC_BUILD_RELEASE=1010 -isysroot / /usr/bin/clang -bundle -undefined dynamic_lookup -arch i386 -arch x86_64 -g build/temp.macosx-10.6-intel-3.5/Modules/_CoreFoundation_inlines.o -o build/lib.macosx-10.6-intel-3.5/CoreFoundation/_inlines.cpython-35m-darwin.so -framework CoreFoundation -isysroot / building 'CoreFoundation._CoreFoundation' extension /usr/bin/clang -fno-strict-aliasing -Wsign-compare -fno-common -dynamic -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes -arch i386 -arch x86_64 -g -Ibuild/temp.macosx-10.6-intel-3.5/pyobjc-include -I/Library/Frameworks/Python.framework/Versions/3.5/include/python3.5m -c Modules/_CoreFoundation.m -o build/temp.macosx-10.6-intel-3.5/Modules/_CoreFoundation.o -DPyObjC_BUILD_RELEASE=1010 -isysroot / /usr/bin/clang -bundle -undefined dynamic_lookup -arch i386 -arch x86_64 -g build/temp.macosx-10.6-intel-3.5/Modules/_CoreFoundation.o -o build/lib.macosx-10.6-intel-3.5/CoreFoundation/_CoreFoundation.cpython-35m-darwin.so -framework CoreFoundation -isysroot / building 'Foundation._inlines' extension /usr/bin/clang -fno-strict-aliasing -Wsign-compare -fno-common -dynamic -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes -arch i386 -arch x86_64 -g -Ibuild/temp.macosx-10.6-intel-3.5/pyobjc-include -I/Library/Frameworks/Python.framework/Versions/3.5/include/python3.5m -c Modules/_Foundation_inlines.m -o build/temp.macosx-10.6-intel-3.5/Modules/_Foundation_inlines.o -DPyObjC_BUILD_RELEASE=1010 -isysroot / /usr/bin/clang -bundle -undefined dynamic_lookup -arch i386 -arch x86_64 -g build/temp.macosx-10.6-intel-3.5/Modules/_Foundation_inlines.o -o build/lib.macosx-10.6-intel-3.5/Foundation/_inlines.cpython-35m-darwin.so -framework Foundation -isysroot / building 'Foundation._Foundation' extension /usr/bin/clang -fno-strict-aliasing -Wsign-compare -fno-common -dynamic -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes -arch i386 -arch x86_64 -g -Ibuild/temp.macosx-10.6-intel-3.5/pyobjc-include -I/Library/Frameworks/Python.framework/Versions/3.5/include/python3.5m -c Modules/_Foundation.m -o build/temp.macosx-10.6-intel-3.5/Modules/_Foundation.o -DPyObjC_BUILD_RELEASE=1010 -isysroot / In file included from Modules/_Foundation.m:15: Modules/_Foundation_protocols.m:14:28: error: cannot find protocol declaration for 'NSProgressReporting' p = PyObjC_IdToPython(@protocol(NSProgressReporting)); Py_XDECREF(p); ^ Modules/_Foundation_protocols.m:15:28: error: cannot find protocol declaration for 'NSURLSessionStreamDelegate' p = PyObjC_IdToPython(@protocol(NSURLSessionStreamDelegate)); Py_XDECREF(p); ^ 2 errors generated. error: command '/usr/bin/clang' failed with exit status 1 Error message for 3.0.4: 28 15:42:29 client2087.office.ableton.com NotoriousWIG[27812] <Notice>: 2016-07-28 15:42:29.169 NotoriousWIG[27812:4040159] NotoriousWIG Error Jul 28 15:42:31 client2087.office.ableton.com NotoriousWIG[27812] <Notice>: Traceback (most recent call last): Jul 28 15:42:31 client2087.office.ableton.com NotoriousWIG[27812] <Notice>: File "/Users/dir/projects/ableton/notorious-wig/dist/NotoriousWIG.app/Contents/Resources/__boot__.py", line 102, in <module> Jul 28 15:42:31 client2087.office.ableton.com NotoriousWIG[27812] <Notice>: _run() Jul 28 15:42:31 client2087.office.ableton.com NotoriousWIG[27812] <Notice>: File "/Users/dir/projects/ableton/notorious-wig/dist/NotoriousWIG.app/Contents/Resources/__boot__.py", line 96, in _run Jul 28 15:42:31 client2087.office.ableton.com NotoriousWIG[27812] <Notice>: exec(compile(source, script, 'exec'), globals(), globals()) Jul 28 15:42:31 client2087.office.ableton.com NotoriousWIG[27812] <Notice>: File "/Users/dir/projects/ableton/notorious-wig/Application.py", line 1, in <module> Jul 28 15:42:31 client2087.office.ableton.com NotoriousWIG[27812] <Notice>: from ApplicationDelegate import * Jul 28 15:42:31 client2087.office.ableton.com NotoriousWIG[27812] <Notice>: File "/Users/dir/projects/ableton/notorious-wig/ApplicationDelegate.py", line 4, in <module> Jul 28 15:42:31 client2087.office.ableton.com NotoriousWIG[27812] <Notice>: import objc Jul 28 15:42:31 client2087.office.ableton.com NotoriousWIG[27812] <Notice>: File "/Library/Frameworks/Python.framework/Versions/3.5/lib/python3.5/site-packages/objc/__init__.py", line 18, in <module> Jul 28 15:42:31 client2087.office.ableton.com NotoriousWIG[27812] <Notice>: _update() Jul 28 15:42:31 client2087.office.ableton.com NotoriousWIG[27812] <Notice>: File "/Library/Frameworks/Python.framework/Versions/3.5/lib/python3.5/site-packages/objc/__init__.py", line 15, in _update Jul 28 15:42:31 client2087.office.ableton.com NotoriousWIG[27812] <Notice>: import objc._objc as _objc Jul 28 15:42:31 client2087.office.ableton.com NotoriousWIG[27812] <Notice>: ImportError: dlopen(/Library/Frameworks/Python.framework/Versions/3.5/lib/python3.5/site-packages/objc/_objc.cpython-35m-darwin.so, 2): Symbol not found: _PyObject_REPR Jul 28 15:42:31 client2087.office.ableton.com NotoriousWIG[27812] <Notice>: Referenced from: /Library/Frameworks/Python.framework/Versions/3.5/lib/python3.5/site-packages/objc/_objc.cpython-35m-darwin.so Jul 28 15:42:31 client2087.office.ableton.com NotoriousWIG[27812] <Notice>: Expected in: flat namespace Jul 28 15:42:31 client2087.office.ableton.com NotoriousWIG[27812] <Notice>: in /Library/Frameworks/Python.framework/Versions/3.5/lib/python3.5/site-packages/objc/_objc.cpython-35m-darwin.so |
From: Ronald O. <ron...@ma...> - 2016-07-30 07:45:03
|
> On 28 Jul 2016, at 15:43, Diez B. Roggisch <de...@we...> wrote: > > Hi, > > I get the problem quoted below after trying to install pyobjc on my 10.10.5 System, Xcode version 7.2 into a vanilla Python3.5 > > Googling resulted in http://stackoverflow.com/questions/37525929/python-pyobjc-idtopythonprotocolnsurlsessionstreamdelegate-error <http://stackoverflow.com/questions/37525929/python-pyobjc-idtopythonprotocolnsurlsessionstreamdelegate-error>, which again on a vanilla Python 3.5 succeeds installing, but gives the second error below. > > Any suggestions are welcome. For some reason PyObjC thinks it is building with the OSX 10.10 SDK, while it is building with an older SDK. Because of this it tries to reference a symbol that isn’t present in the SDK that is used. The “-isysroot /“ flag in the output below explains the behavior, setup.py cannot deduce the SDK used from the sysroot parameter and therefore assumes the SDK version matches the OSX version. Are you using the 3.5 installer from www.python.org? Ronald > > Cheers, > > Diez > > > Error message for normal install: > > running build_ext > building 'CoreFoundation._inlines' extension > creating build/temp.macosx-10.6-intel-3.5/Modules > /usr/bin/clang -fno-strict-aliasing -Wsign-compare -fno-common -dynamic -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes -arch i386 -arch x86_64 -g -Ibuild/temp.macosx-10.6-intel-3.5/pyobjc-include -I/Library/Frameworks/Python.framework/Versions/3.5/include/python3.5m -c Modules/_CoreFoundation_inlines.m -o build/temp.macosx-10.6-intel-3.5/Modules/_CoreFoundation_inlines.o -DPyObjC_BUILD_RELEASE=1010 -isysroot / > /usr/bin/clang -bundle -undefined dynamic_lookup -arch i386 -arch x86_64 -g build/temp.macosx-10.6-intel-3.5/Modules/_CoreFoundation_inlines.o -o build/lib.macosx-10.6-intel-3.5/CoreFoundation/_inlines.cpython-35m-darwin.so -framework CoreFoundation -isysroot / > building 'CoreFoundation._CoreFoundation' extension > /usr/bin/clang -fno-strict-aliasing -Wsign-compare -fno-common -dynamic -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes -arch i386 -arch x86_64 -g -Ibuild/temp.macosx-10.6-intel-3.5/pyobjc-include -I/Library/Frameworks/Python.framework/Versions/3.5/include/python3.5m -c Modules/_CoreFoundation.m -o build/temp.macosx-10.6-intel-3.5/Modules/_CoreFoundation.o -DPyObjC_BUILD_RELEASE=1010 -isysroot / > /usr/bin/clang -bundle -undefined dynamic_lookup -arch i386 -arch x86_64 -g build/temp.macosx-10.6-intel-3.5/Modules/_CoreFoundation.o -o build/lib.macosx-10.6-intel-3.5/CoreFoundation/_CoreFoundation.cpython-35m-darwin.so -framework CoreFoundation -isysroot / > building 'Foundation._inlines' extension > /usr/bin/clang -fno-strict-aliasing -Wsign-compare -fno-common -dynamic -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes -arch i386 -arch x86_64 -g -Ibuild/temp.macosx-10.6-intel-3.5/pyobjc-include -I/Library/Frameworks/Python.framework/Versions/3.5/include/python3.5m -c Modules/_Foundation_inlines.m -o build/temp.macosx-10.6-intel-3.5/Modules/_Foundation_inlines.o -DPyObjC_BUILD_RELEASE=1010 -isysroot / > /usr/bin/clang -bundle -undefined dynamic_lookup -arch i386 -arch x86_64 -g build/temp.macosx-10.6-intel-3.5/Modules/_Foundation_inlines.o -o build/lib.macosx-10.6-intel-3.5/Foundation/_inlines.cpython-35m-darwin.so -framework Foundation -isysroot / > building 'Foundation._Foundation' extension > /usr/bin/clang -fno-strict-aliasing -Wsign-compare -fno-common -dynamic -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes -arch i386 -arch x86_64 -g -Ibuild/temp.macosx-10.6-intel-3.5/pyobjc-include -I/Library/Frameworks/Python.framework/Versions/3.5/include/python3.5m -c Modules/_Foundation.m -o build/temp.macosx-10.6-intel-3.5/Modules/_Foundation.o -DPyObjC_BUILD_RELEASE=1010 -isysroot / > In file included from Modules/_Foundation.m:15: > Modules/_Foundation_protocols.m:14:28: error: cannot find protocol declaration for 'NSProgressReporting' > p = PyObjC_IdToPython(@protocol(NSProgressReporting)); Py_XDECREF(p); > ^ > Modules/_Foundation_protocols.m:15:28: error: cannot find protocol declaration for 'NSURLSessionStreamDelegate' > p = PyObjC_IdToPython(@protocol(NSURLSessionStreamDelegate)); Py_XDECREF(p); > ^ > 2 errors generated. > error: command '/usr/bin/clang' failed with exit status 1 > > > > Error message for 3.0.4: > > 28 15:42:29 client2087.office.ableton.com <http://client2087.office.ableton.com/> NotoriousWIG[27812] <Notice>: 2016-07-28 15:42:29.169 NotoriousWIG[27812:4040159] NotoriousWIG Error > Jul 28 15:42:31 client2087.office.ableton.com <http://client2087.office.ableton.com/> NotoriousWIG[27812] <Notice>: Traceback (most recent call last): > Jul 28 15:42:31 client2087.office.ableton.com <http://client2087.office.ableton.com/> NotoriousWIG[27812] <Notice>: File "/Users/dir/projects/ableton/notorious-wig/dist/NotoriousWIG.app/Contents/Resources/__boot__.py", line 102, in <module> > Jul 28 15:42:31 client2087.office.ableton.com <http://client2087.office.ableton.com/> NotoriousWIG[27812] <Notice>: _run() > Jul 28 15:42:31 client2087.office.ableton.com <http://client2087.office.ableton.com/> NotoriousWIG[27812] <Notice>: File "/Users/dir/projects/ableton/notorious-wig/dist/NotoriousWIG.app/Contents/Resources/__boot__.py", line 96, in _run > Jul 28 15:42:31 client2087.office.ableton.com <http://client2087.office.ableton.com/> NotoriousWIG[27812] <Notice>: exec(compile(source, script, 'exec'), globals(), globals()) > Jul 28 15:42:31 client2087.office.ableton.com <http://client2087.office.ableton.com/> NotoriousWIG[27812] <Notice>: File "/Users/dir/projects/ableton/notorious-wig/Application.py", line 1, in <module> > Jul 28 15:42:31 client2087.office.ableton.com <http://client2087.office.ableton.com/> NotoriousWIG[27812] <Notice>: from ApplicationDelegate import * > Jul 28 15:42:31 client2087.office.ableton.com <http://client2087.office.ableton.com/> NotoriousWIG[27812] <Notice>: File "/Users/dir/projects/ableton/notorious-wig/ApplicationDelegate.py", line 4, in <module> > Jul 28 15:42:31 client2087.office.ableton.com <http://client2087.office.ableton.com/> NotoriousWIG[27812] <Notice>: import objc > Jul 28 15:42:31 client2087.office.ableton.com <http://client2087.office.ableton.com/> NotoriousWIG[27812] <Notice>: File "/Library/Frameworks/Python.framework/Versions/3.5/lib/python3.5/site-packages/objc/__init__.py", line 18, in <module> > Jul 28 15:42:31 client2087.office.ableton.com <http://client2087.office.ableton.com/> NotoriousWIG[27812] <Notice>: _update() > Jul 28 15:42:31 client2087.office.ableton.com <http://client2087.office.ableton.com/> NotoriousWIG[27812] <Notice>: File "/Library/Frameworks/Python.framework/Versions/3.5/lib/python3.5/site-packages/objc/__init__.py", line 15, in _update > Jul 28 15:42:31 client2087.office.ableton.com <http://client2087.office.ableton.com/> NotoriousWIG[27812] <Notice>: import objc._objc as _objc > Jul 28 15:42:31 client2087.office.ableton.com <http://client2087.office.ableton.com/> NotoriousWIG[27812] <Notice>: ImportError: dlopen(/Library/Frameworks/Python.framework/Versions/3.5/lib/python3.5/site-packages/objc/_objc.cpython-35m-darwin.so, 2): Symbol not found: _PyObject_REPR > Jul 28 15:42:31 client2087.office.ableton.com <http://client2087.office.ableton.com/> NotoriousWIG[27812] <Notice>: Referenced from: /Library/Frameworks/Python.framework/Versions/3.5/lib/python3.5/site-packages/objc/_objc.cpython-35m-darwin.so > Jul 28 15:42:31 client2087.office.ableton.com <http://client2087.office.ableton.com/> NotoriousWIG[27812] <Notice>: Expected in: flat namespace > Jul 28 15:42:31 client2087.office.ableton.com <http://client2087.office.ableton.com/> NotoriousWIG[27812] <Notice>: in /Library/Frameworks/Python.framework/Versions/3.5/lib/python3.5/site-packages/objc/_objc.cpython-35m-darwin.so > ------------------------------------------------------------------------------ > _______________________________________________ > Pyobjc-dev mailing list > Pyo...@li... > https://lists.sourceforge.net/lists/listinfo/pyobjc-dev |
From: Diez B. R. <de...@we...> - 2016-07-30 09:50:43
Attachments:
signature.asc
|
Hi Ronald, > For some reason PyObjC thinks it is building with the OSX 10.10 SDK, while it is building with an older SDK. Because of this it tries to reference a symbol that isn’t present in the SDK that is used. The “-isysroot /“ flag in the output below explains the behavior, setup.py cannot deduce the SDK used from the sysroot parameter and therefore assumes the SDK version matches the OSX version. > > Are you using the 3.5 installer from www.python.org <http://www.python.org/>? Yes, I do. Wiped & re-installed explicitly before attempting to install. I will try your suggestion about /usr/include/stdio.h on monday (it’s my work-machine), and report back. Cheers, Diez |
From: Ronald O. <ron...@ma...> - 2016-07-30 08:01:22
|
> On 30 Jul 2016, at 09:44, Ronald Oussoren <ron...@ma...> wrote: > >> >> On 28 Jul 2016, at 15:43, Diez B. Roggisch <de...@we... <mailto:de...@we...>> wrote: >> >> Hi, >> >> I get the problem quoted below after trying to install pyobjc on my 10.10.5 System, Xcode version 7.2 into a vanilla Python3.5 >> >> Googling resulted in http://stackoverflow.com/questions/37525929/python-pyobjc-idtopythonprotocolnsurlsessionstreamdelegate-error <http://stackoverflow.com/questions/37525929/python-pyobjc-idtopythonprotocolnsurlsessionstreamdelegate-error>, which again on a vanilla Python 3.5 succeeds installing, but gives the second error below. >> >> Any suggestions are welcome. > > For some reason PyObjC thinks it is building with the OSX 10.10 SDK, while it is building with an older SDK. Because of this it tries to reference a symbol that isn’t present in the SDK that is used. The “-isysroot /“ flag in the output below explains the behavior, setup.py cannot deduce the SDK used from the sysroot parameter and therefore assumes the SDK version matches the OSX version. I just noticed some old code in the setup.py files for PyObjC that could cause this error. I’ll be testing on older OSX releases once I finish my work on 10.12 support and will try to remove or fix that old code when I do so. Could you check if you have a file named “/usr/include/stdio.h” on your system? If so, please try building without this file (basically: move or rename it, then build PyObjC, then restore the file). Ronald |
From: Diez B. R. <de...@we...> - 2016-08-02 10:13:40
|
Hi, back at work, I tried your below suggestion. It falis with running build_ext building 'CoreFoundation._inlines' extension creating build/temp.macosx-10.6-intel-3.5/Modules /usr/bin/clang -fno-strict-aliasing -Wsign-compare -fno-common -dynamic -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes -arch i386 -arch x86_64 -g -Ibuild/temp.macosx-10.6-intel-3.5/pyobjc-include -I/Library/Frameworks/Python.framework/Versions/3.5/include/python3.5m -c Modules/_CoreFoundation_inlines.m -o build/temp.macosx-10.6-intel-3.5/Modules/_CoreFoundation_inlines.o -DPyObjC_BUILD_RELEASE=1010 In file included from Modules/_CoreFoundation_inlines.m:2: /Library/Frameworks/Python.framework/Versions/3.5/include/python3.5m/Python.h:25:10: fatal error: 'stdio.h' file not found #include <stdio.h> ^ 1 error generated. error: command '/usr/bin/clang' failed with exit status 1 Cheers, Diez > On 30 Jul 2016, at 10:01, Ronald Oussoren <ron...@ma...> wrote: > >> >> On 30 Jul 2016, at 09:44, Ronald Oussoren <ron...@ma... <mailto:ron...@ma...>> wrote: >> >>> >>> On 28 Jul 2016, at 15:43, Diez B. Roggisch <de...@we... <mailto:de...@we...>> wrote: >>> >>> Hi, >>> >>> I get the problem quoted below after trying to install pyobjc on my 10.10.5 System, Xcode version 7.2 into a vanilla Python3.5 >>> >>> Googling resulted in http://stackoverflow.com/questions/37525929/python-pyobjc-idtopythonprotocolnsurlsessionstreamdelegate-error <http://stackoverflow.com/questions/37525929/python-pyobjc-idtopythonprotocolnsurlsessionstreamdelegate-error>, which again on a vanilla Python 3.5 succeeds installing, but gives the second error below. >>> >>> Any suggestions are welcome. >> >> For some reason PyObjC thinks it is building with the OSX 10.10 SDK, while it is building with an older SDK. Because of this it tries to reference a symbol that isn’t present in the SDK that is used. The “-isysroot /“ flag in the output below explains the behavior, setup.py cannot deduce the SDK used from the sysroot parameter and therefore assumes the SDK version matches the OSX version. > > I just noticed some old code in the setup.py files for PyObjC that could cause this error. I’ll be testing on older OSX releases once I finish my work on 10.12 support and will try to remove or fix that old code when I do so. > > Could you check if you have a file named “/usr/include/stdio.h” on your system? If so, please try building without this file (basically: move or rename it, then build PyObjC, then restore the file). > > Ronald |
From: Ronald O. <ron...@ma...> - 2016-08-07 09:22:25
|
> On 02 Aug 2016, at 12:13, Diez B. Roggisch <de...@we...> wrote: > > Hi, > > back at work, I tried your below suggestion. > > > It falis with > > running build_ext > building 'CoreFoundation._inlines' extension > creating build/temp.macosx-10.6-intel-3.5/Modules > /usr/bin/clang -fno-strict-aliasing -Wsign-compare -fno-common -dynamic -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes -arch i386 -arch x86_64 -g -Ibuild/temp.macosx-10.6-intel-3.5/pyobjc-include -I/Library/Frameworks/Python.framework/Versions/3.5/include/python3.5m -c Modules/_CoreFoundation_inlines.m -o build/temp.macosx-10.6-intel-3.5/Modules/_CoreFoundation_inlines.o -DPyObjC_BUILD_RELEASE=1010 > In file included from Modules/_CoreFoundation_inlines.m:2: > /Library/Frameworks/Python.framework/Versions/3.5/include/python3.5m/Python.h:25:10: fatal error: 'stdio.h' file not found > #include <stdio.h> > ^ > 1 error generated. > error: command '/usr/bin/clang' failed with exit status 1 That’s annoying. I don’t understand why the build does not use the SDK inside the Xcode.app package on your machine. Ronald > > Cheers, > > Diez > >> On 30 Jul 2016, at 10:01, Ronald Oussoren <ron...@ma... <mailto:ron...@ma...>> wrote: >> >>> >>> On 30 Jul 2016, at 09:44, Ronald Oussoren <ron...@ma... <mailto:ron...@ma...>> wrote: >>> >>>> >>>> On 28 Jul 2016, at 15:43, Diez B. Roggisch <de...@we... <mailto:de...@we...>> wrote: >>>> >>>> Hi, >>>> >>>> I get the problem quoted below after trying to install pyobjc on my 10.10.5 System, Xcode version 7.2 into a vanilla Python3.5 >>>> >>>> Googling resulted in http://stackoverflow.com/questions/37525929/python-pyobjc-idtopythonprotocolnsurlsessionstreamdelegate-error <http://stackoverflow.com/questions/37525929/python-pyobjc-idtopythonprotocolnsurlsessionstreamdelegate-error>, which again on a vanilla Python 3.5 succeeds installing, but gives the second error below. >>>> >>>> Any suggestions are welcome. >>> >>> For some reason PyObjC thinks it is building with the OSX 10.10 SDK, while it is building with an older SDK. Because of this it tries to reference a symbol that isn’t present in the SDK that is used. The “-isysroot /“ flag in the output below explains the behavior, setup.py cannot deduce the SDK used from the sysroot parameter and therefore assumes the SDK version matches the OSX version. >> >> I just noticed some old code in the setup.py files for PyObjC that could cause this error. I’ll be testing on older OSX releases once I finish my work on 10.12 support and will try to remove or fix that old code when I do so. >> >> Could you check if you have a file named “/usr/include/stdio.h” on your system? If so, please try building without this file (basically: move or rename it, then build PyObjC, then restore the file). >> >> Ronald > > ------------------------------------------------------------------------------ > _______________________________________________ > Pyobjc-dev mailing list > Pyo...@li... > https://lists.sourceforge.net/lists/listinfo/pyobjc-dev |
From: Ronald O. <ron...@ma...> - 2016-08-07 10:54:12
|
> On 07 Aug 2016, at 11:22, Ronald Oussoren <ron...@ma...> wrote: > >> >> On 02 Aug 2016, at 12:13, Diez B. Roggisch <de...@we... <mailto:de...@we...>> wrote: >> >> Hi, >> >> back at work, I tried your below suggestion. >> >> >> It falis with >> >> running build_ext >> building 'CoreFoundation._inlines' extension >> creating build/temp.macosx-10.6-intel-3.5/Modules >> /usr/bin/clang -fno-strict-aliasing -Wsign-compare -fno-common -dynamic -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes -arch i386 -arch x86_64 -g -Ibuild/temp.macosx-10.6-intel-3.5/pyobjc-include -I/Library/Frameworks/Python.framework/Versions/3.5/include/python3.5m -c Modules/_CoreFoundation_inlines.m -o build/temp.macosx-10.6-intel-3.5/Modules/_CoreFoundation_inlines.o -DPyObjC_BUILD_RELEASE=1010 >> In file included from Modules/_CoreFoundation_inlines.m:2: >> /Library/Frameworks/Python.framework/Versions/3.5/include/python3.5m/Python.h:25:10: fatal error: 'stdio.h' file not found >> #include <stdio.h> >> ^ >> 1 error generated. >> error: command '/usr/bin/clang' failed with exit status 1 > > That’s annoying. I don’t understand why the build does not use the SDK inside the Xcode.app package on your machine. I might be onto something. Did you install the command-line tools package? I installed both Xcode 7.2 and the command-line tools (using “xcode-select —install”) and that gives me the same error. The same VM did work properly before I installed the command-line tools. I don’t know yet how to work around this problem, the compiler command-lines are the same on both machines. Ronald > > Ronald > >> >> Cheers, >> >> Diez >> >>> On 30 Jul 2016, at 10:01, Ronald Oussoren <ron...@ma... <mailto:ron...@ma...>> wrote: >>> >>>> >>>> On 30 Jul 2016, at 09:44, Ronald Oussoren <ron...@ma... <mailto:ron...@ma...>> wrote: >>>> >>>>> >>>>> On 28 Jul 2016, at 15:43, Diez B. Roggisch <de...@we... <mailto:de...@we...>> wrote: >>>>> >>>>> Hi, >>>>> >>>>> I get the problem quoted below after trying to install pyobjc on my 10.10.5 System, Xcode version 7.2 into a vanilla Python3.5 >>>>> >>>>> Googling resulted in http://stackoverflow.com/questions/37525929/python-pyobjc-idtopythonprotocolnsurlsessionstreamdelegate-error <http://stackoverflow.com/questions/37525929/python-pyobjc-idtopythonprotocolnsurlsessionstreamdelegate-error>, which again on a vanilla Python 3.5 succeeds installing, but gives the second error below. >>>>> >>>>> Any suggestions are welcome. >>>> >>>> For some reason PyObjC thinks it is building with the OSX 10.10 SDK, while it is building with an older SDK. Because of this it tries to reference a symbol that isn’t present in the SDK that is used. The “-isysroot /“ flag in the output below explains the behavior, setup.py cannot deduce the SDK used from the sysroot parameter and therefore assumes the SDK version matches the OSX version. >>> >>> I just noticed some old code in the setup.py files for PyObjC that could cause this error. I’ll be testing on older OSX releases once I finish my work on 10.12 support and will try to remove or fix that old code when I do so. >>> >>> Could you check if you have a file named “/usr/include/stdio.h” on your system? If so, please try building without this file (basically: move or rename it, then build PyObjC, then restore the file). >>> >>> Ronald >> >> ------------------------------------------------------------------------------ >> _______________________________________________ >> Pyobjc-dev mailing list >> Pyo...@li... <mailto:Pyo...@li...> >> https://lists.sourceforge.net/lists/listinfo/pyobjc-dev > > ------------------------------------------------------------------------------ > _______________________________________________ > Pyobjc-dev mailing list > Pyo...@li... <mailto:Pyo...@li...> > https://lists.sourceforge.net/lists/listinfo/pyobjc-dev <https://lists.sourceforge.net/lists/listinfo/pyobjc-dev> |
From: Ronald O. <ron...@ma...> - 2016-08-07 11:16:35
|
> On 07 Aug 2016, at 12:54, Ronald Oussoren <ron...@ma...> wrote: > >> >> On 07 Aug 2016, at 11:22, Ronald Oussoren <ron...@ma... <mailto:ron...@ma...>> wrote: >> >>> >>> On 02 Aug 2016, at 12:13, Diez B. Roggisch <de...@we... <mailto:de...@we...>> wrote: >>> >>> Hi, >>> >>> back at work, I tried your below suggestion. >>> >>> >>> It falis with >>> >>> running build_ext >>> building 'CoreFoundation._inlines' extension >>> creating build/temp.macosx-10.6-intel-3.5/Modules >>> /usr/bin/clang -fno-strict-aliasing -Wsign-compare -fno-common -dynamic -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes -arch i386 -arch x86_64 -g -Ibuild/temp.macosx-10.6-intel-3.5/pyobjc-include -I/Library/Frameworks/Python.framework/Versions/3.5/include/python3.5m -c Modules/_CoreFoundation_inlines.m -o build/temp.macosx-10.6-intel-3.5/Modules/_CoreFoundation_inlines.o -DPyObjC_BUILD_RELEASE=1010 >>> In file included from Modules/_CoreFoundation_inlines.m:2: >>> /Library/Frameworks/Python.framework/Versions/3.5/include/python3.5m/Python.h:25:10: fatal error: 'stdio.h' file not found >>> #include <stdio.h> >>> ^ >>> 1 error generated. >>> error: command '/usr/bin/clang' failed with exit status 1 >> >> That’s annoying. I don’t understand why the build does not use the SDK inside the Xcode.app package on your machine. > > I might be onto something. Did you install the command-line tools package? I installed both Xcode 7.2 and the command-line tools (using “xcode-select —install”) and that gives me the same error. The same VM did work properly before I installed the command-line tools. > > I don’t know yet how to work around this problem, the compiler command-lines are the same on both machines. The patch below fixes the issue for me. I haven’t checked yet if this does the right thing on any system other than one running Xcode 7.2 with the command tools installed. --- pyobjc_setup.py.orig 2016-08-07 04:03:55.000000000 -0700 +++ pyobjc_setup.py 2016-08-07 04:13:22.000000000 -0700 @@ -284,6 +284,9 @@ except (ImportError, NameError): pass + + + cc = oldcc = get_config_var('CC').split()[0] cc = _find_executable(cc) if cc is not None and os.path.basename(cc).startswith('gcc'): @@ -377,6 +380,16 @@ if 'clang' in get_config_var('CC'): cflags.append('-Wno-deprecated-declarations') + CFLAGS = get_config_var('CFLAGS') + if '-isysroot' not in CFLAGS and os.path.exists('/usr/include/stdio.h'): + # We're likely on a system with de Xcode Command Line Tools. + # Explicitly use an SDK + data = os.popen('xcodebuild -version -sdk macosx Path').read() + data = data.strip() + if data: + cflags.append('-isysroot') + cflags.append(data) + #if os_level != '10.4': # if os.path.exists('/usr/include/stdio.h'): # # only tweak the SDK when using the command-line tools > > Ronald > > >> >> Ronald >> >>> >>> Cheers, >>> >>> Diez >>> >>>> On 30 Jul 2016, at 10:01, Ronald Oussoren <ron...@ma... <mailto:ron...@ma...>> wrote: >>>> >>>>> >>>>> On 30 Jul 2016, at 09:44, Ronald Oussoren <ron...@ma... <mailto:ron...@ma...>> wrote: >>>>> >>>>>> >>>>>> On 28 Jul 2016, at 15:43, Diez B. Roggisch <de...@we... <mailto:de...@we...>> wrote: >>>>>> >>>>>> Hi, >>>>>> >>>>>> I get the problem quoted below after trying to install pyobjc on my 10.10.5 System, Xcode version 7.2 into a vanilla Python3.5 >>>>>> >>>>>> Googling resulted in http://stackoverflow.com/questions/37525929/python-pyobjc-idtopythonprotocolnsurlsessionstreamdelegate-error <http://stackoverflow.com/questions/37525929/python-pyobjc-idtopythonprotocolnsurlsessionstreamdelegate-error>, which again on a vanilla Python 3.5 succeeds installing, but gives the second error below. >>>>>> >>>>>> Any suggestions are welcome. >>>>> >>>>> For some reason PyObjC thinks it is building with the OSX 10.10 SDK, while it is building with an older SDK. Because of this it tries to reference a symbol that isn’t present in the SDK that is used. The “-isysroot /“ flag in the output below explains the behavior, setup.py cannot deduce the SDK used from the sysroot parameter and therefore assumes the SDK version matches the OSX version. >>>> >>>> I just noticed some old code in the setup.py files for PyObjC that could cause this error. I’ll be testing on older OSX releases once I finish my work on 10.12 support and will try to remove or fix that old code when I do so. >>>> >>>> Could you check if you have a file named “/usr/include/stdio.h” on your system? If so, please try building without this file (basically: move or rename it, then build PyObjC, then restore the file). >>>> >>>> Ronald >>> >>> ------------------------------------------------------------------------------ >>> _______________________________________________ >>> Pyobjc-dev mailing list >>> Pyo...@li... <mailto:Pyo...@li...> >>> https://lists.sourceforge.net/lists/listinfo/pyobjc-dev <https://lists.sourceforge.net/lists/listinfo/pyobjc-dev> >> >> ------------------------------------------------------------------------------ >> _______________________________________________ >> Pyobjc-dev mailing list >> Pyo...@li... <mailto:Pyo...@li...> >> https://lists.sourceforge.net/lists/listinfo/pyobjc-dev <https://lists.sourceforge.net/lists/listinfo/pyobjc-dev> > ------------------------------------------------------------------------------ > _______________________________________________ > Pyobjc-dev mailing list > Pyo...@li... <mailto:Pyo...@li...> > https://lists.sourceforge.net/lists/listinfo/pyobjc-dev <https://lists.sourceforge.net/lists/listinfo/pyobjc-dev> |
From: Diez B. R. <de...@we...> - 2016-08-08 09:06:33
|
Hi Ronald, >> I might be onto something. Did you install the command-line tools package? I installed both Xcode 7.2 and the command-line tools (using “xcode-select —install”) and that gives me the same error. The same VM did work properly before I installed the command-line tools. >> >> I don’t know yet how to work around this problem, the compiler command-lines are the same on both machines. I did install commandline tools, as a large part of daily development comprises C++ work. I will try & use your patch, and give feedback on the results soon. Cheers, Diez > > The patch below fixes the issue for me. I haven’t checked yet if this does the right thing on any system other than one running Xcode 7.2 with the command tools installed. > > --- pyobjc_setup.py.orig 2016-08-07 04:03:55.000000000 -0700 > +++ pyobjc_setup.py 2016-08-07 04:13:22.000000000 -0700 > @@ -284,6 +284,9 @@ > except (ImportError, NameError): > pass > > + > + > + > cc = oldcc = get_config_var('CC').split()[0] > cc = _find_executable(cc) > if cc is not None and os.path.basename(cc).startswith('gcc'): > @@ -377,6 +380,16 @@ > if 'clang' in get_config_var('CC'): > cflags.append('-Wno-deprecated-declarations') > > + CFLAGS = get_config_var('CFLAGS') > + if '-isysroot' not in CFLAGS and os.path.exists('/usr/include/stdio.h'): > + # We're likely on a system with de Xcode Command Line Tools. > + # Explicitly use an SDK > + data = os.popen('xcodebuild -version -sdk macosx Path').read() > + data = data.strip() > + if data: > + cflags.append('-isysroot') > + cflags.append(data) > + > #if os_level != '10.4': > # if os.path.exists('/usr/include/stdio.h'): > # # only tweak the SDK when using the command-line tools > >> >> Ronald >> >> >>> >>> Ronald >>> >>>> >>>> Cheers, >>>> >>>> Diez >>>> >>>>> On 30 Jul 2016, at 10:01, Ronald Oussoren <ron...@ma... <mailto:ron...@ma...>> wrote: >>>>> >>>>>> >>>>>> On 30 Jul 2016, at 09:44, Ronald Oussoren <ron...@ma... <mailto:ron...@ma...>> wrote: >>>>>> >>>>>>> >>>>>>> On 28 Jul 2016, at 15:43, Diez B. Roggisch <de...@we... <mailto:de...@we...>> wrote: >>>>>>> >>>>>>> Hi, >>>>>>> >>>>>>> I get the problem quoted below after trying to install pyobjc on my 10.10.5 System, Xcode version 7.2 into a vanilla Python3.5 >>>>>>> >>>>>>> Googling resulted in http://stackoverflow.com/questions/37525929/python-pyobjc-idtopythonprotocolnsurlsessionstreamdelegate-error <http://stackoverflow.com/questions/37525929/python-pyobjc-idtopythonprotocolnsurlsessionstreamdelegate-error>, which again on a vanilla Python 3.5 succeeds installing, but gives the second error below. >>>>>>> >>>>>>> Any suggestions are welcome. >>>>>> >>>>>> For some reason PyObjC thinks it is building with the OSX 10.10 SDK, while it is building with an older SDK. Because of this it tries to reference a symbol that isn’t present in the SDK that is used. The “-isysroot /“ flag in the output below explains the behavior, setup.py cannot deduce the SDK used from the sysroot parameter and therefore assumes the SDK version matches the OSX version. >>>>> >>>>> I just noticed some old code in the setup.py files for PyObjC that could cause this error. I’ll be testing on older OSX releases once I finish my work on 10.12 support and will try to remove or fix that old code when I do so. >>>>> >>>>> Could you check if you have a file named “/usr/include/stdio.h” on your system? If so, please try building without this file (basically: move or rename it, then build PyObjC, then restore the file). >>>>> >>>>> Ronald >>>> >>>> ------------------------------------------------------------------------------ >>>> _______________________________________________ >>>> Pyobjc-dev mailing list >>>> Pyo...@li... <mailto:Pyo...@li...> >>>> https://lists.sourceforge.net/lists/listinfo/pyobjc-dev <https://lists.sourceforge.net/lists/listinfo/pyobjc-dev> >>> >>> ------------------------------------------------------------------------------ >>> _______________________________________________ >>> Pyobjc-dev mailing list >>> Pyo...@li... <mailto:Pyo...@li...> >>> https://lists.sourceforge.net/lists/listinfo/pyobjc-dev <https://lists.sourceforge.net/lists/listinfo/pyobjc-dev> >> ------------------------------------------------------------------------------ >> _______________________________________________ >> Pyobjc-dev mailing list >> Pyo...@li... <mailto:Pyo...@li...> >> https://lists.sourceforge.net/lists/listinfo/pyobjc-dev <https://lists.sourceforge.net/lists/listinfo/pyobjc-dev> > ------------------------------------------------------------------------------ > _______________________________________________ > Pyobjc-dev mailing list > Pyo...@li... <mailto:Pyo...@li...> > https://lists.sourceforge.net/lists/listinfo/pyobjc-dev <https://lists.sourceforge.net/lists/listinfo/pyobjc-dev> |
From: Diez B. R. <de...@we...> - 2016-08-08 12:26:54
|
Ok, I tried to locate the setup.py, but for the through pip download acquired pyobjc-core-3.1.1 (which I presume is the right one?), I don’t find the necessary code part. I find similar ones, and could try patching these, but maybe it would be better if you told me what exactly you used, so I can recreate that environment more faithfully. Cheers, Diez > On 07 Aug 2016, at 13:16, Ronald Oussoren <ron...@ma...> wrote: > >> >> On 07 Aug 2016, at 12:54, Ronald Oussoren <ron...@ma... <mailto:ron...@ma...>> wrote: >> >>> >>> On 07 Aug 2016, at 11:22, Ronald Oussoren <ron...@ma... <mailto:ron...@ma...>> wrote: >>> >>>> >>>> On 02 Aug 2016, at 12:13, Diez B. Roggisch <de...@we... <mailto:de...@we...>> wrote: >>>> >>>> Hi, >>>> >>>> back at work, I tried your below suggestion. >>>> >>>> >>>> It falis with >>>> >>>> running build_ext >>>> building 'CoreFoundation._inlines' extension >>>> creating build/temp.macosx-10.6-intel-3.5/Modules >>>> /usr/bin/clang -fno-strict-aliasing -Wsign-compare -fno-common -dynamic -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes -arch i386 -arch x86_64 -g -Ibuild/temp.macosx-10.6-intel-3.5/pyobjc-include -I/Library/Frameworks/Python.framework/Versions/3.5/include/python3.5m -c Modules/_CoreFoundation_inlines.m -o build/temp.macosx-10.6-intel-3.5/Modules/_CoreFoundation_inlines.o -DPyObjC_BUILD_RELEASE=1010 >>>> In file included from Modules/_CoreFoundation_inlines.m:2: >>>> /Library/Frameworks/Python.framework/Versions/3.5/include/python3.5m/Python.h:25:10: fatal error: 'stdio.h' file not found >>>> #include <stdio.h> >>>> ^ >>>> 1 error generated. >>>> error: command '/usr/bin/clang' failed with exit status 1 >>> >>> That’s annoying. I don’t understand why the build does not use the SDK inside the Xcode.app package on your machine. >> >> I might be onto something. Did you install the command-line tools package? I installed both Xcode 7.2 and the command-line tools (using “xcode-select —install”) and that gives me the same error. The same VM did work properly before I installed the command-line tools. >> >> I don’t know yet how to work around this problem, the compiler command-lines are the same on both machines. > > The patch below fixes the issue for me. I haven’t checked yet if this does the right thing on any system other than one running Xcode 7.2 with the command tools installed. > > --- pyobjc_setup.py.orig 2016-08-07 04:03:55.000000000 -0700 > +++ pyobjc_setup.py 2016-08-07 04:13:22.000000000 -0700 > @@ -284,6 +284,9 @@ > except (ImportError, NameError): > pass > > + > + > + > cc = oldcc = get_config_var('CC').split()[0] > cc = _find_executable(cc) > if cc is not None and os.path.basename(cc).startswith('gcc'): > @@ -377,6 +380,16 @@ > if 'clang' in get_config_var('CC'): > cflags.append('-Wno-deprecated-declarations') > > + CFLAGS = get_config_var('CFLAGS') > + if '-isysroot' not in CFLAGS and os.path.exists('/usr/include/stdio.h'): > + # We're likely on a system with de Xcode Command Line Tools. > + # Explicitly use an SDK > + data = os.popen('xcodebuild -version -sdk macosx Path').read() > + data = data.strip() > + if data: > + cflags.append('-isysroot') > + cflags.append(data) > + > #if os_level != '10.4': > # if os.path.exists('/usr/include/stdio.h'): > # # only tweak the SDK when using the command-line tools > >> >> Ronald >> >> >>> >>> Ronald >>> >>>> >>>> Cheers, >>>> >>>> Diez >>>> >>>>> On 30 Jul 2016, at 10:01, Ronald Oussoren <ron...@ma... <mailto:ron...@ma...>> wrote: >>>>> >>>>>> >>>>>> On 30 Jul 2016, at 09:44, Ronald Oussoren <ron...@ma... <mailto:ron...@ma...>> wrote: >>>>>> >>>>>>> >>>>>>> On 28 Jul 2016, at 15:43, Diez B. Roggisch <de...@we... <mailto:de...@we...>> wrote: >>>>>>> >>>>>>> Hi, >>>>>>> >>>>>>> I get the problem quoted below after trying to install pyobjc on my 10.10.5 System, Xcode version 7.2 into a vanilla Python3.5 >>>>>>> >>>>>>> Googling resulted in http://stackoverflow.com/questions/37525929/python-pyobjc-idtopythonprotocolnsurlsessionstreamdelegate-error <http://stackoverflow.com/questions/37525929/python-pyobjc-idtopythonprotocolnsurlsessionstreamdelegate-error>, which again on a vanilla Python 3.5 succeeds installing, but gives the second error below. >>>>>>> >>>>>>> Any suggestions are welcome. >>>>>> >>>>>> For some reason PyObjC thinks it is building with the OSX 10.10 SDK, while it is building with an older SDK. Because of this it tries to reference a symbol that isn’t present in the SDK that is used. The “-isysroot /“ flag in the output below explains the behavior, setup.py cannot deduce the SDK used from the sysroot parameter and therefore assumes the SDK version matches the OSX version. >>>>> >>>>> I just noticed some old code in the setup.py files for PyObjC that could cause this error. I’ll be testing on older OSX releases once I finish my work on 10.12 support and will try to remove or fix that old code when I do so. >>>>> >>>>> Could you check if you have a file named “/usr/include/stdio.h” on your system? If so, please try building without this file (basically: move or rename it, then build PyObjC, then restore the file). >>>>> >>>>> Ronald >>>> >>>> ------------------------------------------------------------------------------ >>>> _______________________________________________ >>>> Pyobjc-dev mailing list >>>> Pyo...@li... <mailto:Pyo...@li...> >>>> https://lists.sourceforge.net/lists/listinfo/pyobjc-dev <https://lists.sourceforge.net/lists/listinfo/pyobjc-dev> >>> >>> ------------------------------------------------------------------------------ >>> _______________________________________________ >>> Pyobjc-dev mailing list >>> Pyo...@li... <mailto:Pyo...@li...> >>> https://lists.sourceforge.net/lists/listinfo/pyobjc-dev <https://lists.sourceforge.net/lists/listinfo/pyobjc-dev> >> ------------------------------------------------------------------------------ >> _______________________________________________ >> Pyobjc-dev mailing list >> Pyo...@li... <mailto:Pyo...@li...> >> https://lists.sourceforge.net/lists/listinfo/pyobjc-dev <https://lists.sourceforge.net/lists/listinfo/pyobjc-dev> |