summaryrefslogtreecommitdiffstats
path: root/meta/recipes-devtools/python/python3/04-default-is-optimized.patch
diff options
context:
space:
mode:
Diffstat (limited to 'meta/recipes-devtools/python/python3/04-default-is-optimized.patch')
-rw-r--r--meta/recipes-devtools/python/python3/04-default-is-optimized.patch59
1 files changed, 0 insertions, 59 deletions
diff --git a/meta/recipes-devtools/python/python3/04-default-is-optimized.patch b/meta/recipes-devtools/python/python3/04-default-is-optimized.patch
deleted file mode 100644
index 4b8a7e56bc..0000000000
--- a/meta/recipes-devtools/python/python3/04-default-is-optimized.patch
+++ /dev/null
@@ -1,59 +0,0 @@
1Upstream-Status: Inappropriate [embedded specific]
2
3# when compiling for an embedded system, we need every bit of
4# performance we can get. default to optimized with the option
5# of opt-out.
6# Signed-Off: Michael 'Mickey' Lauer <mickey@vanille-media.de>
7
8
92012/05/01
10Signed-Off-By: Nitin A Kamble <nitin.a.kamble@intel.com>
11
12Rebased for 3.4.2 02/2015
13Signed-off-by: Alejandro Hernandez <alejandro.hernandez@linux.intel.com>
14
15Index: Python-3.5.0/Modules/main.c
16===================================================================
17--- Python-3.5.0.orig/Modules/main.c
18+++ Python-3.5.0/Modules/main.c
19@@ -37,7 +37,7 @@ static wchar_t **orig_argv;
20 static int orig_argc;
21
22 /* command line options */
23-#define BASE_OPTS L"bBc:dEhiIJm:OqRsStuvVW:xX:?"
24+#define BASE_OPTS L"bBc:dEhiIJm:NOqRsStuvVW:xX:?"
25
26 #define PROGRAM_OPTS BASE_OPTS
27
28@@ -63,6 +63,7 @@ static char *usage_2 = "\
29 -m mod : run library module as a script (terminates option list)\n\
30 -O : optimize generated bytecode slightly; also PYTHONOPTIMIZE=x\n\
31 -OO : remove doc-strings in addition to the -O optimizations\n\
32+-N : do NOT optimize generated bytecode\n\
33 -q : don't print version and copyright messages on interactive startup\n\
34 -s : don't add user site directory to sys.path; also PYTHONNOUSERSITE\n\
35 -S : don't imply 'import site' on initialization\n\
36@@ -419,8 +420,8 @@ Py_Main(int argc, wchar_t **argv)
37
38 /* case 'J': reserved for Jython */
39
40- case 'O':
41- Py_OptimizeFlag++;
42+ case 'N':
43+ Py_OptimizeFlag=0;
44 break;
45
46 case 'B':
47Index: Python-3.5.0/Python/pylifecycle.c
48===================================================================
49--- Python-3.5.0.orig/Python/pylifecycle.c
50+++ Python-3.5.0/Python/pylifecycle.c
51@@ -80,7 +80,7 @@ int Py_VerboseFlag; /* Needed by import.
52 int Py_QuietFlag; /* Needed by sysmodule.c */
53 int Py_InteractiveFlag; /* Needed by Py_FdIsInteractive() below */
54 int Py_InspectFlag; /* Needed to determine whether to exit at SystemExit */
55-int Py_OptimizeFlag = 0; /* Needed by compile.c */
56+int Py_OptimizeFlag = 1; /* Needed by compile.c */
57 int Py_NoSiteFlag; /* Suppress 'import site' */
58 int Py_BytesWarningFlag; /* Warn on str(bytes) and str(buffer) */
59 int Py_UseClassExceptionsFlag = 1; /* Needed by bltinmodule.c: deprecated */