From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from lists.gentoo.org (pigeon.gentoo.org [208.92.234.80]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by finch.gentoo.org (Postfix) with ESMTPS id 8A2CF1396D9 for ; Sun, 5 Nov 2017 16:23:15 +0000 (UTC) Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id DC388E0F68; Sun, 5 Nov 2017 16:23:14 +0000 (UTC) Received: from smtp.gentoo.org (dev.gentoo.org [IPv6:2001:470:ea4a:1:5054:ff:fec7:86e4]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by pigeon.gentoo.org (Postfix) with ESMTPS id AB89AE0F68 for ; Sun, 5 Nov 2017 16:23:13 +0000 (UTC) Received: from oystercatcher.gentoo.org (oystercatcher.gentoo.org [148.251.78.52]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.gentoo.org (Postfix) with ESMTPS id 2EC543416E3 for ; Sun, 5 Nov 2017 16:23:12 +0000 (UTC) Received: from localhost.localdomain (localhost [IPv6:::1]) by oystercatcher.gentoo.org (Postfix) with ESMTP id 966E095F4 for ; Sun, 5 Nov 2017 16:23:10 +0000 (UTC) From: "Michał Górny" To: gentoo-commits@lists.gentoo.org Content-Transfer-Encoding: 8bit Content-type: text/plain; charset=UTF-8 Reply-To: gentoo-dev@lists.gentoo.org, "Michał Górny" Message-ID: <1509898984.4f81065965bb531663dfa7f8d757d1ebd4393d2b.mgorny@gentoo> Subject: [gentoo-commits] repo/gentoo:master commit in: dev-python/pypy3-bin/ X-VCS-Repository: repo/gentoo X-VCS-Files: dev-python/pypy3-bin/pypy3-bin-5.9.0.ebuild X-VCS-Directories: dev-python/pypy3-bin/ X-VCS-Committer: mgorny X-VCS-Committer-Name: Michał Górny X-VCS-Revision: 4f81065965bb531663dfa7f8d757d1ebd4393d2b X-VCS-Branch: master Date: Sun, 5 Nov 2017 16:23:10 +0000 (UTC) Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-Id: Gentoo Linux mail X-BeenThere: gentoo-commits@lists.gentoo.org X-Archives-Salt: 029b955b-8bde-47e7-a8ab-5b8296ea2a40 X-Archives-Hash: e85740e56b37decc164d076b17902da1 commit: 4f81065965bb531663dfa7f8d757d1ebd4393d2b Author: Michał Górny gentoo org> AuthorDate: Sun Nov 5 16:10:07 2017 +0000 Commit: Michał Górny gentoo org> CommitDate: Sun Nov 5 16:23:04 2017 +0000 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=4f810659 dev-python/pypy3-bin: Sync to dev-python/pypy3 dev-python/pypy3-bin/pypy3-bin-5.9.0.ebuild | 85 +++++++++++++++-------------- 1 file changed, 45 insertions(+), 40 deletions(-) diff --git a/dev-python/pypy3-bin/pypy3-bin-5.9.0.ebuild b/dev-python/pypy3-bin/pypy3-bin-5.9.0.ebuild index cea9bc9a319..55abb1af9ee 100644 --- a/dev-python/pypy3-bin/pypy3-bin-5.9.0.ebuild +++ b/dev-python/pypy3-bin/pypy3-bin-5.9.0.ebuild @@ -90,8 +90,47 @@ src_compile() { mv pypy/module/cpyext/parse/*.h include/ || die #use doc && emake -C pypy/doc/ html - #needed even without jit :( also needed in both compile and install phases pax-mark m pypy3-c libpypy3-c.so + + #use doc && emake -C pypy/doc html + + einfo "Generating caches and CFFI modules ..." + + # Generate Grammar and PatternGrammar pickles. + "${PYTHON}" -c "import lib2to3.pygram, lib2to3.patcomp; lib2to3.patcomp.PatternCompiler()" \ + || die "Generation of Grammar and PatternGrammar pickles failed" + + # Generate cffi modules + # Please keep in sync with pypy/tool/build_cffi_imports.py! +#cffi_build_scripts = { +# "sqlite3": "_sqlite3_build.py", +# "audioop": "_audioop_build.py", +# "tk": "_tkinter/tklib_build.py", +# "curses": "_curses_build.py" if sys.platform != "win32" else None, +# "syslog": "_syslog_build.py" if sys.platform != "win32" else None, +# "_gdbm": "_gdbm_build.py" if sys.platform != "win32" else None, +# "pwdgrp": "_pwdgrp_build.py" if sys.platform != "win32" else None, +# "resource": "_resource_build.py" if sys.platform != "win32" else None, +# "lzma": "_lzma_build.py", +# "_decimal": "_decimal_build.py", +# "ssl": "_ssl_build.py", + cffi_targets=( audioop curses syslog pwdgrp resource lzma decimal ssl ) + use gdbm && cffi_targets+=( gdbm ) + use sqlite && cffi_targets+=( sqlite3 ) + use tk && cffi_targets+=( tkinter/tklib ) + + local t + # all modules except tkinter output to . + # tkinter outputs to the correct dir ... + cd lib_pypy || die + for t in "${cffi_targets[@]}"; do + # tkinter doesn't work via -m + ../pypy3-c "_${t}_build.py" || die "Failed to build CFFI bindings for ${t}" + done + + # Cleanup temporary objects + find -name "_cffi_*.[co]" -delete || die + find -type d -empty -delete || die } src_test() { @@ -106,10 +145,11 @@ src_test() { src_install() { local dest=/usr/$(get_libdir)/pypy3 einfo "Installing PyPy ..." - insinto "${dest}" - doins -r include lib_pypy lib-python pypy3-c libpypy3-c.so - fperms a+x ${dest}/pypy3-c ${dest}/libpypy3-c.so + exeinto "${dest}" + doexe pypy3-c libpypy3-c.so pax-mark m "${ED%/}${dest}/pypy3-c" "${ED%/}${dest}/libpypy3-c.so" + insinto "${dest}" + doins -r include lib_pypy lib-python dosym ../$(get_libdir)/pypy3/pypy3-c /usr/bin/pypy3 dodoc README.rst @@ -133,7 +173,6 @@ src_install() { einfo "Generating caches and byte-compiling ..." local -x PYTHON=${ED%/}${dest}/pypy3-c - local -x LD_LIBRARY_PATH="${ED%/}${dest}" # we can't use eclass function since PyPy is dumb and always gives # paths relative to the interpreter local PYTHON_SITEDIR=${EPREFIX}/usr/$(get_libdir)/pypy3/site-packages @@ -142,41 +181,7 @@ src_install() { echo "EPYTHON='${EPYTHON}'" > epython.py || die python_domodule epython.py - # Generate Grammar and PatternGrammar pickles. - "${PYTHON}" -c "import lib2to3.pygram, lib2to3.patcomp; lib2to3.patcomp.PatternCompiler()" \ - || die "Generation of Grammar and PatternGrammar pickles failed" - - # Generate cffi modules - # Please keep in sync with pypy/tool/build_cffi_imports.py! -#cffi_build_scripts = { -# "sqlite3": "_sqlite3_build.py", -# "audioop": "_audioop_build.py", -# "tk": "_tkinter/tklib_build.py", -# "curses": "_curses_build.py" if sys.platform != "win32" else None, -# "syslog": "_syslog_build.py" if sys.platform != "win32" else None, -# "_gdbm": "_gdbm_build.py" if sys.platform != "win32" else None, -# "pwdgrp": "_pwdgrp_build.py" if sys.platform != "win32" else None, -# "resource": "_resource_build.py" if sys.platform != "win32" else None, -# "lzma": "_lzma_build.py", -# "_decimal": "_decimal_build.py", -# "ssl": "_ssl_build.py", - cffi_targets=( audioop curses syslog pwdgrp resource lzma decimal ssl ) - use gdbm && cffi_targets+=( gdbm ) - use sqlite && cffi_targets+=( sqlite3 ) - use tk && cffi_targets+=( tkinter/tklib ) - - local t - # all modules except tkinter output to . - # tkinter outputs to the correct dir ... - cd "${ED%/}${dest}"/lib_pypy || die - for t in "${cffi_targets[@]}"; do - # tkinter doesn't work via -m - "${PYTHON}" "_${t}_build.py" || die "Failed to build CFFI bindings for ${t}" - done - - # Cleanup temporary objects - find "${ED%/}${dest}" -name "_cffi_*.[co]" -delete || die - find "${ED%/}${dest}" -type d -empty -delete || die + einfo "Byte-compiling Python standard library..." # compile the installed modules python_optimize "${ED%/}${dest}"