cc -DNDEBUG -O2 -pipe -fno-strict-aliasing -pthread -pthread Parser/acceler.oParser/grammar1.oParser/listnode.oParser/node.oParser/parser.oParser/bitset.oParser/metagrammar.oParser/firstsets.oParser/grammar.oParser/pgen.oObjects/obmalloc.oPython/dynamic_annotations.oPython/mysnprintf.oPython/pyctype.oParser/tokenizer_pgen.oParser/printgrammar.oParser/parsetok_pgen.oParser/pgenmain.o -lutil -o Parser/pgen `Parser/pgen' is up to date. Parser/pgen ./../Grammar/Grammar Include/graminit.hPython/graminit.cParser/pgen: Permission denied *** [Include/graminit.h] Error code 126 cc -c -DNDEBUG -O2 -pipe -fno-strict-aliasing -O2 -pipe -fno-strict-aliasing -O2 -pipe -fno-strict-aliasing -I. -IInclude -I./../Include -DPy_BUILD_CORE -o Objects/typeobject.o ./../Objects/typeobject.c /usr/lib/crt1.o: In function `_start': crt1.c:(.text+0x8a): undefined reference to `main' Parser/bitset.o: In function `_Py_newbitset': bitset.c:(.text+0xfa): undefined reference to `Py_FatalError' Parser/firstsets.o: In function `calcfirstset': firstsets.c:(.text+0x15): undefined reference to `Py_DebugFlag' firstsets.c:(.text+0x1d9): undefined reference to `Py_DebugFlag' firstsets.c:(.text+0x20f): undefined reference to `Py_FatalError' firstsets.c:(.text+0x329): undefined reference to `Py_FatalError' Parser/firstsets.o: In function `_Py_addfirstsets': firstsets.c:(.text+0x345): undefined reference to `Py_DebugFlag' Parser/grammar.o: In function `_Py_translatelabels': grammar.c:(.text+0x87): undefined reference to `Py_DebugFlag' grammar.c:(.text+0x10d): undefined reference to `Py_DebugFlag' grammar.c:(.text+0x205): undefined reference to `Py_DebugFlag' grammar.c:(.text+0x234): undefined reference to `Py_DebugFlag' Parser/grammar.o: In function `_Py_findlabel': grammar.c:(.text+0x452): undefined reference to `Py_FatalError' Parser/grammar.o: In function `_Py_addarc': grammar.c:(.text+0x4ec): undefined reference to `Py_FatalError' Parser/grammar.o: In function `_Py_addstate': grammar.c:(.text+0x588): undefined reference to `Py_FatalError' Parser/grammar.o: In function `_Py_addlabel': grammar.c:(.text+0x63b): undefined reference to `Py_DebugFlag' grammar.c:(.text+0x675): undefined reference to `Py_FatalError' Parser/grammar.o: In function `_Py_adddfa': grammar.c:(.text+0x72e): undefined reference to `Py_FatalError' Parser/grammar.o: In function `_Py_newgrammar': grammar.c:(.text+0x7a6): undefined reference to `Py_FatalError' Parser/pgen.o: In function `addnfaarc': pgen.c:(.text+0x76): undefined reference to `Py_FatalError' Parser/pgen.o: In function `addnfastate': pgen.c:(.text+0xd6): undefined reference to `Py_FatalError' Parser/pgen.o: In function `_Py_pgen': pgen.c:(.text+0x5f4): undefined reference to `Py_DebugFlag' pgen.c:(.text+0x744): undefined reference to `Py_FatalError' pgen.c:(.text+0x799): undefined reference to `Py_FatalError' pgen.c:(.text+0x7ee): undefined reference to `Py_DebugFlag' pgen.c:(.text+0xaa3): undefined reference to `Py_DebugFlag' pgen.c:(.text+0xb86): undefined reference to `Py_DebugFlag' pgen.c:(.text+0xc96): undefined reference to `Py_FatalError' pgen.c:(.text+0xca5): undefined reference to `Py_FatalError' pgen.c:(.text+0xcb1): undefined reference to `Py_DebugFlag' pgen.c:(.text+0xeed): undefined reference to `Py_FatalError' pgen.c:(.text+0xefc): undefined reference to `Py_FatalError' Parser/tokenizer_pgen.o: In function `indenterror': tokenizer_pgen.c:(.text+0x3a6): undefined reference to `PySys_WriteStderr' Parser/tokenizer_pgen.o: In function `tok_nextc': tokenizer_pgen.c:(.text+0x605): undefined reference to `PyOS_Readline' tokenizer_pgen.c:(.text+0x6ef): undefined reference to `PySys_WriteStderr' Parser/tokenizer_pgen.o: In function `tok_backup': tokenizer_pgen.c:(.text+0xa98): undefined reference to `Py_FatalError' Parser/parsetok_pgen.o: In function `PyParser_ParseStringFlagsFilenameEx': parsetok_pgen.c:(.text+0x5e3): undefined reference to `PyErr_Occurred' *** [Parser/pgen] Error code 1 1 error *** [Include/graminit.h] Error code 2 1 error *** [Python/importlib.h] Error code 2 2 errors *** [do-build] Error code 1 Stop in /usr/ports/lang/python33. *** [install] Error code 1 Stop in /usr/ports/lang/python33. root@server:/usr/ports/lang/python33 # make clean ===> Cleaning for python33-3.3.2
You did not provide enough information to determine exactly what went wrong in your build but you are likely running in an environment with non-standard permissions (umask, root, ACLs, etc.). Note that the failure occurs when the main Makefile rule to build Include/graminit.h ($(GRAMMAR_H): around Makefile.pre.in:669) gets a permission denied error trying to execute the pgen executable (Parser/pgen) created in the previously executed rule ($(PGEN): Makefile.pre.in:677). Most likely the executable lacks executable permission. Check the permissions on Parser/pgen to determine if that was so and determine why the cc -o build recipe was unable to set the normal executable permissions on it or why it was subsequently unable to be executed by make.
This is a FreeBSD-specific problem with the Python 3.3 port. Using pmake (BSD's make implementation) leads to random errors on either generating pgen or executing pgen. This seems to happen since Python 3.3.1 randomly and is quite hard to reproduce. Switching to GNU make seems to solve the issue, but makes me wonder, if Python (from now on) relies on GNU make.
I don't know of an intention to break use of other makes but I don't know of any specific effort to test with various makes. As you may have noticed, there were some significant changes to the Makefile rules for pgen-related targets by changeset 52597f888e7a which was released with 3.3.0. I would start by looking there. If someone can identify a problem, patches are welcome. The thing is pgen shouldn't need to be run at all when using a release tarball (assuming you are doing that) as long as the preserved timestamps are correct (see http://bugs.python.org/issue14321#msg155910). Perhaps there is a step missing in the creation of the release tarballs. Georg?
Indeed, the new "hg touch" facility should have been integrated in the release script. I've done that now, in the future all necessary files should have the correct timestamps in the release tarballs.