Visitar URL original
Add explicit check to silence warning on MacOS by remilapeyre · Pull Request #12384 · python/cpython · GitHub
The Wayback Machine - https://web.archive.org/web/20260217075657/https://github.com/python/cpython/pull/12384
Skip to content
/ cpython Public

Add explicit check to silence warning on MacOS#12384

Merged
methane merged 2 commits intopython:masterfrom
remilapeyre:unreachable-code-warning-on-macos-x
May 3, 2019
Merged

Add explicit check to silence warning on MacOS#12384
methane merged 2 commits intopython:masterfrom
remilapeyre:unreachable-code-warning-on-macos-x

Conversation

@remilapeyre
Copy link

skip news
skip bpo

@methane
Copy link
Member

methane commented Mar 20, 2019

I don't see such warning on macOS.

@remilapeyre
Copy link
Author

Hi @methane, I am using clang version 10.0.0 and I only get the warning when I am not using --with-pydebug. I still get it on master (cc60cdd):

➜  cpython git:(cc60cdd9c4) make distclean -s 2>/dev/null && ./configure --with-openssl=$(brew --prefix openssl) 2>&1 >/dev/null && make clean -s 2>/dev/null&& make -sj
Configured with: --prefix=/Library/Developer/CommandLineTools/usr --with-gxx-include-dir=/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/c++/4.2.1
./Modules/posixmodule.c:1266:9: warning: code will never be executed [-Wunreachable-code]
        PyErr_SetFromErrno(PyExc_OSError);
        ^~~~~~~~~~~~~~~~~~
1 warning generated.
/Library/Developer/CommandLineTools/usr/bin/ranlib: file: libpython3.8m.a(dynamic_annotations.o) has no symbols
/Library/Developer/CommandLineTools/usr/bin/ranlib: file: libpython3.8m.a(pymath.o) has no symbols
 CC='gcc' LDSHARED='gcc -bundle -undefined dynamic_lookup -L/usr/local/opt/zlib/lib -L/usr/local/opt/zlib/lib  ' OPT='-DNDEBUG -g -fwrapv -O3 -Wall' 	_TCLTK_INCLUDES='' _TCLTK_LIBS='' 	./python.exe -E ./setup.py -q build
ld: warning: directory not found for option '-L/usr/lib/termcap'
clang: warning: -framework Tk: 'linker' input unused [-Wunused-command-line-argument]
clang: warning: -framework Tk: 'linker' input unused [-Wunused-command-line-argument]
ld: warning: could not create compact unwind for _ffi_call_unix64: does not use RBP or RSP based frame

Python build finished successfully!
The necessary bits to build these optional modules were not found:
_dbm                  _sqlite3              _uuid
nis                   ossaudiodev           spwd
To find the necessary bits, look in setup.py in detect_modules() for the module's name.


The following modules found by detect_modules() in setup.py, have been
built by the Makefile instead, as configured by the Setup files:
_abc                  atexit                pwd
time

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants