This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

classification
Title: Main branch of CPython does not build anymore on macOS
Type: compile error Stage: resolved
Components: Build Versions: Python 3.11
process
Status: closed Resolution: not a bug
Dependencies: Superseder:
Assigned To: Nosy List: andrei.avk, ned.deily, sobolevn
Priority: normal Keywords:

Created on 2021-12-06 08:00 by sobolevn, last changed 2022-04-11 14:59 by admin. This issue is now closed.

Files
File name Uploaded Description Edit
Makefile sobolevn, 2021-12-06 08:00
Messages (5)
msg407773 - (view) Author: Nikita Sobolev (sobolevn) * (Python triager) Date: 2021-12-06 08:00
New version of `main` branch does not build for me anymore.

Command: `make -j`
System information: 
- macOS 10.14.6
- Apple clang version 11.0.0 (clang-1100.0.33.16)

I am also attaching resulting Makefile.

Output:

```
» make -j
gcc -L/usr/local/opt/openssl/lib -L/usr/local/opt/openssl/lib   -o Programs/_freeze_module Programs/_freeze_module.o Modules/getpath_noop.o Modules/getbuildinfo.o Parser/token.o  Parser/pegen.o Parser/pegen_errors.o Parser/action_helpers.o Parser/parser.o Parser/string_parser.o Parser/peg_api.o Parser/myreadline.o Parser/tokenizer.o Objects/abstract.o Objects/accu.o Objects/boolobject.o Objects/bytes_methods.o Objects/bytearrayobject.o Objects/bytesobject.o Objects/call.o Objects/capsule.o Objects/cellobject.o Objects/classobject.o Objects/codeobject.o Objects/complexobject.o Objects/descrobject.o Objects/enumobject.o Objects/exceptions.o Objects/genericaliasobject.o Objects/genobject.o Objects/fileobject.o Objects/floatobject.o Objects/frameobject.o Objects/funcobject.o Objects/interpreteridobject.o Objects/iterobject.o Objects/listobject.o Objects/longobject.o Objects/dictobject.o Objects/odictobject.o Objects/memoryobject.o Objects/methodobject.o Objects/moduleobject.o Objects/namespaceobject.o Objects/object.o Objects/obmalloc.o Objects/picklebufobject.o Objects/rangeobject.o Objects/setobject.o Objects/sliceobject.o Objects/structseq.o Objects/tupleobject.o Objects/typeobject.o Objects/unicodeobject.o Objects/unicodectype.o Objects/unionobject.o Objects/weakrefobject.o Python/_warnings.o Python/Python-ast.o Python/Python-tokenize.o Python/asdl.o Python/ast.o Python/ast_opt.o Python/ast_unparse.o Python/bltinmodule.o Python/ceval.o Python/codecs.o Python/compile.o Python/context.o Python/dynamic_annotations.o Python/errors.o Python/frame.o Python/frozenmain.o Python/future.o Python/getargs.o Python/getcompiler.o Python/getcopyright.o Python/getplatform.o Python/getversion.o Python/hamt.o Python/hashtable.o Python/import.o Python/importdl.o Python/initconfig.o Python/marshal.o Python/modsupport.o Python/mysnprintf.o Python/mystrtoul.o Python/pathconfig.o Python/preconfig.o Python/pyarena.o Python/pyctype.o Python/pyfpe.o Python/pyhash.o Python/pylifecycle.o Python/pymath.o Python/pystate.o Python/pythonrun.o Python/pytime.o Python/bootstrap_hash.o Python/specialize.o Python/structmember.o Python/symtable.o Python/sysmodule.o Python/thread.o Python/traceback.o Python/getopt.o Python/pystrcmp.o Python/pystrtod.o Python/pystrhex.o Python/dtoa.o Python/formatter_unicode.o Python/fileutils.o Python/suggestions.o Python/dynload_shlib.o    Modules/config.o Modules/main.o Modules/gcmodule.o Modules/xxsubtype.o -lintl -ldl  -framework CoreFoundation    
Undefined symbols for architecture x86_64:
  "_PyErr_CheckSignals", referenced from:
      _my_fgets in myreadline.o
      _long_to_decimal_string_internal in longobject.o
      _x_mul in longobject.o
      _x_divrem in longobject.o
      _PyObject_Print in object.o
      _PyObject_Str in object.o
      _PyObject_Repr in object.o
      ...
  "_PyOS_FSPath", referenced from:
      _PyUnicode_FSConverter in unicodeobject.o
      _PyUnicode_FSDecoder in unicodeobject.o
  "__PyAtExit_Call", referenced from:
      _Py_FinalizeEx in pylifecycle.o
      _Py_EndInterpreter in pylifecycle.o
  "__PyAtExit_Fini", referenced from:
      _interpreter_clear in pystate.o
  "__PyAtExit_Init", referenced from:
      _pycore_interp_init in pylifecycle.o
  "__PyErr_CheckSignalsTstate", referenced from:
      _handle_signals in ceval.o
  "__PyFaulthandler_Fini", referenced from:
      _Py_FinalizeEx in pylifecycle.o
      _fatal_error in pylifecycle.o
  "__PyFaulthandler_Init", referenced from:
      _init_interp_main in pylifecycle.o
  "__PyMem_DumpTraceback", referenced from:
      __PyObject_AssertFailed in object.o
      __PyObject_DebugDumpAddress in obmalloc.o
  "__PyOS_InterruptOccurred", referenced from:
      _my_fgets in myreadline.o
  "__PySignal_Fini", referenced from:
      _Py_FinalizeEx in pylifecycle.o
  "__PySignal_Init", referenced from:
      _init_interp_main in pylifecycle.o
  "__PyTraceMalloc_Fini", referenced from:
      _Py_FinalizeEx in pylifecycle.o
  "__PyTraceMalloc_Init", referenced from:
      _init_interp_main in pylifecycle.o
  "__PyTraceMalloc_NewReference", referenced from:
      __Py_NewReference in object.o
ld: symbol(s) not found for architecture x86_64
clang: error: linker command failed with exit code 1 (use -v to see invocation)
make: *** [Programs/_freeze_module] Error 1
```
msg407774 - (view) Author: Christian Heimes (christian.heimes) * (Python committer) Date: 2021-12-06 08:27
Did you run "make distclean" or "git clean -xdf" before ./configure?
msg407778 - (view) Author: Nikita Sobolev (sobolevn) * (Python triager) Date: 2021-12-06 09:32
Looks like removing cache worked. Thanks!
msg414926 - (view) Author: Andrei Kulakov (andrei.avk) * (Python triager) Date: 2022-03-11 17:45
I'm getting the same exact error but on `arm64`, and clearing the cache does not help.

clang=13.0.0
MacOS=11.5.2

Should I open a new issue for this?


257 warnings generated.
257 warnings generated.
Undefined symbols for architecture arm64:
  "_libintl_bindtextdomain", referenced from:
      __locale_bindtextdomain_impl in _localemodule.o
  "_libintl_dcgettext", referenced from:
      __locale_dcgettext_impl in _localemodule.o
  "_libintl_dgettext", referenced from:
      __locale_dgettext_impl in _localemodule.o
  "_libintl_gettext", referenced from:
      __locale_gettext_impl in _localemodule.o
  "_libintl_setlocale", referenced from:
      __locale_setlocale_impl in _localemodule.o
      _locale_decode_monetary in _localemodule.o
  "_libintl_textdomain", referenced from:
      __locale_textdomain_impl in _localemodule.o
ld: symbol(s) not found for architecture arm64
clang: error: linker command failed with exit code 1 (use -v to see invocation)
make: *** [Programs/_freeze_module] Error 1
msg415018 - (view) Author: Ned Deily (ned.deily) * (Python committer) Date: 2022-03-12 22:17
@Andrei, see Issue46975.
History
Date User Action Args
2022-04-11 14:59:53adminsetgithub: 90151
2022-03-12 22:17:33ned.deilysetnosy: + ned.deily
messages: + msg415018
2022-03-11 18:43:26christian.heimessetnosy: - christian.heimes
2022-03-11 17:45:48andrei.avksetnosy: + andrei.avk
messages: + msg414926
2021-12-06 09:32:49sobolevnsetstatus: open -> closed
resolution: not a bug
messages: + msg407778

stage: resolved
2021-12-06 08:27:42christian.heimessetnosy: + christian.heimes
messages: + msg407774
2021-12-06 08:00:18sobolevncreate