From owner-svn-ports-all@freebsd.org Sun Apr 12 01:40:29 2020 Return-Path: Delivered-To: svn-ports-all@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id 1A2162AAD93; Sun, 12 Apr 2020 01:40:29 +0000 (UTC) (envelope-from leres@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) server-signature RSA-PSS (4096 bits) client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "Let's Encrypt Authority X3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 490DwD70Bwz4PmT; Sun, 12 Apr 2020 01:40:28 +0000 (UTC) (envelope-from leres@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id EB1F0217B3; Sun, 12 Apr 2020 01:40:28 +0000 (UTC) (envelope-from leres@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id 03C1eSt7038101; Sun, 12 Apr 2020 01:40:28 GMT (envelope-from leres@FreeBSD.org) Received: (from leres@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id 03C1eSAT038096; Sun, 12 Apr 2020 01:40:28 GMT (envelope-from leres@FreeBSD.org) Message-Id: <202004120140.03C1eSAT038096@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: leres set sender to leres@FreeBSD.org using -f From: Craig Leres Date: Sun, 12 Apr 2020 01:40:28 +0000 (UTC) To: ports-committers@freebsd.org, svn-ports-all@freebsd.org, svn-ports-head@freebsd.org Subject: svn commit: r531470 - in head/devel/xtensa-esp32-elf: . files X-SVN-Group: ports-head X-SVN-Commit-Author: leres X-SVN-Commit-Paths: in head/devel/xtensa-esp32-elf: . files X-SVN-Commit-Revision: 531470 X-SVN-Commit-Repository: ports MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-ports-all@freebsd.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: SVN commit messages for the ports tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 Apr 2020 01:40:29 -0000 Author: leres Date: Sun Apr 12 01:40:28 2020 New Revision: 531470 URL: https://svnweb.freebsd.org/changeset/ports/531470 Log: devel/xtensa-esp32-elf: Fix build with python3 and remove DEPRECATED Chase a Python 3.7 internal api change with a patch to the toolchain version of gdb. Unpin the USES=python version. Added: head/devel/xtensa-esp32-elf/files/ head/devel/xtensa-esp32-elf/files/0001-gdb-7.12.1.patch (contents, props changed) Modified: head/devel/xtensa-esp32-elf/Makefile Modified: head/devel/xtensa-esp32-elf/Makefile ============================================================================== --- head/devel/xtensa-esp32-elf/Makefile Sun Apr 12 01:22:10 2020 (r531469) +++ head/devel/xtensa-esp32-elf/Makefile Sun Apr 12 01:40:28 2020 (r531470) @@ -3,7 +3,7 @@ PORTNAME= xtensa-esp32-elf DISTVERSION= 1.22.0.g20171219 -PORTREVISION= 3 +PORTREVISION= 4 CATEGORIES= devel MASTER_SITES= SOURCEWARE/binutils/releases/binutils:source1 \ GNU/binutils:source1 \ @@ -38,9 +38,6 @@ COMMENT= Espressif ESP32 toolchain LICENSE= GPLv2 LGPL21 LICENSE_COMB= multi -DEPRECATED= Uses deprecated version of python -EXPIRATION_DATE= 2020-09-15 - BROKEN_armv6= fails to build: failed in step 'Installing pass-2 core C gcc compiler' BROKEN_armv7= fails to build: failed in step 'Installing pass-2 core C gcc compiler' BROKEN_powerpc64= fails to build: [ERROR] collect2: error: ld returned 1 exit status @@ -56,7 +53,7 @@ BUILD_DEPENDS= bash:shells/bash \ makeinfo:print/texinfo \ wget:ftp/wget -USES= autoreconf:build bison gmake libtool python:2.7 +USES= autoreconf:build bison gmake libtool python USE_GCC= 7 USE_GITHUB= yes USE_LDCONFIG= ${PREFIX}/${PORTNAME}/libexec/gcc/${PORTNAME}/5.2.0 @@ -76,6 +73,8 @@ post-extract: ${LN} -s ${DISTDIR}/${F:C/:source[0-9]+$//} \ ${BUILD_WRKSRC}/.build/tarballs .endfor + ${MKDIR} ${WRKSRC}/local-patches/gdb/7.10 + ${CP} ${FILESDIR}/0001-gdb-7.12.1.patch ${WRKSRC}/local-patches/gdb/7.10 echo CT_LOG_PROGRESS_BAR=n >> \ ${BUILD_WRKSRC}/samples/${PORTNAME}/crosstool.config Added: head/devel/xtensa-esp32-elf/files/0001-gdb-7.12.1.patch ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/devel/xtensa-esp32-elf/files/0001-gdb-7.12.1.patch Sun Apr 12 01:40:28 2020 (r531470) @@ -0,0 +1,46 @@ +Derived from: + + https://github.com/crosstool-ng/crosstool-ng/issues/1206 + _PyImport_FixupBuiltin Solution patch #1206 + +--- a/gdb/python/python.c.orig 2019-06-14 11:41:02.944671520 +0800 ++++ b/gdb/python/python.c 2019-06-14 11:55:32.000000000 +0800 +@@ -1624,6 +1624,17 @@ finalize_python (void *ignore) + } + #endif + ++#ifdef IS_PY3K ++/* This is called via the PyImport_AppendInittab mechanism called ++ during initialization, to make the built-in _gdb module known to ++ Python. */ ++PyMODINIT_FUNC ++init__gdb_module (void) ++{ ++ return PyModule_Create (&python_GdbModuleDef); ++} ++#endif ++ + /* Provide a prototype to silence -Wmissing-prototypes. */ + extern initialize_file_ftype _initialize_python; + +@@ -1743,6 +1754,9 @@ message == an error message without a st + remain alive for the duration of the program's execution, so + it is not freed after this call. */ + Py_SetProgramName (progname_copy); ++ ++ /* Define _gdb as a built-in module. */ ++ PyImport_AppendInittab ("_gdb", init__gdb_module); + #else + Py_SetProgramName (progname); + #endif +@@ -1752,9 +1766,7 @@ message == an error message without a st + PyEval_InitThreads (); + + #ifdef IS_PY3K +- gdb_module = PyModule_Create (&python_GdbModuleDef); +- /* Add _gdb module to the list of known built-in modules. */ +- _PyImport_FixupBuiltin (gdb_module, "_gdb"); ++ gdb_module = PyImport_ImportModule ("_gdb"); + #else + gdb_module = Py_InitModule ("_gdb", python_GdbMethods); + #endif