• Skip to sidebar navigation
  • Skip to content

Bitbucket

  • More
    ProjectsRepositories
  • Help
    • Online help
    • Learn Git
    • Welcome to Bitbucket
    • Keyboard shortcuts
  • Log In
Alexander Dahl
  1. Alexander Dahl

buildroot

Public
Actions
  • Clone
  • Compare

Learn more about cloning repositories

You have read-only access

Navigation
  • Source
  • Commits
  • Branches
  • All Branches Graph
  • Forks
  1. Alexander Dahl
  2. buildroot

Source

buildroot/package/python/python-2.7-003-no-import-when-cross-compiling.patch
Thomas PetazzoniThomas Petazzoni committed 2455c89bab318 Sep 2011
Raw file
Source viewDiff to previous
 
1
Disable import check when cross-compiling
2
​
3
Once Python has compiled an extension (i.e some C code, potentially
4
linked to a library), it tries to import it. This cannot work in
5
cross-compilation mode, so we just disable this check.
6
​
7
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
8
---
9
 setup.py |    4 ++++
10
 1 file changed, 4 insertions(+)
11
​
12
Index: Python-2.7.2/setup.py
13
===================================================================
14
--- Python-2.7.2.orig/setup.py
15
+++ Python-2.7.2/setup.py
16
@@ -304,6 +304,10 @@
17
             self.announce('WARNING: skipping import check for Cygwin-based "%s"'
18
                 % ext.name)
19
             return
20
+        if os.environ.get('CROSS_COMPILING') == 'yes':
21
+            self.announce('WARNING: skipping import check for cross compiled "%s"'
22
+                          % ext.name)
23
+            return
24
         ext_filename = os.path.join(
25
             self.build_lib,
26
             self.get_ext_filename(self.get_ext_fullname(ext.name)))
  • Git repository management for enterprise teams powered by Atlassian Bitbucket
  • Atlassian Bitbucket v6.7.2
  • Documentation
  • Request a feature
  • About
  • Contact Atlassian
Atlassian

Everything looks good. We'll let you know here if there's anything you should know about.