From 7218e1b46bceac05841e90472501742d905fb3fc Mon Sep 17 00:00:00 2001 From: V3n3RiX Date: Fri, 12 Mar 2021 21:55:15 +0000 Subject: gentoo resync : 12.03.2021 --- dev-python/pypy/Manifest | 7 +- ....UnixCCompiler.runtime_library_dir_option.patch | 11 - dev-python/pypy/files/7.3.1-gentoo-path.patch | 42 --- dev-python/pypy/files/7.3.3-distutils-cxx.patch | 387 --------------------- dev-python/pypy/pypy-7.3.3.ebuild | 176 ---------- dev-python/pypy/pypy-7.3.3_p2-r1.ebuild | 2 +- 6 files changed, 2 insertions(+), 623 deletions(-) delete mode 100644 dev-python/pypy/files/1.9-distutils.unixccompiler.UnixCCompiler.runtime_library_dir_option.patch delete mode 100644 dev-python/pypy/files/7.3.1-gentoo-path.patch delete mode 100644 dev-python/pypy/files/7.3.3-distutils-cxx.patch delete mode 100644 dev-python/pypy/pypy-7.3.3.ebuild (limited to 'dev-python/pypy') diff --git a/dev-python/pypy/Manifest b/dev-python/pypy/Manifest index 07723c9e6616..22c8adf28d6b 100644 --- a/dev-python/pypy/Manifest +++ b/dev-python/pypy/Manifest @@ -1,9 +1,4 @@ -AUX 1.9-distutils.unixccompiler.UnixCCompiler.runtime_library_dir_option.patch 555 BLAKE2B 4976bf66e4e96f89e64ad79910bb7b6fc7c3929cf7b7f1a0a59e66b5bb87e600864df2556f1dccf7695223121c7271382227e16cfb8fb7851cf56be25542b7ab SHA512 f2df0a67480bbe46fbb25dd06abcbc226a7034410855105012045287e662a598fae467f5bc81b3d4adb738f812bf41819aaa5827151db0d6bba573305ee88474 -AUX 7.3.1-gentoo-path.patch 1575 BLAKE2B e374b879aabdb1a9b4d3bb07ba03510e9df7c00e6fba13e117dd718268118ade06fa76f7468855463fa50112fb780fddb9687198f4a24bb0a6cc69b5b79e70d4 SHA512 14e14e4c000166bfe3f1cd10377baecc721b43c2df43c0d5d85e8dc6f220e1a453d7fe30cfbaab547e5483f8f493ddd840620b8de4de6d55abe8f9cddcca2464 -AUX 7.3.3-distutils-cxx.patch 18613 BLAKE2B af9f2a5f0248a865d1a5c7423b35a9a14d7cf8a3d885f5ddeafa68b0c0358a0a9eebf5ba1b687558102c3dd4e2a5b4399db1f4f701628b8fff8f0f4d9795550f SHA512 332396a0a1b8181946ef3b70cd76fad8ef6f06b3fc267229ef70fda5e6d48193981ed5620a5f3577a12e3cfda22a75ee4fdad12351a57c9ade96b3f1796d651c DIST pypy2.7-gentoo-patches-7.3.3_p2.tar.xz 11184 BLAKE2B b2b9b94478609372d616c65a87cbb12a07e217928beef9fac26c428f81c662ef390db3fd85bf368ffcc8c6fa3802e506412b7bebd14bdc453009008bc3459d25 SHA512 9ab8ed99b42b36e9c212683ef93f7f1fb99caecf056293ab9a5734f8b52eedec192860702baa121630558530cb5c4652f8542300ecaaaa282377ea6456618b95 DIST pypy2.7-v7.3.3-src.tar.bz2 20881821 BLAKE2B ce1ecdd1fffe40574c7662da6038b84d2bca47ab168939ef0c12be2c6348317f17a94a3026e7fa53c71601edc153aefd98f770bd148e7af07ca751c0a5fc1252 SHA512 c2b6c44fdcac5f9445fab01572f859228fc286891fd09a4ddb95d283683d805276c853ec8e61fcd04cb9ee811d0e959d19bb03fdd7442c044f28a773633122e7 -DIST python-gentoo-patches-2.7.18-r1.tar.xz 15500 BLAKE2B 7008b29827dbbd80d4ab8f010ccf9efced99c6b4b9109e4430c0ba269ce53529cb6fedd832502c8d2d3aa21938749cc3591c2545b21c0a59a6e60f8598e84ccc SHA512 e656ab07281fd932b92165674619bbf55ecf410d2937ae4ae771d490b4532540498cc731d30d19c1e8aafd1f64df8a406bbfbb46ea985b3dcd8edb89a0b7f20f -EBUILD pypy-7.3.3.ebuild 5592 BLAKE2B 470f10f9d2ce53951adb8cc108b55a504afaf33598ee9e970b57d42aa8b2b554bc4ae41c1d45c853836c0bad73d70572b683bf95cf9ebe65040ed7e3b9f6a19a SHA512 b5095f9cdfdf68cb9049343f8e888a7da94d5f4c272baacc4e4c8be87adede76b5342a3dfc74fc7f09987e122f98f7b0f4d4e1618f3af62273936ee7e71a3f9d -EBUILD pypy-7.3.3_p2-r1.ebuild 4882 BLAKE2B 53bf57f5c0420e7c09b1a443410a4728fe0536c6bf54ac191c707bb3fd038f9b9297b157ff0424aad9589c1055cb9ab5874d3a791468dc493baeb65051df99ec SHA512 d3704ed1211a8742b9147890937eb7801c12389e67de262d6b010dc7ab04db73e2a6e9c5e4beae588bcb9cd83db69c41171b43839c0a5583d69775ac58697979 +EBUILD pypy-7.3.3_p2-r1.ebuild 4880 BLAKE2B 652df6a07bc9fb23a636ff2289b9fd4709fece2b26ec5ea029c71e8a394b569b5ac72ff27b98e077c24d0d654c72dd4d74e71c94bfcdf748c52d0b69cf03ddd5 SHA512 e8b81d6ff53b744aab44a46ffea2384a2ebf6a265b32b89d62fce2ea65fd6d53a7c69b8c66e73c600a0c29a1b13b29cb956e428c070d2fc0f5ad97e5c131ee4a MISC metadata.xml 240 BLAKE2B 41e6a4d9da33dab2decc5ff419924f382a8f64d27a81fdb97576db8c6cf125be95911747946ec8be1b453f56617fef1084f5947f84b50a8db419d46df2ae8a0f SHA512 9c23321eaa853f851bf00195ea64ac2ba093e516f9b57855ee5aa58fbb1988130c9f0c17c2a9ce9fae4ee033e0a28a70c868e0f5acdfa1dd316ab533c5279d59 diff --git a/dev-python/pypy/files/1.9-distutils.unixccompiler.UnixCCompiler.runtime_library_dir_option.patch b/dev-python/pypy/files/1.9-distutils.unixccompiler.UnixCCompiler.runtime_library_dir_option.patch deleted file mode 100644 index 65321bb60e6e..000000000000 --- a/dev-python/pypy/files/1.9-distutils.unixccompiler.UnixCCompiler.runtime_library_dir_option.patch +++ /dev/null @@ -1,11 +0,0 @@ ---- a/lib-python/2.7/distutils/unixccompiler.py -+++ b/lib-python/2.7/distutils/unixccompiler.py -@@ -297,7 +297,7 @@ - # this time, there's no way to determine this information from - # the configuration data stored in the Python installation, so - # we use this hack. -- compiler = os.path.basename(sysconfig.get_config_var("CC")) -+ compiler = os.path.basename(self.compiler[0]) - if sys.platform[:6] == "darwin": - # MacOSX's linker doesn't understand the -R flag at all - return "-L" + dir diff --git a/dev-python/pypy/files/7.3.1-gentoo-path.patch b/dev-python/pypy/files/7.3.1-gentoo-path.patch deleted file mode 100644 index 74ca86a84ac9..000000000000 --- a/dev-python/pypy/files/7.3.1-gentoo-path.patch +++ /dev/null @@ -1,42 +0,0 @@ -From 6d439c6718625bb7dce32b0afdc6a3d5168a21e5 Mon Sep 17 00:00:00 2001 -From: =?UTF-8?q?Micha=C5=82=20G=C3=B3rny?= -Date: Sat, 11 Apr 2020 07:01:27 +0200 -Subject: [PATCH] Support Gentoo install scheme - ---- - lib-python/2.7/distutils/command/install.py | 12 +++++++++++- - 1 file changed, 11 insertions(+), 1 deletion(-) - -diff --git a/lib-python/2.7/distutils/command/install.py b/lib-python/2.7/distutils/command/install.py -index 6fe62be..a4e9f0d 100644 ---- a/lib-python/2.7/distutils/command/install.py -+++ b/lib-python/2.7/distutils/command/install.py -@@ -97,6 +97,13 @@ INSTALL_SCHEMES = { - 'scripts': '$base/Scripts', - 'data' : '$base', - }, -+ 'gentoo': { -+ 'purelib': '$base/site-packages', -+ 'platlib': '$base/site-packages', -+ 'headers': '$base/include/$dist_name', -+ 'scripts': '@EPREFIX@/usr/bin', -+ 'data' : '@EPREFIX@/usr', -+ }, - } - - # The keys to an installation scheme; if any new types of files are to be -@@ -483,7 +490,10 @@ class install (Command): - # it's the caller's problem if they supply a bad name! - if (hasattr(sys, 'pypy_version_info') and - not name.endswith(('_user', '_home'))): -- if os.name == 'nt': -+ if self.install_base.startswith(os.path.normpath('@EPREFIX@/usr/lib/pypy')): -+ # override paths for system-wide install -+ name = 'gentoo' -+ elif os.name == 'nt': - name = 'pypy_nt' - else: - name = 'pypy' --- -2.26.0 - diff --git a/dev-python/pypy/files/7.3.3-distutils-cxx.patch b/dev-python/pypy/files/7.3.3-distutils-cxx.patch deleted file mode 100644 index d5939d7417f2..000000000000 --- a/dev-python/pypy/files/7.3.3-distutils-cxx.patch +++ /dev/null @@ -1,387 +0,0 @@ -From 5ca45626481778f12654cd2ea8c45b5eeb2363c6 Mon Sep 17 00:00:00 2001 -From: =?UTF-8?q?Micha=C5=82=20G=C3=B3rny?= -Date: Fri, 13 Nov 2020 01:02:28 +0100 -Subject: [PATCH] Fancy patch for distutils C++ support, rebased for - pypy7.3.3rc1 - ---- - lib-python/2.7/_osx_support.py | 10 ++-- - lib-python/2.7/distutils/cygwinccompiler.py | 21 ++++++- - lib-python/2.7/distutils/emxccompiler.py | 14 ++++- - lib-python/2.7/distutils/sysconfig_cpython.py | 26 +++++++-- - lib-python/2.7/distutils/sysconfig_pypy.py | 37 ++++++++++--- - lib-python/2.7/distutils/unixccompiler.py | 55 ++++++++++--------- - 6 files changed, 112 insertions(+), 51 deletions(-) - -diff --git a/lib-python/2.7/_osx_support.py b/lib-python/2.7/_osx_support.py -index d2aaae7..8bcdb05 100644 ---- a/lib-python/2.7/_osx_support.py -+++ b/lib-python/2.7/_osx_support.py -@@ -14,13 +14,13 @@ __all__ = [ - # configuration variables that may contain universal build flags, - # like "-arch" or "-isdkroot", that may need customization for - # the user environment --_UNIVERSAL_CONFIG_VARS = ('CFLAGS', 'LDFLAGS', 'CPPFLAGS', 'BASECFLAGS', -- 'BLDSHARED', 'LDSHARED', 'CC', 'CXX', -- 'PY_CFLAGS', 'PY_LDFLAGS', 'PY_CPPFLAGS', -- 'PY_CORE_CFLAGS') -+_UNIVERSAL_CONFIG_VARS = ('CFLAGS', 'CXXFLAGS', 'LDFLAGS', 'CPPFLAGS', -+ 'BASECFLAGS', 'BLDSHARED', 'LDSHARED', 'LDCXXSHARED', -+ 'CC', 'CXX', 'PY_CFLAGS', 'PY_LDFLAGS', -+ 'PY_CPPFLAGS', 'PY_CORE_CFLAGS') - - # configuration variables that may contain compiler calls --_COMPILER_CONFIG_VARS = ('BLDSHARED', 'LDSHARED', 'CC', 'CXX') -+_COMPILER_CONFIG_VARS = ('BLDSHARED', 'LDSHARED', 'LDCXXSHARED', 'CC', 'CXX') - - # prefix added to original configuration variable names - _INITPRE = '_OSX_SUPPORT_INITIAL_' -diff --git a/lib-python/2.7/distutils/cygwinccompiler.py b/lib-python/2.7/distutils/cygwinccompiler.py -index 767400c..7133097 100644 ---- a/lib-python/2.7/distutils/cygwinccompiler.py -+++ b/lib-python/2.7/distutils/cygwinccompiler.py -@@ -120,8 +120,10 @@ class CygwinCCompiler (UnixCCompiler): - # dllwrap 2.10.90 is buggy - if self.ld_version >= "2.10.90": - self.linker_dll = "gcc" -+ self.linker_dll_cxx = "g++" - else: - self.linker_dll = "dllwrap" -+ self.linker_dll_cxx = "dllwrap" - - # ld_version >= "2.13" support -shared so use it instead of - # -mdll -static -@@ -135,9 +137,13 @@ class CygwinCCompiler (UnixCCompiler): - self.set_executables(compiler='gcc -mcygwin -O -Wall', - compiler_so='gcc -mcygwin -mdll -O -Wall', - compiler_cxx='g++ -mcygwin -O -Wall', -+ compiler_so_cxx='g++ -mcygwin -mdll -O -Wall', - linker_exe='gcc -mcygwin', - linker_so=('%s -mcygwin %s' % -- (self.linker_dll, shared_option))) -+ (self.linker_dll, shared_option)), -+ linker_exe_cxx='g++ -mcygwin', -+ linker_so_cxx=('%s -mcygwin %s' % -+ (self.linker_dll_cxx, shared_option))) - - # cygwin and mingw32 need different sets of libraries - if self.gcc_version == "2.91.57": -@@ -163,8 +169,12 @@ class CygwinCCompiler (UnixCCompiler): - raise CompileError, msg - else: # for other files use the C-compiler - try: -- self.spawn(self.compiler_so + cc_args + [src, '-o', obj] + -- extra_postargs) -+ if self.detect_language(src) == 'c++': -+ self.spawn(self.compiler_so_cxx + cc_args + [src, '-o', obj] + -+ extra_postargs) -+ else: -+ self.spawn(self.compiler_so + cc_args + [src, '-o', obj] + -+ extra_postargs) - except DistutilsExecError, msg: - raise CompileError, msg - -@@ -330,9 +340,14 @@ class Mingw32CCompiler (CygwinCCompiler): - self.set_executables(compiler='gcc%s -O -Wall' % no_cygwin, - compiler_so='gcc%s -mdll -O -Wall' % no_cygwin, - compiler_cxx='g++%s -O -Wall' % no_cygwin, -+ compiler_so_cxx='g++%s -mdll -O -Wall' % no_cygwin, - linker_exe='gcc%s' % no_cygwin, - linker_so='%s%s %s %s' - % (self.linker_dll, no_cygwin, -+ shared_option, entry_point), -+ linker_exe_cxx='g++%s' % no_cygwin, -+ linker_so_cxx='%s%s %s %s' -+ % (self.linker_dll_cxx, no_cygwin, - shared_option, entry_point)) - # Maybe we should also append -mthreads, but then the finished - # dlls need another dll (mingwm10.dll see Mingw32 docs) -diff --git a/lib-python/2.7/distutils/emxccompiler.py b/lib-python/2.7/distutils/emxccompiler.py -index a017205..bdc532c 100644 ---- a/lib-python/2.7/distutils/emxccompiler.py -+++ b/lib-python/2.7/distutils/emxccompiler.py -@@ -65,8 +65,12 @@ class EMXCCompiler (UnixCCompiler): - # XXX optimization, warnings etc. should be customizable. - self.set_executables(compiler='gcc -Zomf -Zmt -O3 -fomit-frame-pointer -mprobe -Wall', - compiler_so='gcc -Zomf -Zmt -O3 -fomit-frame-pointer -mprobe -Wall', -+ compiler_cxx='g++ -Zomf -Zmt -O3 -fomit-frame-pointer -mprobe -Wall', -+ compiler_so_cxx='g++ -Zomf -Zmt -O3 -fomit-frame-pointer -mprobe -Wall', - linker_exe='gcc -Zomf -Zmt -Zcrtdll', -- linker_so='gcc -Zomf -Zmt -Zcrtdll -Zdll') -+ linker_so='gcc -Zomf -Zmt -Zcrtdll -Zdll', -+ linker_exe_cxx='g++ -Zomf -Zmt -Zcrtdll', -+ linker_so_cxx='g++ -Zomf -Zmt -Zcrtdll -Zdll') - - # want the gcc library statically linked (so that we don't have - # to distribute a version dependent on the compiler we have) -@@ -83,8 +87,12 @@ class EMXCCompiler (UnixCCompiler): - raise CompileError, msg - else: # for other files use the C-compiler - try: -- self.spawn(self.compiler_so + cc_args + [src, '-o', obj] + -- extra_postargs) -+ if self.detect_language(src) == 'c++': -+ self.spawn(self.compiler_so_cxx + cc_args + [src, '-o', obj] + -+ extra_postargs) -+ else: -+ self.spawn(self.compiler_so + cc_args + [src, '-o', obj] + -+ extra_postargs) - except DistutilsExecError, msg: - raise CompileError, msg - -diff --git a/lib-python/2.7/distutils/sysconfig_cpython.py b/lib-python/2.7/distutils/sysconfig_cpython.py -index 6a14f70..2cce5bc 100644 ---- a/lib-python/2.7/distutils/sysconfig_cpython.py -+++ b/lib-python/2.7/distutils/sysconfig_cpython.py -@@ -181,10 +181,12 @@ def customize_compiler(compiler): - _osx_support.customize_compiler(_config_vars) - _config_vars['CUSTOMIZED_OSX_COMPILER'] = 'True' - -- (cc, cxx, cflags, ccshared, ldshared, so_ext, ar, ar_flags) = \ -- get_config_vars('CC', 'CXX', 'CFLAGS', -- 'CCSHARED', 'LDSHARED', 'SO', 'AR', -- 'ARFLAGS') -+ (cc, cxx, ccshared, ldshared, ldcxxshared, so_ext, ar, ar_flags) = \ -+ get_config_vars('CC', 'CXX', 'CCSHARED', 'LDSHARED', 'LDCXXSHARED', -+ 'SO', 'AR', 'ARFLAGS') -+ -+ cflags = '' -+ cxxflags = '' - - if 'CC' in os.environ: - newcc = os.environ['CC'] -@@ -199,19 +201,27 @@ def customize_compiler(compiler): - cxx = os.environ['CXX'] - if 'LDSHARED' in os.environ: - ldshared = os.environ['LDSHARED'] -+ if 'LDCXXSHARED' in os.environ: -+ ldcxxshared = os.environ['LDCXXSHARED'] - if 'CPP' in os.environ: - cpp = os.environ['CPP'] - else: - cpp = cc + " -E" # not always - if 'LDFLAGS' in os.environ: - ldshared = ldshared + ' ' + os.environ['LDFLAGS'] -+ ldcxxshared = ldcxxshared + ' ' + os.environ['LDFLAGS'] - if 'CFLAGS' in os.environ: -- cflags = cflags + ' ' + os.environ['CFLAGS'] -+ cflags = os.environ['CFLAGS'] - ldshared = ldshared + ' ' + os.environ['CFLAGS'] -+ if 'CXXFLAGS' in os.environ: -+ cxxflags = os.environ['CXXFLAGS'] -+ ldcxxshared = ldcxxshared + ' ' + os.environ['CXXFLAGS'] - if 'CPPFLAGS' in os.environ: - cpp = cpp + ' ' + os.environ['CPPFLAGS'] - cflags = cflags + ' ' + os.environ['CPPFLAGS'] -+ cxxflags = cxxflags + ' ' + os.environ['CPPFLAGS'] - ldshared = ldshared + ' ' + os.environ['CPPFLAGS'] -+ ldcxxshared = ldcxxshared + ' ' + os.environ['CPPFLAGS'] - if 'AR' in os.environ: - ar = os.environ['AR'] - if 'ARFLAGS' in os.environ: -@@ -220,13 +230,17 @@ def customize_compiler(compiler): - archiver = ar + ' ' + ar_flags - - cc_cmd = cc + ' ' + cflags -+ cxx_cmd = cxx + ' ' + cxxflags - compiler.set_executables( - preprocessor=cpp, - compiler=cc_cmd, - compiler_so=cc_cmd + ' ' + ccshared, -- compiler_cxx=cxx, -+ compiler_cxx=cxx_cmd, -+ compiler_so_cxx=cxx_cmd + ' ' + ccshared, - linker_so=ldshared, - linker_exe=cc, -+ linker_so_cxx=ldcxxshared, -+ linker_exe_cxx=cxx, - archiver=archiver) - - compiler.shared_lib_extension = so_ext -diff --git a/lib-python/2.7/distutils/sysconfig_pypy.py b/lib-python/2.7/distutils/sysconfig_pypy.py -index ec9f5a3..192974d 100644 ---- a/lib-python/2.7/distutils/sysconfig_pypy.py -+++ b/lib-python/2.7/distutils/sysconfig_pypy.py -@@ -67,6 +67,7 @@ def _init_posix(): - g['CFLAGS'] = "-DNDEBUG -O2" - g['CCSHARED'] = "-fPIC" - g['LDSHARED'] = "cc -pthread -shared" -+ g['LDCXXSHARED'] = "c++ -pthread -shared" - g['SO'] = [s[0] for s in imp.get_suffixes() if s[2] == imp.C_EXTENSION][0] - g['AR'] = "ar" - g['ARFLAGS'] = "rc" -@@ -85,6 +86,7 @@ def _init_posix(): - # just a guess - arch = platform.machine() - g['LDSHARED'] += ' -undefined dynamic_lookup' -+ g['LDCXXSHARED'] += ' -undefined dynamic_lookup' - g['CC'] += ' -arch %s' % (arch,) - g['MACOSX_DEPLOYMENT_TARGET'] = '10.7' - -@@ -183,37 +185,52 @@ def customize_compiler(compiler): - _osx_support.customize_compiler(_config_vars) - _config_vars['CUSTOMIZED_OSX_COMPILER'] = 'True' - -- (cc, cxx, opt, cflags, ccshared, ldshared, so_ext, ar, ar_flags) = \ -- get_config_vars('CC', 'CXX', 'OPT', 'CFLAGS', -- 'CCSHARED', 'LDSHARED', 'SO', 'AR', -- 'ARFLAGS') -+ (cc, cxx, ccshared, ldshared, ldcxxshared, so_ext, ar, ar_flags) = \ -+ get_config_vars('CC', 'CXX', 'CCSHARED', 'LDSHARED', 'LDCXXSHARED', -+ 'SO', 'AR', 'ARFLAGS') -+ -+ cflags = '' -+ cxxflags = '' - - if 'CC' in os.environ: - newcc = os.environ['CC'] -- if (sys.platform == 'darwin' -+ if (True - and 'LDSHARED' not in os.environ - and ldshared.startswith(cc)): - # On OS X, if CC is overridden, use that as the default - # command for LDSHARED as well -+ # Gentoo: s/OS X/every system/ - ldshared = newcc + ldshared[len(cc):] - cc = newcc - if 'CXX' in os.environ: -- cxx = os.environ['CXX'] -+ newcxx = os.environ['CXX'] -+ if ('LDCXXSHARED' not in os.environ -+ and ldcxxshared.startswith(cxx)): -+ ldcxxshared = newcxx + ldcxxshared[len(cxx):] -+ cxx = newcxx - if 'LDSHARED' in os.environ: - ldshared = os.environ['LDSHARED'] -+ if 'LDCXXSHARED' in os.environ: -+ ldcxxshared = os.environ['LDCXXSHARED'] - if 'CPP' in os.environ: - cpp = os.environ['CPP'] - else: - cpp = cc + " -E" # not always - if 'LDFLAGS' in os.environ: - ldshared = ldshared + ' ' + os.environ['LDFLAGS'] -+ ldcxxshared = ldcxxshared + ' ' + os.environ['LDFLAGS'] - if 'CFLAGS' in os.environ: -- cflags = opt + ' ' + os.environ['CFLAGS'] -+ cflags = os.environ['CFLAGS'] - ldshared = ldshared + ' ' + os.environ['CFLAGS'] -+ if 'CXXFLAGS' in os.environ: -+ cxxflags = os.environ['CXXFLAGS'] -+ ldcxxshared = ldcxxshared + ' ' + os.environ['CXXFLAGS'] - if 'CPPFLAGS' in os.environ: - cpp = cpp + ' ' + os.environ['CPPFLAGS'] - cflags = cflags + ' ' + os.environ['CPPFLAGS'] -+ cxxflags = cxxflags + ' ' + os.environ['CPPFLAGS'] - ldshared = ldshared + ' ' + os.environ['CPPFLAGS'] -+ ldcxxshared = ldcxxshared + ' ' + os.environ['CPPFLAGS'] - if 'AR' in os.environ: - ar = os.environ['AR'] - if 'ARFLAGS' in os.environ: -@@ -222,13 +239,17 @@ def customize_compiler(compiler): - archiver = ar + ' ' + ar_flags - - cc_cmd = cc + ' ' + cflags -+ cxx_cmd = cxx + ' ' + cxxflags - compiler.set_executables( - preprocessor=cpp, - compiler=cc_cmd, - compiler_so=cc_cmd + ' ' + ccshared, -- compiler_cxx=cxx, -+ compiler_cxx=cxx_cmd, -+ compiler_so_cxx=cxx_cmd + ' ' + ccshared, - linker_so=ldshared, - linker_exe=cc, -+ linker_so_cxx=ldcxxshared, -+ linker_exe_cxx=cxx, - archiver=archiver) - - compiler.shared_lib_extension = so_ext -diff --git a/lib-python/2.7/distutils/unixccompiler.py b/lib-python/2.7/distutils/unixccompiler.py -index 250ff12..7e64543 100644 ---- a/lib-python/2.7/distutils/unixccompiler.py -+++ b/lib-python/2.7/distutils/unixccompiler.py -@@ -55,14 +55,17 @@ class UnixCCompiler(CCompiler): - # are pretty generic; they will probably have to be set by an outsider - # (eg. using information discovered by the sysconfig about building - # Python extensions). -- executables = {'preprocessor' : None, -- 'compiler' : ["cc"], -- 'compiler_so' : ["cc"], -- 'compiler_cxx' : ["c++"], # pypy: changed, 'cc' is bogus -- 'linker_so' : ["cc", "-shared"], -- 'linker_exe' : ["cc"], -- 'archiver' : ["ar", "-cr"], -- 'ranlib' : None, -+ executables = {'preprocessor' : None, -+ 'compiler' : ["cc"], -+ 'compiler_so' : ["cc"], -+ 'compiler_cxx' : ["c++"], -+ 'compiler_so_cxx' : ["c++"], -+ 'linker_so' : ["cc", "-shared"], -+ 'linker_exe' : ["cc"], -+ 'linker_so_cxx' : ["c++", "-shared"], -+ 'linker_exe_cxx' : ["c++"], -+ 'archiver' : ["ar", "-cr"], -+ 'ranlib' : None, - } - - if sys.platform[:6] == "darwin": -@@ -129,12 +132,19 @@ class UnixCCompiler(CCompiler): - - def _compile(self, obj, src, ext, cc_args, extra_postargs, pp_opts): - compiler_so = self.compiler_so -+ compiler_so_cxx = self.compiler_so_cxx - if sys.platform == 'darwin': - compiler_so = _osx_support.compiler_fixup(compiler_so, - cc_args + extra_postargs) -+ compiler_so_cxx = _osx_support.compiler_fixup(compiler_so_cxx, -+ cc_args + extra_postargs) - try: -- self.spawn(compiler_so + cc_args + [src, '-o', obj] + -- extra_postargs) -+ if self.detect_language(src) == 'c++': -+ self.spawn(compiler_so_cxx + cc_args + [src, '-o', obj] + -+ extra_postargs) -+ else: -+ self.spawn(compiler_so + cc_args + [src, '-o', obj] + -+ extra_postargs) - except DistutilsExecError, msg: - raise CompileError, msg - -@@ -191,23 +201,16 @@ class UnixCCompiler(CCompiler): - ld_args.extend(extra_postargs) - self.mkpath(os.path.dirname(output_filename)) - try: -- if target_desc == CCompiler.EXECUTABLE: -- linker = self.linker_exe[:] -+ if target_lang == "c++": -+ if target_desc == CCompiler.EXECUTABLE: -+ linker = self.linker_exe_cxx[:] -+ else: -+ linker = self.linker_so_cxx[:] - else: -- linker = self.linker_so[:] -- if target_lang == "c++" and self.compiler_cxx: -- # skip over environment variable settings if /usr/bin/env -- # is used to set up the linker's environment. -- # This is needed on OSX. Note: this assumes that the -- # normal and C++ compiler have the same environment -- # settings. -- i = 0 -- if os.path.basename(linker[0]) == "env": -- i = 1 -- while '=' in linker[i]: -- i = i + 1 -- -- linker[i] = self.compiler_cxx[i] -+ if target_desc == CCompiler.EXECUTABLE: -+ linker = self.linker_exe[:] -+ else: -+ linker = self.linker_so[:] - - if sys.platform == 'darwin': - linker = _osx_support.compiler_fixup(linker, ld_args) --- -2.29.2 - diff --git a/dev-python/pypy/pypy-7.3.3.ebuild b/dev-python/pypy/pypy-7.3.3.ebuild deleted file mode 100644 index 8e48bcb5dc59..000000000000 --- a/dev-python/pypy/pypy-7.3.3.ebuild +++ /dev/null @@ -1,176 +0,0 @@ -# Copyright 1999-2021 Gentoo Authors -# Distributed under the terms of the GNU General Public License v2 - -EAPI=7 - -inherit pax-utils python-utils-r1 - -MY_P=pypy2.7-v${PV/_/} -# note: remember to update this to newest dev-lang/python:2.7 on bump -PATCHSET="python-gentoo-patches-2.7.18-r1" - -DESCRIPTION="A fast, compliant alternative implementation of the Python language" -HOMEPAGE="https://www.pypy.org/" -SRC_URI="https://buildbot.pypy.org/pypy/${MY_P}-src.tar.bz2 - https://dev.gentoo.org/~mgorny/dist/python/${PATCHSET}.tar.xz" -S="${WORKDIR}/${MY_P}-src" - -LICENSE="MIT" -# pypy -c 'import sysconfig; print sysconfig.get_config_var("SOABI")' -SLOT="0/73" -KEYWORDS="amd64 ~arm64 ~ppc64 x86 ~amd64-linux ~x86-linux" -IUSE="bzip2 gdbm +jit libressl ncurses sqlite tk" - -RDEPEND=" - || ( - dev-python/pypy-exe:${PV}[bzip2?,ncurses?] - dev-python/pypy-exe-bin:${PV} - ) - !libressl? ( dev-libs/openssl:0= ) - libressl? ( dev-libs/libressl:0= ) - gdbm? ( sys-libs/gdbm:0= ) - sqlite? ( dev-db/sqlite:3= ) - tk? ( - dev-lang/tk:0= - dev-tcltk/tix:0= - ) - ! /dev/null || die - # TODO: cpy turkish locale patch now fixes C code - # probably needs better port to pypy, if it is broken there - eapply -p2 "${WORKDIR}/${PATCHSET}"/0010-use_pyxml.patch - popd > /dev/null || die - - # this test relies on pypy-c hardcoding correct build time paths - sed -i -e 's:test_executable_without_cwd:_&:' \ - lib-python/2.7/test/test_subprocess.py || die - # requires Internet - sed -i -e '/class NetworkedTests/i@unittest.skip("Requires networking")' \ - lib-python/2.7/test/test_ssl.py || die - - eapply_user -} - -src_compile() { - # copy over to make sys.prefix happy - cp -p "${BROOT}"/usr/lib/pypy2.7/pypy-c-${PV} pypy-c || die - cp -p "${BROOT}"/usr/lib/pypy2.7/include/${PV}/* include/ || die - # (not installed by pypy) - rm pypy/module/cpyext/include/_numpypy/numpy/README || die - mv pypy/module/cpyext/include/* include/ || die - mv pypy/module/cpyext/parse/*.h include/ || die - pax-mark m pypy-c - - einfo "Generating caches and CFFI modules ..." - - # Generate Grammar and PatternGrammar pickles. - ./pypy-c -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 = { -# "_ssl": "_ssl_build.py", -# "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, - cffi_targets=( ssl audioop syslog pwdgrp resource ) - use gdbm && cffi_targets+=( gdbm ) - use ncurses && cffi_targets+=( curses ) - 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 - ../pypy-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() { - # (unset) - local -x PYTHONDONTWRITEBYTECODE= - local -x COLUMNS=80 - - local ignored_tests=( - # network - --ignore=lib-python/2.7/test/test_urllibnet.py - --ignore=lib-python/2.7/test/test_urllib2net.py - # lots of free space - --ignore=lib-python/2.7/test/test_zipfile64.py - ) - - ./pypy-c ./pypy/test_all.py --pypy=./pypy-c -vv \ - "${ignored_tests[@]}" lib-python || die -} - -src_install() { - local dest=/usr/lib/pypy2.7 - einfo "Installing PyPy ..." - dosym pypy-c-${PV} "${dest}/pypy-c" - insinto "${dest}" - # preserve mtimes to avoid obsoleting caches - insopts -p - doins -r include lib_pypy lib-python - - # replace copied headers with symlinks - for x in "${BROOT}"/usr/lib/pypy2.7/include/${PV}/*; do - dosym "${PV}/${x##*/}" "${dest}/include/${x##*/}" - done - - dosym ../lib/pypy2.7/pypy-c /usr/bin/pypy - dodoc README.rst - - if ! use gdbm; then - rm -r "${ED}${dest}"/lib_pypy/gdbm.py \ - "${ED}${dest}"/lib-python/*2.7/test/test_gdbm.py || die - fi - if ! use sqlite; then - rm -r "${ED}${dest}"/lib-python/*2.7/sqlite3 \ - "${ED}${dest}"/lib_pypy/_sqlite3.py \ - "${ED}${dest}"/lib-python/*2.7/test/test_sqlite.py || die - fi - if ! use tk; then - rm -r "${ED}${dest}"/lib-python/*2.7/{idlelib,lib-tk} \ - "${ED}${dest}"/lib_pypy/_tkinter \ - "${ED}${dest}"/lib-python/*2.7/test/test_{tcl,tk,ttk*}.py || die - fi - - local -x EPYTHON=pypy - local -x PYTHON=${ED}${dest}/pypy-c-${PV} - # temporarily copy to build tree to facilitate module builds - cp -p "${BROOT}${dest}/pypy-c-${PV}" "${PYTHON}" || die - - echo "EPYTHON='${EPYTHON}'" > epython.py || die - python_moduleinto /usr/lib/pypy2.7/site-packages - python_domodule epython.py - - einfo "Byte-compiling Python standard library..." - python_optimize "${ED}${dest}" - - # remove to avoid collisions - rm "${PYTHON}" || die -} diff --git a/dev-python/pypy/pypy-7.3.3_p2-r1.ebuild b/dev-python/pypy/pypy-7.3.3_p2-r1.ebuild index d9a8bc29d156..94fa2f5ad800 100644 --- a/dev-python/pypy/pypy-7.3.3_p2-r1.ebuild +++ b/dev-python/pypy/pypy-7.3.3_p2-r1.ebuild @@ -18,7 +18,7 @@ S="${WORKDIR}/${MY_P}-src" LICENSE="MIT" # pypy -c 'import sysconfig; print sysconfig.get_config_var("SOABI")' SLOT="0/73" -KEYWORDS="~amd64 ~arm64 ~ppc64 ~x86 ~amd64-linux ~x86-linux" +KEYWORDS="amd64 ~arm64 ~ppc64 x86 ~amd64-linux ~x86-linux" IUSE="bzip2 gdbm +jit libressl ncurses sqlite tk" RDEPEND=" -- cgit v1.2.3